Mob Instant Explosion

Started by RoboWorks on Tue, 01/31/2017 - 14:10

Topic category: Help with modding (Java Edition)

Last seen on 18:06, 3. Jul 2019
Joined Nov 2014
User points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Mob Instant Explosion
Tue, 01/31/2017 - 14:10

So I have tried everything but I can't make this work. I want the mob to run at the player and as soon as it gets in range of one block it instantly blows up. I have made it to work like a creeper but I need it to blow up instantly instead of a hissing delay. Is there any way to do it?

 

Last seen on 23:21, 14. Apr 2019
Joined Jul 2015
User points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
You need to code that in.  I
Tue, 01/31/2017 - 19:07

You need to code that in.  I can maybe point you in the right direction if you are using 1.7.10.  I am not good with anything over 1.7.10

Last seen on 18:06, 3. Jul 2019
Joined Nov 2014
User points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
I am using 1.7.10  
Tue, 01/31/2017 - 19:32

I am using 1.7.10

 

Last seen on 23:21, 14. Apr 2019
Joined Jul 2015
User points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
RE:I am using 1.7.10 
Tue, 01/31/2017 - 22:20

@#2  You can use either array list or BoundingBox

Last seen on 18:06, 3. Jul 2019
Joined Nov 2014
User points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
RE:I am using 1.7.10 
Tue, 01/31/2017 - 22:46

I did it using this code:

public void onCollideWithPlayer(EntityPlayer entityplayer) {
          
               world.createExplosion((Entity) null, posX, posY, posZ, 1F, true);
          }