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.

Solved Skript question, please read my description.

Discussion in 'Skript' started by iamhuneey, Dec 29, 2020.

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

    iamhuneey New Member

    Joined:
    Dec 12, 2020
    Messages:
    6
    Likes Received:
    0
    Hey guys, I am a mostly beginner skript user, and I have a problem. If "player1" writes the captcha code, he is able to unlock player2's captcha code too. Can I solve this problem anyhow?
    Code (Text):
    1. On join:
    2.     if player's name is "player1" or "player2":
    3.         set {captcha::check} to true
    4.         wait 3 seconds
    5.         message "&8(&b&lCaptcha&8) &aPlease type your code"
    6.        
    7. On quit:
    8.     if player's name is "player1" or "player2":
    9.         set {captcha::check} to false
    10.  
    11. On chat:
    12.     if player's name is "player1" or "player2":
    13.         if {captcha::check} is true:
    14.             cancel event
    15.         if message is "captchatest":
    16.             set {captcha::check} to false
    17.             message "&8(&b&lCaptcha&8) &aSuccessfully checked"
     
    #1 iamhuneey, Dec 29, 2020
    Last edited: Dec 29, 2020
  2. Best Answer:
    Post #2 by Marc, Dec 29, 2020
  3. Marc

    Marc Active Member

    Joined:
    Nov 27, 2020
    Messages:
    94
    Likes Received:
    0
    you need to Set it to a specific player: {captcha::check.%player%} smth like that so skript knows your talking about 1 specific player instead of the whole server :emoji_slight_smile:
     
  4. iamhuneey

    iamhuneey New Member

    Joined:
    Dec 12, 2020
    Messages:
    6
    Likes Received:
    0
    thank you :emoji_slight_smile:)
     
Thread Status:
Not open for further replies.

Share This Page

Loading...