Jump to content

GotoLink

Members
  • Posts

    2012
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by GotoLink

  1. Either use the event as coolboy suggested, there is a tutorial on the wiki, or override Item#onUpdate(ItemStack, World, Entity, int, boolean) in your item. The PotionEffect isn't going to work if you keep it on the client.
  2. Named registry were introduced in 1.7. 1.6.4 only use numerical id. The preferred method was Configuration#getItem.
  3. You don't need to manipulate the container. Just use the methods in InventoryPlayer.
  4. Extend Item. Item#setCreativeTab(CreativeTabs); Write spawning code inside Item#onItemUse(foo). Eventually use texture from vanilla spawn egg to make it look the same.
  5. You might as well tell him to look at minecraft crafting recipe manager. That is the type of code one could use. sequituri was probably talking about your CLASSNAME "example". It doesn't contain any valuable code nor information. That kind of stuff : public class TheUltimateAnswer{ public static Object getSolution(Object allHumankindProblems){ //TODO: Think of something return 42; } }
  6. GameData.itemRegistry.getObjectByName(String)
  7. Bow enchantments look for ItemBow. Extend that class and you should be fine. *Hint* Copy-paste = Baaad . Durability is based on the item damage value.
  8. You are supposed to write code, not expect it from a machine or other program. If you find it too hard, take a break and try something else.
  9. "Available" doesn't mean "used". The wolf damage value is hard-coded in its attack routine. public boolean attackEntityAsMob(Entity par1Entity) { int i = this.isTamed() ? 4 : 2; return par1Entity.attackEntityFrom(DamageSource.causeMobDamage(this), (float)i); } See EntityLivingBase#applyEntityAttributes() for the attributes actually registered in all "living" entities. EntityLiving only adds the "follow range" attribute. Only EntityMob and EntityPlayer register the "attack damage" attribute.
  10. ....................... Learn how to use "for" loops. Don't follow a "tutorial" that doesn't explain the stuff.
  11. World#getTileEntity(int, int, int) And opening your container from client side (key handler) is not going to work. You need to send a packet to the server and open the container on server side.
  12. And ? The thing about attributes is they are optional. If you want it for your entity, register it into the entity attribute map by overriding the entity attribute initialization.
  13. The burning time needs to be sync on the client to be drawn into the GUI. See ContainerFurnace.
  14. TileEntity is related to a Block in the World. You can't have it in this HashMap from your Main class.
  15. What is your import for Material ? What is SampleBlock constructor ?
  16. You also need to remove the ai task when you don't want it to run.
  17. He is talking about buttons added to the inventory GUI, with a matching design like the icons for creative inventory. The only thing that Forge could do to ease the process would be to make GuiScreen.buttonList public.
  18. So the question is when do you call the second constructor for CustomFood.
  19. You shouldn't run cleanCache unless you switch from versions and want to get some free space.
  20. gradlew setupDecompWorkspace --refresh-dependencies
  21. Follow LexManos tutorial till eclipse stuff happens, then import each mod as modules into intelliJ Idea from their build.gradle file. The gradlew idea command is useless, but you can use gradlew genIntelliJRuns to get basic run configurations.
  22. EntityRegistry.registerModEntity appends modid at the beginning of the mob name, you need the complete name to use into the mob spawner logic.
  23. You are missing @SubscribeEvent, and you better use event.player, rather than Minecraft.thePlayer.
×
×
  • Create New...

Important Information

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