Help with procedures

Started by Axle 'The Reap… on

Topic category: Advanced modding

Last seen on 17:22, 10. Oct 2019
Joined Sep 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Help with procedures

Two things:

  1. How would you add a procedure that checks if the player has an item in their inventory when you punch a mob, then removes previously mentioned item and causes an explosion at the mob that was hit?
  2. how would you create a stacking effect the increases whenever you take damage?
Last seen on 17:22, 10. Oct 2019
Joined Sep 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Also, with #2, you have to…
Wed, 03/20/2019 - 14:15

Also, with #2, you have to be holding a specific item.

Last seen on 17:49, 25. Mar 2021
Joined Jun 2016
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
1. Do you have to punch any…
Wed, 03/20/2019 - 16:05

1. Do you have to punch any mob or a specific mob?

I don't remember if there global triggers/procedure triggers for this, anyway to check for an item in inventory use this:

 

If has player item in inventory (item)

do something

 

And to remove it

Remove (item) from player's inventory

 

I think you know how to cause an explosion... Just use the "explode" procedure block

 

2. This will be possible with MCreator 1.8.3. Anyway, to check if the player has an item in hand, use this:

If [(item in entity main hand) = (item)]

do something

Last seen on 17:22, 10. Oct 2019
Joined Sep 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Causing an explosion and…
Wed, 03/20/2019 - 16:55

Causing an explosion and removing items I know how to do, but the problem arises with checking for the item. It checks the inventory of the mob you hit instead of your own. As for the off-hand/main-hand, it does the same as checking the entity you're fighting.

Last seen on 17:49, 25. Mar 2021
Joined Jun 2016
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Then I have no ideas :(
Wed, 03/20/2019 - 18:44

Then I have no ideas :(

Last seen on 17:22, 10. Oct 2019
Joined Sep 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
how about the stacking…
Wed, 03/20/2019 - 21:27

how about the stacking strength effect?