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 Option(s) ending with ":"

Discussion in 'Skript' started by Nikola, Jan 8, 2021.

Tags:
Thread Status:
Not open for further replies.
  1. Nikola

    Nikola Member

    Joined:
    Jul 10, 2019
    Messages:
    38
    Likes Received:
    1
    Hi, I've tried to end one of my messages in options with :, and it gives a huge error. I guess it's because options are supposed to be written in this format:

    Code (Text):
    1. options:
    2.        first-option:
    (ending with : )

    and my message looks something like this:
    Code (Text):
    1. options:
    2.         first-option: &fSome text:
    I've tried using :: or \: at the end like I do with other symbols (##, %%, etc.), but it doesn't work

    Does anyone know how to fix this? (Without just removing : at the end)

     
  2. Best Answer:
    Post #4 by Ankoki, Jan 8, 2021
  3. Ankoki

    Supporter

    Joined:
    Nov 5, 2020
    Messages:
    55
    Likes Received:
    12
    Imma gonna assume because its looking for : to get your option, and that just screws with it. I believe you could put it in quotes and use your option in replace of the text.
     
  4. Nikola

    Nikola Member

    Joined:
    Jul 10, 2019
    Messages:
    38
    Likes Received:
    1
    ":" gives an error,
    ':' works but it shows the quotes in text too
     
  5. Ankoki

    Supporter

    Joined:
    Nov 5, 2020
    Messages:
    55
    Likes Received:
    12
    try instead of "{@option}", use {@option}
     
  6. Nikola

    Nikola Member

    Joined:
    Jul 10, 2019
    Messages:
    38
    Likes Received:
    1
    Works! Thank you so much :emoji_slight_smile:

    If anyone in the future has the same issue, here's what you should do:

    1. The whole option text must be quoted:

    Code (Text):
    1. options:
    2.         first-option: "Text:"
    2. To display the text, use

    Code (Text):
    1. send {@first-option}
    instead of
    Code (Text):
    1. send "{@first-option}"
    and that's it
     
Thread Status:
Not open for further replies.

Share This Page

Loading...