Guest User

TutorialMoon.java

a guest
Aug 11th, 2014
659
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package tutorial;
  2.  
  3. import tutorial.dimension.TutorialWorldProvider;
  4. import tutorial.proxy.CommonProxy;
  5. import micdoodle8.mods.galacticraft.api.GalacticraftRegistry;
  6. import micdoodle8.mods.galacticraft.api.galaxies.CelestialBody;
  7. import micdoodle8.mods.galacticraft.api.galaxies.GalaxyRegistry;
  8. import micdoodle8.mods.galacticraft.api.galaxies.Moon;
  9. import micdoodle8.mods.galacticraft.core.GalacticraftCore;
  10. import net.minecraft.util.ResourceLocation;
  11. import cpw.mods.fml.common.Mod;
  12. import cpw.mods.fml.common.Mod.EventHandler;
  13. import cpw.mods.fml.common.Mod.Instance;
  14. import cpw.mods.fml.common.SidedProxy;
  15. import cpw.mods.fml.common.event.FMLInitializationEvent;
  16. import cpw.mods.fml.common.event.FMLPostInitializationEvent;
  17. import cpw.mods.fml.common.event.FMLPreInitializationEvent;
  18.  
  19. @Mod(modid = TutorialMoon.MODID, version = TutorialMoon.VERSION, dependencies = "required-after:GalacticraftCore",
  20.         name = TutorialMoon.NAME)
  21. public class TutorialMoon
  22. {
  23.     public static final String MODID = "moonTutorial";
  24.     public static final String VERSION = "0.1.1";
  25.     public static final String NAME = "Tutorial Moon";
  26.    
  27.     public static final String ASSETPREFIX = "moonTutorial";
  28.     public static final String TEXTUREPREFIX = ASSETPREFIX + ":";
  29.    
  30.     public static Moon moonTutorial;
  31.        
  32.     @Instance(value = MODID)
  33.     public static TutorialMoon instance;
  34.    
  35.     @SidedProxy(clientSide="tutorial.proxy.ClientProxy", serverSide="tutorial.proxy.CommonProxy")
  36.     public static CommonProxy proxy;
  37.    
  38.     @EventHandler
  39.     public void preInit(FMLPreInitializationEvent event) {
  40.         PhobianConfig.initialize(event.getSuggestedConfigurationFile());
  41.     }
  42.    
  43.     @EventHandler
  44.     public void init(FMLInitializationEvent event)
  45.     {      
  46.         moonTutorial = (Moon) new Moon("Tutorial").setParentPlanet(GalacticraftCore.planetOverworld).setRelativeSize(0.0017F).setRelativeDistanceFromCenter(new CelestialBody.ScalableDistance(8F, 8F));
  47.         moonTutorial.setRelativeOrbitTime(100F).setTierRequired(1).setBodyIcon(new ResourceLocation(this.ASSETPREFIX, "textures/gui/celestial/moonTutorial.png"));
  48.         moonTutorial.setDimensionInfo(3, TutorialWorldProvider.class);
  49.        
  50.         GalaxyRegistry.registerMoon(moonTutorial);
  51.         GalacticraftRegistry.registerTeleportType(TutorialWorldProvider.class, new TutorialWorldProvider());
  52.        
  53.     }
  54.    
  55.     @EventHandler
  56.     public void postInit(FMLPostInitializationEvent event) {
  57.         // Stub Method
  58.     }
  59.    
  60. }
RAW Paste Data