本文整理汇总了Java中net.minecraftforge.fml.common.event.FMLPreInitializationEvent.getModLog方法的典型用法代码示例。如果您正苦于以下问题:Java FMLPreInitializationEvent.getModLog方法的具体用法?Java FMLPreInitializationEvent.getModLog怎么用?Java FMLPreInitializationEvent.getModLog使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类net.minecraftforge.fml.common.event.FMLPreInitializationEvent
的用法示例。
在下文中一共展示了FMLPreInitializationEvent.getModLog方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: onPreInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@Mod.EventHandler
public void onPreInit(FMLPreInitializationEvent event)
{
try
{
instance = this;
this.logger = event.getModLog();
this.conf = new File(Launch.minecraftHome, "authlibloginhelper-accounts.json");
if (this.conf.createNewFile())
{
String path = this.conf.getAbsolutePath();
this.logger.info("AuthlibLoginHelper: Successfully created " + path);
}
MinecraftForge.EVENT_BUS.register(this);
}
catch (IOException e)
{
throw Throwables.propagate(e);
}
}
示例2: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@EventHandler
public void preInit(FMLPreInitializationEvent event)
{
logger = event.getModLog();
config = new Configuration(event.getSuggestedConfigurationFile());
doConfig();
int id = 1; // Don't use 0, more easy debug.
snw = NetworkRegistry.INSTANCE.newSimpleChannel(MOD_ID);
snw.registerMessage(Request.Handler.class, Request.class, id++, Side.SERVER);
snw.registerMessage(Data.Handler.class, Data.class, id++, Side.CLIENT);
proxy.preInit();
}
示例3: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@EventHandler
public void preInit(FMLPreInitializationEvent event){
Util.logger = new Logger(event.getModLog());
// find the fields we need regardless of obs
OpenGuiWrapper.findFields();
// register event handlers
MinecraftForge.EVENT_BUS.register(new Registrar());
MinecraftForge.EVENT_BUS.register(new VersionTracker());
MinecraftForge.EVENT_BUS.register(PlayerWorldSyncServer.INSTANCE);
// setup networking
RemoteGuiNetworkManager.INSTANCE.preInit(event);
VersionTracker.register(new UniversalRemoteVersionProvider());
proxy.preInit(event);
// fix broken config issues
UniversalRemoteConfiguration.validateConfig();
}
示例4: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@Mod.EventHandler
public void preInit(FMLPreInitializationEvent event) {
event.getModMetadata().version = VERSION;
log = event.getModLog();
devEnvChache = (Boolean) Launch.blackboard.get("fml.deobfuscatedEnvironment");
isMekanismLoaded = Loader.isModLoaded("mekanism");
NET_CHANNEL.registerMessage(PktCopyToClipboard.class, PktCopyToClipboard.class, 0, Side.CLIENT);
NET_CHANNEL.registerMessage(PktSyncSelection.class, PktSyncSelection.class, 1, Side.CLIENT);
proxy.loadModData(event.getModConfigurationDirectory());
proxy.preInit();
}
示例5: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
/**
* Run before anything else. Read your config, create blocks, items, etc, and
* register them with the GameRegistry.
*/
@Mod.EventHandler
public void preInit(FMLPreInitializationEvent e) {
logger = e.getModLog();
creativeTab = new CompatCreativeTabs("lector") {
@Override
protected Item getItem() {
return ModItems.manual;
}
};
this.proxy.preInit(e);
}
示例6: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@Mod.EventHandler
public void preInit(FMLPreInitializationEvent event) {
logger = event.getModLog();
}
开发者ID:Kubithorg,项目名称:KubidibotsStreamDownloaderFromYoutubeAndDisplayerThanksToAForgeMod,代码行数:5,代码来源:Streamer.java
示例7: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@Mod.EventHandler
public void preInit(FMLPreInitializationEvent event) {
logger = event.getModLog();
MinecraftForge.EVENT_BUS.register(this);
MinecraftForge.EVENT_BUS.register(new RestrictionHandler());
MinecraftForge.EVENT_BUS.register(new PlayerHandler());
MinecraftForge.EVENT_BUS.register(new DeathHandler());
MinecraftForge.EVENT_BUS.register(new RescueHandler());
MinecraftForge.EVENT_BUS.register(proxy);
CapabilityHardcoreRevival.register();
}
示例8: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@EventHandler
public void preInit(FMLPreInitializationEvent event)
{
logger = event.getModLog();
channel = NetworkRegistry.INSTANCE.newSimpleChannel(CHANNEL);
int messageNumber = 0;
channel.registerMessage(SwapItems.Handler.class, SwapItems.class, messageNumber++, Side.SERVER);
channel.registerMessage(BeltContentsChange.Handler.class, BeltContentsChange.class, messageNumber++, Side.CLIENT);
logger.debug("Final message number: " + messageNumber);
File configurationFile = event.getSuggestedConfigurationFile();
Config.loadConfig(configurationFile);
}
示例9: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@Mod.EventHandler
public void preInit(FMLPreInitializationEvent event)
{
LOGGER = event.getModLog();
ModEntities.init();
ArcaneMagicPacketHandler.registerMessages(ArcaneMagic.MODID);
proxy.preInit(event);
MinecraftForge.EVENT_BUS.register(new ModRegistry());
MinecraftForge.EVENT_BUS.register(new AnimaSubscriber());
ModRegistry.registerTiles();
Capabilities.register();
}
示例10: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@Mod.EventHandler
public void preInit(FMLPreInitializationEvent event)
{
logger = event.getModLog();
proxy.preInit(event);
}
示例11: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@EventHandler
public void preInit(FMLPreInitializationEvent event) {
logger = event.getModLog();
teslaLoaded = Loader.isModLoaded("tesla");
redstonefluxLoaded = Loader.isModLoaded("redstoneflux");
immersiveLoaded = Loader.isModLoaded("immersiveengineering");
ic2Loaded = Loader.isModLoaded("ic2");
proxy.preInit(event);
}
示例12: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@Mod.EventHandler
public void preInit(FMLPreInitializationEvent e)
{
log = e.getModLog();
setupMetadata(e.getModMetadata());
configFile = new Configuration(new File(e.getModConfigurationDirectory(), "Purificati Magicae.cfg"));
config.setup(configFile);
debug = LogManager.getLogger(MODID + "-debug");
proxy.setupDrawables();
getSipRegistry().register();
TileRegistry.register();
CapabilityRegistry.register();
EntityRegistry.register();
getPapyrusRegistry().setup();
getExpressionRegistry().setup();
PMStructureProcessorRegistry.setup();
getMagibenchRegistry().setup();
proxy.setupIfTiers();
proxy.preInit();
}
示例13: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@EventHandler
public void preInit(FMLPreInitializationEvent event) {
configFolder = new File(event.getSuggestedConfigurationFile().getParentFile(), "defier");
if(!configFolder.exists())configFolder.mkdir();
config = new Configuration(new File(configFolder, "defier.cfg"), "1.0.0", true);
ConfigData.load(config);
logger = event.getModLog();
NetworkManager.registerMessages();
proxy.preInit(event);
}
示例14: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@Mod.EventHandler
public void preInit(FMLPreInitializationEvent event) {
logger = event.getModLog();
proxy.preInit(event);
}
示例15: preInit
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; //导入方法依赖的package包/类
@Mod.EventHandler
public void preInit(FMLPreInitializationEvent event)
{
logger = event.getModLog();
proxy.preInit(event);
}