1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2024-12-13 03:30:29 +00:00

Expose a stub "cctweaked" mod

This is largely invisible (it's marked as a child of the main
"computercraft" mod), but allows other mods (such as Plethora) to add
hard/soft dependencies on CC:T in a user-friendly manner.
This commit is contained in:
SquidDev 2019-03-30 16:41:45 +00:00
parent 9bf586b018
commit e4ef92ca2d
3 changed files with 43 additions and 9 deletions

View File

@ -0,0 +1,30 @@
/*
* This file is part of ComputerCraft - http://www.computercraft.info
* Copyright Daniel Ratcliffe, 2011-2019. Do not distribute without permission.
* Send enquiries to dratcliffe@gmail.com
*/
package dan200.computercraft;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.network.NetworkCheckHandler;
import net.minecraftforge.fml.relauncher.Side;
import java.util.Map;
/**
* A stub mod for CC: Tweaked. This doesn't have any functionality (everything of note is done in
* {@link ComputerCraft}), but people may depend on this if they require CC: Tweaked functionality.
*/
@Mod(
modid = "cctweaked", name = ComputerCraft.NAME, version = ComputerCraft.VERSION,
acceptableRemoteVersions = "*"
)
public class CCTweaked
{
@NetworkCheckHandler
public boolean onNetworkConnect( Map<String, String> mods, Side side )
{
return true;
}
}

View File

@ -91,13 +91,15 @@ import java.util.zip.ZipEntry;
import java.util.zip.ZipFile;
@Mod(
modid = ComputerCraft.MOD_ID, name = "CC: Tweaked", version = "${version}",
modid = ComputerCraft.MOD_ID, name = ComputerCraft.NAME, version = ComputerCraft.VERSION,
guiFactory = "dan200.computercraft.client.gui.GuiConfigCC$Factory",
dependencies = "required:forge@[14.23.4.2746,)"
)
public class ComputerCraft
{
public static final String MOD_ID = "computercraft";
static final String VERSION = "${version}";
static final String NAME = "CC: Tweaked";
// Configuration options
public static final String[] DEFAULT_HTTP_WHITELIST = new String[] { "*" };
@ -297,7 +299,7 @@ public class ComputerCraft
public static String getVersion()
{
return "${version}";
return VERSION;
}
private static File getBaseDir()

View File

@ -5,17 +5,19 @@
"version" : "${version}",
"mcversion" : "${mcversion}",
"url" : "https://github.com/SquidDev-CC/CC-Tweaked",
"credits" : "Created by Daniel Ratcliffe (@DanTwoHundred)",
"credits" : "Initially created by Daniel Ratcliffe (@DanTwoHundred)",
"authorList" : [
"Daniel Ratcliffe",
"Aaron Mills",
"SquidDev"
],
"description" : "CC: Tweaked is a fork of ComputerCraft with a focus on more experimental features.",
"logoFile" : "pack.png",
"updateUrl" : "https://github.com/SquidDev-CC/CC-Tweaked",
"parent" : "",
"screenshots": [
]
"description" : "CC: Tweaked is a fork of ComputerCraft, adding programmable computers, turtles and more to Minecraft.",
"logoFile" : "pack.png"
},
{
"modid" : "cctweaked",
"name" : "CC: Tweaked",
"version" : "${version}",
"parent" : "computercraft"
}
]