Raebit Posted July 18, 2015 Posted July 18, 2015 So I'm trying to setup my base mod file in Eclipse using this tutorial http://www.minecraftforge.net/wiki/Tutorials/Making_the_base_mod_file. The problem I'm having is that certain parameters or functions are not being recognized as types. package gilgamesh.tutorialmod.common; import net.minecraftforge.fml.common.Mod; import net.minecraftforge.fml.common.Mod.Instance; import net.minecraftforge.fml.common.event.FMLInitializationEvent; import net.minecraftforge.fml.common.event.FMLPostInitializationEvent; import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; @Mod(modid = "tutorial", name = "Tutorial Mod", version = "1.0.0") @NetworkMod(clientSideRequired = true, serverSideRequired = false) public class mod_tutorial { @Instance("tutorial") public static mod_tutorial instance; @PreInit public void preInit(FMLPreInitializationEvent event) { } @Init public void init(FMLInitializationEvent event) { } @PostInit public static void postInit(FMLPostInitializationEvent event) { } } NetworkMod, PreInit, Init, and PostInit all "cannot be resolved to a type". Totally new to JAVA. I know I've done something wrong here. Quote
Failender Posted July 18, 2015 Posted July 18, 2015 If you are New to Java Then you shouldnt be modding.. Learn some Java Then come back. Id guess youre Imports are wrong. Maybe you were following a tutorial for a different Version Then you are coding Abd The Imports changed. Also read about Java class naming Standards please Quote
Raebit Posted July 19, 2015 Author Posted July 19, 2015 Thanks, both of you. I am studying Java and it is similar to other coding languages that I work with. The major thing for me now is just learning the calls and vocab. Could you please offer me the proper setup for the base mod in the newest version? I am having difficulty locating it. Quote
Failender Posted July 19, 2015 Posted July 19, 2015 I think its still the same, just the annotation is non existant Quote
I_Iz_Shahid Posted July 19, 2015 Posted July 19, 2015 To fix the other annotation issues, try deleting all of the imports and import them again Quote if(pain == 0) { gain = 0; }
larsgerrits Posted July 20, 2015 Posted July 20, 2015 1) Remove the @NetworkMod annotation completely. 2) @PreInit, @Init and @PostInit are removed, change them to @EventHandler. 3) Please use Java coding conventions. Quote Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support. 1.12 -> 1.13 primer by williewillus. 1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support. http://www.howoldisminecraft1710.today/
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.