blob: ae7db630415a3cf27e0683e35377231b85eeacce (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
package com.anthonyhilyard.iceberg;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import net.minecraftforge.api.distmarker.Dist;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.eventbus.api.SubscribeEvent;
import net.minecraftforge.fml.IExtensionPoint;
import net.minecraftforge.fml.ModLoadingContext;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.event.lifecycle.FMLCommonSetupEvent;
import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;
import net.minecraftforge.fml.loading.FMLEnvironment;
@Mod(Loader.MODID)
public class Loader
{
public static final String MODID = "iceberg";
public static final Logger LOGGER = LogManager.getLogger(MODID);
public Loader()
{
if (FMLEnvironment.dist == Dist.CLIENT)
{
IcebergClient mod = new IcebergClient();
MinecraftForge.EVENT_BUS.register(IcebergClient.class);
FMLJavaModLoadingContext.get().getModEventBus().addListener(mod::onClientSetup);
}
else
{
new IcebergServer();
}
ModLoadingContext.get().registerExtensionPoint(IExtensionPoint.DisplayTest.class, () -> new IExtensionPoint.DisplayTest(() -> "ANY", (remote, isServer) -> true));
}
@SubscribeEvent
public void onCommonSetup(FMLCommonSetupEvent event)
{
}
}
|