1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Knockback player to selected position

Discussion in 'Development' started by kaliiks, Mar 3, 2017.

  1. kaliiks

    kaliiks Zombie

    Messages:
    250
    I'm trying to make a plugin which knockback the player from anywhere to a specific position (for example 1, 1, 17)
    I don't want to teleport the player.
    How i do that?
     
  2. jasonwynn10

    jasonwynn10 Moderator Poggit Reviewer

    Messages:
    1,489
    GitHub:
    jasonwynn10
    Apply the force to the player's vector position by using the add function
     
  3. kaliiks

    kaliiks Zombie

    Messages:
    250
    Can you give me example? Sorry, idk what do you mean :/
     
  4. jasonwynn10

    jasonwynn10 Moderator Poggit Reviewer

    Messages:
    1,489
    GitHub:
    jasonwynn10
    PHP:
    $player->add($x$y$z);
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.