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.

function with options?

Discussion in 'Skript' started by Vane2k16, Nov 12, 2019.

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

    Vane2k16 Member

    Joined:
    Feb 17, 2018
    Messages:
    10
    Likes Received:
    1
    Hello, i need help with a function for a signupdate.

    this is the function for the signupdate:

    Code (Text):
    1. function signupdate(a: text):
    2.     set line 1 of block at {knockout.sign::%{_a}%} to "- KNOCKOUT -"
    3.     set line 2 of block at {knockout.sign::%{_a}%} to "[&aONLINE&r]"
    4.     set line 4 of block at {knockout.sign::%{_a}%} to "&8%{knockout.%{_a}%}%/20"
    and this is the command to activate the function:


    Code (Text):
    1. options:
    2.    
    3.     map1: unicate
    4.     map2: duo
    5.     map3: easy
    6.    
    7. command /knockout <text>:
    8.     trigger:
    9.         if arg-1 is "join{@map1}":
    10.             wait 1 tick
    11.             add 1 to {knockout.{@map1}}
    12.             signupdate(@map1)
    And these are the errors:

    [​IMG]

    Skript Version :
    Skript 2.2
    Skript Author: Bensku
    Minecraft Version: 1.8.x
     
  2. AsuDev

    VIP

    Joined:
    Jan 27, 2017
    Messages:
    244
    Likes Received:
    22
    Surround the options in quotes. "{@map1}". Also you did not include the curvy brackets in the function args.
     
  3. Vane2k16

    Vane2k16 Member

    Joined:
    Feb 17, 2018
    Messages:
    10
    Likes Received:
    1
    Thank you very mutch it worked now! :emoji_slight_smile:
     
Thread Status:
Not open for further replies.

Share This Page

Loading...