Tempoarary Ender Pearl

  • 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.

ChocoAura

Member
Jul 3, 2019
38
0
6
24
So I would like to make an ender pearl like the one in one of the Hypixel Game modes where it teleports you, then teleports you back 3 seconds later. I would like to make it 5 seconds, this is my code right now:

Code:
on projectile hit:
    shooter is a player:
        projectile is ender pearl with name "&aRewind Pearl":
            wait 5 seconds
            send "&aTeleporting you back to the previous location..."
            execute console command "/tp %shooter% %{rptp.%shooter%}%"
       
on right click with ender pearl:
    name of held item contains "aRewind Pearl":
        set {rptp.%player%} to player coordinates
        send "&aYou will teleport back to this location 5 seconds after the ender pearl lands."

The error is:

Code:
Can't understand this expression: 'player coordinates'
[doublepost=1564328954,1564279759][/doublepost]bump
 
code_language.skript:
on projectile hit:
    projectile = ender pearl:
        set {_locs} to shooter's location
        teleport shooter to event-location
        wait 5 seconds 
        teleport shooter to {_locs}
 
code_language.skript:
on projectile hit:
    projectile = ender pearl:
        set {_locs} to shooter's location
        teleport shooter to event-location
        wait 5 seconds
        teleport shooter to {_locs}
I tried it, It doesn't work.
[doublepost=1564414294,1564414151][/doublepost]
Code:
to player's current position # also location works too

also
Code:
name of held item is "&aRewind Pearl":

edit:
Code:
to player's coordinates # this should also work, remember don't forget the '
I tried, this one doesn't work
[doublepost=1564506799][/doublepost]bump
 
So I would like to make an ender pearl like the one in one of the Hypixel Game modes where it teleports you, then teleports you back 3 seconds later. I would like to make it 5 seconds, this is my code right now:

Code:
on projectile hit:
    shooter is a player:
        projectile is ender pearl with name "&aRewind Pearl":
            wait 5 seconds
            send "&aTeleporting you back to the previous location..."
            execute console command "/tp %shooter% %{rptp.%shooter%}%"
      
on right click with ender pearl:
    name of held item contains "aRewind Pearl":
        set {rptp.%player%} to player coordinates
        send "&aYou will teleport back to this location 5 seconds after the ender pearl lands."

The error is:

Code:
Can't understand this expression: 'player coordinates'
[doublepost=1564328954,1564279759][/doublepost]bump
Try:
code_language.skript:
on projectile hit:
    shooter is a player
    projectile is ender pearl with name "&aRewind Pearl":
        set {_enderpearl} to shooter's location

        wait 5 seconds

        send "&aTeleporting you back to the previous location..."
        teleport shooter to {_enderpearl}
 
Status
Not open for further replies.