Jump to content

PeterRDevries

Forge Modder
  • Posts

    169
  • Joined

  • Last visited

Everything posted by PeterRDevries

  1. PS: i'm trying to do something like forge microblocks theyre creating another block with the same block name as all the other blocks it had loaded.
  2. What about editing the items subtext? and not the item name
  3. That doesnt seem to work because getItemStackDisplayName needs an ItemStack as parameter
  4. I tried overriding it in the main itemclass: @Override public String getItemStackDisplayName(ItemStack par1ItemStack) { return super.getItemStackDisplayName(new ItemStack(Items.arrow)); } To test but nothing happened and I also noticed it only works with itemstacks. How can I add an item for every existing block with a name like blockname + sample or anything like it? Thanks for your help.
  5. Damn thanks I was looking for that. Edit: i still can't get it to work somehow
  6. Hello. I'm trying to edit my item names in game using the localized system the en_US.lang file. So i've tried this: Set<String> example = GameData.blockRegistry.getKeys(); for (String s : example) { PrintWriter out; try { out = new PrintWriter( new BufferedWriter( new OutputStreamWriter( new FileOutputStream("assets/MolecularScience/lang/en_US.lang"),"UTF-8"))); out.println("simpleString"); out.close(); } catch (UnsupportedEncodingException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (FileNotFoundException e) { // TODO Auto-generated catch block e.printStackTrace(); } Sample = new ItemSampler().setUnlocalizedName(s + "sample").setCreativeTab(MolecularScience.Molecules); GameRegistry.registerItem(Sample, s + " Sample"); } } Sadly I get an error returning path not found. Does anyone know the path or a better way to do this? PS: without the use of the en_US.lang file i would need to do something like this LanguageRegistry.addName(Sample, s + " Sample"); but since addname is probably going to be removed in 1.8 I can't seem to find anyother way to do this Thanks.
  7. I think he means the short render distance the black void stuff.
  8. Does you server have the appeng mod installed?
  9. I think not all mods are using forge gradle then check your config files.
  10. Yeah here's the problem technic doens't allow users to just simply add mods by putting them in the mod folder. Atleast this is what I think they had a config for other mods somewhere in the bin folder.
  11. Your item id's are conflicting. example: Let's say you have an item using the id 1500. Then you add another mod using that id overriding the id 1500. your item will change to the other mods item id removing the other item. You should edit the mod configs and check the console for any item id conflicts
  12. Could you say what few other mods you have running since my modpack using mfr ic2 and tinkerers is working just fine
  13. Tried that Still no difference.
  14. Hello Somehow I can't add any new items or blocks this is my main file: package molecularscience; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.Item; import net.minecraftforge.common.config.Configuration; import cpw.mods.fml.common.Mod; import cpw.mods.fml.common.Mod.Instance; import cpw.mods.fml.common.SidedProxy; import cpw.mods.fml.common.event.FMLInitializationEvent; import cpw.mods.fml.common.event.FMLPostInitializationEvent; import cpw.mods.fml.common.event.FMLPreInitializationEvent; import cpw.mods.fml.common.registry.GameRegistry; @Mod(modid = MolecularScience.MODID, version = MolecularScience.VERSION) public class MolecularScience { public static Item tutorialItem; public static final String MODID = "MolecularScience"; public static final String VERSION = "1.0.0"; @Instance(value = "MolecularScience") public static MolecularScience instance; @SidedProxy(clientSide="molecularscience.ClientProxy", serverSide="molecularscience.CommonProxy") public static CommonProxy proxy; public void preInit(FMLPreInitializationEvent event){ Configuration config = new Configuration(event.getSuggestedConfigurationFile()); config.load(); config.save(); System.out.println("hoi"); } public void load(FMLInitializationEvent event) { proxy.registerRenderers(); tutorialItem = new ItemTutorial().setUnlocalizedName("tutorialitem"); GameRegistry.registerItem(tutorialItem,"tutorial"); } public void postInit(FMLPostInitializationEvent event) { System.out.println("hoi"); } } And this is my item file: package molecularscience; import java.util.List; import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.util.IIcon; import net.minecraft.util.MathHelper; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; public class ItemTutorial extends Item { public ItemTutorial() { super(); this.setCreativeTab(CreativeTabs.tabMisc); } } I don't know what I'm doing wrong here please help. Thanks
  15. I think you need to take a look in your teleporter file maybe you have an error or typo there
  16. You could try to create some sort of cooldown before the block is harvested.
  17. This modeler is Craftstudio www.craftstud.io It's a pretty good modeler unless you want to actually use them in minecraft wich costs 20 eur to export to java.
  18. No.... You need to code something that prevents the player from teleporting for 10seconds after he/she used your portal. i think this is the code you're looking for: entity.timeUntilPortal = entity.getPortalCooldown();
  19. You could take a look at the tileentity furnace and edit out the burning stuff OR you could just copy all minecraft furnace file remove the fuel slot and set public boolean isBurning() { return this.furnaceBurnTime > 0; } to always return true so technically your new block is always burning therefor never needing a new fuel.
  20. Thanks alot I got it working now. The event I wanted to use working: @ForgeSubscribe public void onPlayerDeath(LivingDeathEvent event){ if(event.entity instanceof EntityPlayerMP){//uses entityplayermp because entityplayer is not called on player death as of minecraft 1.5.2 i think System.out.println("hoi"); } }
  21. I did register the class MinecraftForge.EVENT_BUS.register(new PlayerHandler()); but i can't forgesubscribe livingdeathevent
  22. Hello, I've been wondering how to call the LivingDeathEvent. @ForgeSubscribe public void LivingDeathEvent(EntityLivingBase entity){ if(entity instanceof EntityPlayer){ System.out.println("test"); } } i tried doing this but entitylivingbase isn't a event class with what should i replace this ? I'm trying to call a line of code on player death Thanks for any help and have a great 2014
  23. couldnt have solved without draco thank him
  24. @SideOnly(Side.CLIENT) @Override public void registerIcons(IconRegister par1IconRegister) { itemIcon = par1IconRegister.registerIcon(Icons.getIcon("dagger")); overlayIcon = par1IconRegister.registerIcon(Icons.getIcon("dagger_overlay")); } @Override public boolean requiresMultipleRenderPasses() { return true; } public Icon getIcon(ItemStack stack, int renderPass){ if(renderPass == 0){ return itemIcon; }else{ return overlayIcon; } } private int colorA = 421010; @SideOnly(Side.CLIENT) public int getColorFromItemStack(ItemStack par1ItemStack, int renderPass) { if (renderPass == 0){ return colorA; } return 16777215; }
  25. Thanks for the reply draco. well I'm just trying to use an overlay in my default item that just extends Item. public void registerIcons(IconRegister par1IconRegister) { //some code with the normal texture //the overlay itemIcon = par1IconRegister.registerIcon(Icons.getIcon("dagger_overlay")); }
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.