Create a sword procedure that allows you to do a quick forward charge.

Started by zachariecauchon on

Topic category: Help with MCreator software

Joined Oct 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Create a sword procedure that allows you to do a quick forward charge.
Hello, I would like to do a procedure for my sword in my mod. If the player right-clicks with their sword, it will move the player forward very quickly a short distance (a pierce). And will give resistance and absorption to the player and will inflict sword damage with a slow effect on mobs around the player during the charge. And if this is possible, I would also like the more mobs the player hits, the further he goes. I tried to do it alone but I can't do it at all and I hope you can help me.
Joined Sep 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I have the code for the dash…
Wed, 10/30/2024 - 21:37

I have the code for the dash, its basicly just something that teleports the player where he is looking and for the effects, just use the give effects block but im not sure how to do it to where it affects mobs around the player and he goes farther. Tell me if you want the teleport code. My best idea for the teleport longer the more mobs you hit would to be use my code but create a variable that is equal to the amount of mobs in a certain distance where the player is looking and then add that variable to the telporting one in my code (if you want it to go farther you can multipy the variable you created so that way say I have the teleport at 10 blocks, it would be 10+your variable x 2 or whatever number you want. Thats all I can think of though, im prtty new to coding