Skript (Death)

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

Ajility

Member
Sep 18, 2018
4
0
0
28
I am confused on how to make a player respawn in the same world they died in. Example, if you fall of the map in skypvp world you will teleport to that worlds spawn and they will be given an item. I am using Skript, Skquery, Mutliverse Core 2. Can someone help me?
 
I haven't tested this, but it should work
code_language.skript:
on death:
    if victim is a player:
        set {world::%victim%} to world of victim

on respawn:
    wait 1 tick
    teleport playaer to spawn of world {world::%player%}
    #or
    teleport playaer to spawn of {world::%player%}
 
Status
Not open for further replies.