How make when a player hits a mob add potion effect to the mob?

Started by Ser_nih on

Topic category: Help with MCreator software

Joined Mar 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How make when a player hits a mob add potion effect to the mob?

hi, I need to have potion effects applied to the player when they hit a mob (in my case, the slowness effect when the player hits the mob with a sword).)

please help me

Joined Feb 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Do you mean with a specific…
Sun, 04/11/2021 - 21:25

Do you mean with a specific sword that you made or with any sword in general. The first is easier, I think.  Make the weapon, go to the triggers and to the "When entity is hit with tool". Then make a new procedure that adds potion effect to event/target entity. If that doesn't work, change it to "source entity" instead of target entity, but I think it should work. 

Joined Mar 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
yes its true, thanks!
Tue, 04/13/2021 - 16:58

yes its true, thanks!