Procedure: Test for and remove item from player inventory, then add new item

Started by Theshortcircuit on

Topic category: Help with MCreator software

Last seen on 06:22, 12. May 2020
Joined Apr 2016
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Procedure: Test for and remove item from player inventory, then add new item

Hey guys! 

Basically I want to create a procedure that, upon the slaying of a specific mob, will test for an item in the player inventory (the one that killed the mob). If the player has said item, it will remove it and add another item to their inventory. I know how to make the system test for the item and swap it out, but it's not triggering when I add it into the mob under "when mob killed" please help!! 

Last seen on 01:15, 28. Feb 2024
Joined Jan 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Procedure:   In the mob's…
Mon, 07/16/2018 - 17:31

Procedure:Aw

 

In the mob's procedure page: w

The procedure is the procedure you created that swapped the items. In this example, when the mob is killed:

If the entity (player that killed the mob) has wooden sword, remove the wooden sword and give a stone sword. Hope this helps.