Jump to content

Recommended Posts

Posted

I am trying to add a potion effect to an entity when I hit it. No methods I could find return an Entity every click besides "hitEntity", however that isn't working for me. If anybody knows how to fix this, or a different solution, any help would be great :)!

Code:[embed=425,349]  @Override

  public boolean hitEntity(ItemStack par1ItemStack, EntityLivingBase par2EntityLivingBase, EntityLivingBase par3EntityLivingBase) {

      System.out.println("Testing");

      return true;

  }[/embed]

Posted

I am trying to add a potion effect to an entity when I hit it. No methods I could find return an Entity every click besides "hitEntity", however that isn't working for me. If anybody knows how to fix this, or a different solution, any help would be great :)!

Code:[embed=425,349]  @Override

  public boolean hitEntity(ItemStack par1ItemStack, EntityLivingBase par2EntityLivingBase, EntityLivingBase par3EntityLivingBase) {

      System.out.println("Testing");

      return true;

  }[/embed]

Posted

I am trying to add a potion effect to an entity when I hit it.

 

You need an event.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted

I am trying to add a potion effect to an entity when I hit it.

 

You need an event.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted

I am new to modding, and I can't find anywhere how to use this, could you possible explain how I would go about doing this? Or what I should I search for?

Here's a helpful article on Forge events, though some info might be out-of-date as it was written back in the days of 1.7.10.)

 

http://greyminecraftcoder.blogspot.com/2013/12/forge-techniques-events.html

Colore - The mod that adds monochrome blocks in every color of the rainbow!

http://www.minecraftforge.net/forum/index.php?topic=35149

 

If you're looking to learn how to make mods for 1.9.4, I wrote a helpful article with links to a lot of useful resources for learning Minecraft 1.9.4 modding!

 

http://supergeniuszeb.com/mods/a-helpful-list-of-minecraft-1-9-4-modding-resources/

Posted

I am new to modding, and I can't find anywhere how to use this, could you possible explain how I would go about doing this? Or what I should I search for?

Here's a helpful article on Forge events, though some info might be out-of-date as it was written back in the days of 1.7.10.)

 

http://greyminecraftcoder.blogspot.com/2013/12/forge-techniques-events.html

Colore - The mod that adds monochrome blocks in every color of the rainbow!

http://www.minecraftforge.net/forum/index.php?topic=35149

 

If you're looking to learn how to make mods for 1.9.4, I wrote a helpful article with links to a lot of useful resources for learning Minecraft 1.9.4 modding!

 

http://supergeniuszeb.com/mods/a-helpful-list-of-minecraft-1-9-4-modding-resources/

Posted

Largely speaking, everything is still correct.  There's been a reduction in buses for 1.9 (there's only one now, the split wasn't very meaningful) and some event names/properties have changed, but it should still be sufficient to get started.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted

Largely speaking, everything is still correct.  There's been a reduction in buses for 1.9 (there's only one now, the split wasn't very meaningful) and some event names/properties have changed, but it should still be sufficient to get started.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

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