How to launch a player to a location with velocities.

Discussion in 'Plugin Development' started by AstramG, Aug 14, 2013.

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

    AstramG

    How can I arc a player with a velocity to a certain location? Basically if I wanted to shoot a player exactly to the location of another player with a velocity. Thanks in advance!
     
    etaxi341 likes this.
  2. Offline

    Chinwe

    There are quite a lot of threads about vectors on the forum, like this one :>
    And then you can player.setVelocity(vector);

    Though beware, if the other player is quite far away and you want to shoot them with only one vector, they will most likely get kicked/stopped with a lot of console spam "Player moved too quickly!"!

    What about shoot them ~20 blocks in the direction, teleport to 20 blocks away from the other person, then shoot them the rest of that distance - shouldn't be too noticeable? And doesn't take too long to transport them :)
     
  3. Offline

    AstramG

    Chinwe I know about Vectors. I've been using them in almost all of my plugins. However, I'm not sure how to accomplish the task that I've mentioned.
     
Thread Status:
Not open for further replies.

Share This Page