Adding procedures for vanilla items

Started by BlueRedCommand on Wed, 04/22/2020 - 14:09

Topic category: Help with modding (Java Edition)

Last seen on 20:31, 19. May 2020
Joined Jun 2018

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Adding procedures for vanilla items
Wed, 04/22/2020 - 14:09

I tried to make the player/entity flyable while he has a specific item in the inventory (the slot isn't really matter) by adding a procedure of flying to that item, and I'd tried to use                if-do-else-do function, but it didn't work, I'd tried to change it a few, and nothing happened, so I infer tat was because that procedure work only while the item in the inventory of the entity (player), but when it doesn't have the item in it's inventory, the system won't remove from him the ability to fly in survival mode.

To fix that I think I should add this procedure to minecraft:air and not to the item itself, but how I ought to do that? I'd looked for answer, but I'd found nothing.

Tanks for help.