Help with making a TPsword

Started by Versannon on

Topic category: Help with modding (Java Edition)

Last seen on 10:20, 5. Apr 2024
Joined Sep 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Help with making a TPsword

So, i am trying to make a sword that can teleport the player holding the sword to the location where the crosshair is pointed at but i can't quite figure it out.
I have the textures and everything else ready just not the procedure for 'when right clicked'.Please help me

Last seen on 05:55, 16. Apr 2024
Joined Mar 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
You can use the 'set…
Sat, 03/09/2024 - 06:43

You can use the 'set location of' block found in entity procedures tab, and inside each coordinate axis, replace the x, y & z with all the different 'look x/y/z position of event/target entity with raytrace distance' blocks found under the same tab and set the number to how far away you want players to be able to teleport. Just remember to match up the x, y & z's together.

This forum has a pretty good example of what I'm talking about, but replace summoning lightning with teleporting the player:
https://mcreator.net/forum/66804/lightining-sword