how do i get if entity is attacking something?

Started by koshikawa on

Topic category: Help with Minecraft modding (Java Edition)

Joined Apr 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
how do i get if entity is attacking something?

i am trying to make it where if someone with an spasific enchant attacks anything they get a potion effect, yet i cant find anything that will help me. i looked through alot of forms on here and found nothing that works.

im trying to make it where

Entity attacks
 If they are holding an item with the enchant, then they gain the effect

 

and yes i am really new to this app so i dont know that much but the offical forms for enchanting didnt really help.

Joined Apr 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Global Trigger: Entity…
Tue, 04/25/2023 - 12:12

Global Trigger: Entity attacked

If item in main hand of source entity is has enchantment (your enchantment)

Do apply potion effect (your choice) with amplifier (your power-1) for (your duration*20) ticks to source entity.

 

 

 

All of the procedure blocks have been modified by swapping out some of the removable blocks for other blocks of the same type.

Joined Apr 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
thank you so much catnip!
Tue, 04/25/2023 - 15:25

thank you so much catnip!