Minecraft grappling hook?

Discussion in 'Plugin Development' started by Didi1150, Apr 30, 2020.

Thread Status:
Not open for further replies.
  1. Offline

    Didi1150

    How do u add velocity to the player, so that he flies to the rod position?
     
  2. Offline

    Niv-Mizzet

  3. You can tune the multiply and remove the setY if needed (setY will ignore the Y direction the player is looking at and always shoots him up).
    Code:
    player.setVelocity(player.getLocation().getDirection().multiply(8).setY(1.3));
    Or do you want to shoot a player towards an x,y,z location? Please be more specific when creating a thread :)
     
  4. Offline

    Didi1150

    Shoot towards a position
     
Thread Status:
Not open for further replies.

Share This Page