1. 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!

  2. LOOKING FOR A VERSION OF SKRIPT?

    You can always check out our Wiki for downloads and any other information about Skript!

Dismiss Notice
This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

WHY U NO WORK?

Discussion in 'Skript' started by JustADev, Aug 17, 2017.

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

    JustADev Well-Known Member

    Joined:
    Apr 8, 2017
    Messages:
    380
    Likes Received:
    9
    Code:
    Code (Skript):
    1. on rightclick with diamond sword:
    2.     name of player's tool is "&eIce Mage Sword":
    3.         set {_Waited} to difference between {Freeze::%player%} and now
    4.         if {_Waited} is less than 20 seconds:
    5.             stop
    6.         else:
    7.             set {AbilityInUse} to "True"
    8.             send "&cAbility &8&l» &7You have activated your &aFreeze &7ability" to player
    9.             set {Freeze::%player%} to now
    10.             loop players in radius 4 around player:
    11.                 set the freeze state of loop-player to true
    12.                 wait 2 seconds
    13.                 set the freeze state of loop-player to false
     
  2. ShaneBee

    Moderator Resource Staff Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,181
    Likes Received:
    220
  3. ShaneBee

    Moderator Resource Staff Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,181
    Likes Received:
    220
    What exactly isn't working... do what @Wynnevir said.
     
  4. ShaneBee

    Moderator Resource Staff Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,181
    Likes Received:
    220
    BTW if {Freeze::%player%} is not set beforehand, the code won't work.

    But yeah, use the layout.
     
  5. ShaneBee

    Moderator Resource Staff Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,181
    Likes Received:
    220
    Ok the issue is that it can't define the freeze state of the loop-player:

    Code (Skript):
    1. on rightclick with diamond sword:
    2.     name of player's tool is "&eIce Mage Sword":
    3.         set {_Waited} to difference between {Freeze::%player%} and now
    4.         if {_Waited} is less than 20 seconds:
    5.             stop
    6.         else:
    7.             set {AbilityInUse} to "True"
    8.             send "&cAbility &8&l» &7You have activated your &aFreeze &7ability" to player
    9.             set {Freeze::%player%} to now
    10.             loop players in radius 4 around player:
    11.                 set the freeze state of loop-player to true
    12.                 wait 2 seconds
    13.                 set the freeze state of loop-player to false
     
  6. ShaneBee

    Moderator Resource Staff Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,181
    Likes Received:
    220
    Use the help request layout, please. It's not a recommendation, it's required if you want help.
     
  7. ShaneBee

    Moderator Resource Staff Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,181
    Likes Received:
    220
    Don't use freeze state
     
  8. ShaneBee

    Moderator Resource Staff Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,181
    Likes Received:
    220
    Why cant you just apply slowness and negative jump boost to the loop-player?
     
Thread Status:
Not open for further replies.

Share This Page

Loading...