Solved Help with "make player fly"

  • 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 community!

    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!

msaid5860

Member
Feb 19, 2025
2
1
3
I'm making a blox fruits like server. On a fruit called "air" i'm having problems. Here is my code:

on click with air:
if player is sneaking:
if {fruit.%player's uuid%} is "inferno":
if {cooldown.%player's uuid%} is not set:
apply fire resistance to player for 20 seconds
send "&aUsed ability 1, now you have fire resistance for 20 seconds!" to player
set {cooldown.%player's uuid%} to 60
while {cooldown.%player's uuid%} > 0:
wait 1 second
subtract 1 from {cooldown.%player's uuid%}
else if {cooldown.%player's uuid%} is 0:
apply fire resistance to player for 20 seconds
send "&aUsed ability 1, now you have fire resistance for 20 seconds!" to player
set {cooldown.%player's uuid%} to 60
while {cooldown.%player's uuid%} > 0:
wait 1 second
subtract 1 from {cooldown.%player's uuid%}
else:
send "&cYou can't use this fruit yet! Wait %{cooldown.%player's uuid%}% seconds!" to player
else if {fruit.%player's uuid%} is "air":
if {cooldown2.%player's uuid%} is not set:
send "&aUsed ability 2, now you can fly for 5 seconds!" to player
set {cooldown2.%player's uuid%} to 60
make player fly
wait 5 seconds
unmake player fly
while {cooldown2.%player's uuid%} > 0:
wait 1 second
subtract 1 from {cooldown2.%player's uuid%}
else if {cooldown2.%player's uuid%} is 0:
send "&aUsed ability 2, now you can fly for 5 seconds!" to player
set {cooldown2.%player's uuid%} to 60
make player fly
wait 5 seconds
unmake player fly
else:
send "&cYou can't use this fruit yet! Wait %{cooldown2.%player's uuid%}% seconds!" to player
else if {fruit.%player's uuid%} is "glow":
send "" to player
How can i make it so i can make the player stop flying after 5 seconds? Also, using SkBee.