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 "Easy Title" Skript not coloring title & subtitle

Discussion in 'Skript' started by Fiopon, Feb 11, 2019.

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

    Fiopon New Member

    Joined:
    Dec 26, 2018
    Messages:
    6
    Likes Received:
    0
    So, I'm making an "easy title" skript, which works perfectly except for one small issue. The title and subtitle are never colored. The actionbar will come out colored, but neither the title nor the subtitle will. I find it really weird and I'm wondering if anyone could help me out?
    Code (Text):
    1. command /easytitle [<text>] [<text>]:
    2.     aliases: etitle, simpletitle, stitle
    3.     permission: duffcraft.easytitle
    4.     permission message: {@nopermission}
    5.     trigger:
    6.         if {temptitle.%player%.title} is not set:
    7.             set {temptitle.%player%.title} to false
    8.         if {temptitle.%player%.subtitle} is not set:
    9.             set {temptitle.%player%.subtitle} to false
    10.         if {temptitle.%player%.actionbar} is not set:
    11.             set {temptitle.%player%.actionbar} to false
    12.         if arg 1 is not set:
    13.             message "&bUsage: /&eeasytitle &etitle&b|&esubtitle&b|&eactionbar&b|&edelete&b|&etest&b|&esend &b<&etext&b>"
    14.         if arg 1 is "title":
    15.             if arg 2 is not set:
    16.                 make player execute command "/etitle"
    17.                 stop
    18.             message "&eTitle&b set to '&r%colored arg-2%&b'"
    19.             set {temptitle.%player%.title} to arg 2
    20.         if arg 1 is "subtitle":
    21.             if arg 2 is not set:
    22.                 make player execute command "/etitle"
    23.                 stop
    24.             message "&eSubtitle&b set to '&r%colored arg-2%&b'"
    25.             set {temptitle.%player%.subtitle} to arg 2
    26.         if arg 1 is "actionbar":
    27.             if arg 2 is not set:
    28.                 make player execute command "/etitle"
    29.                 stop
    30.             message "&eAction Bar&b set to '&r%colored arg-2%&b'"
    31.             set {temptitle.%player%.actionbar} to arg 2
    32.         if arg 1 is "del" or "delete" or "remove" or "rem":
    33.             if arg 2 is not set:
    34.                 message "&bWhich would you like to delete?"
    35.                 message "  &cAll"
    36.                 if {temptitle.%player%.title} is not false:
    37.                     message "  &cTitle"
    38.                 if {temptitle.%player%.subtitle} is not false:
    39.                     message "  &cSubtitle"
    40.                 if {temptitle.%player%.actionbar} is not false:
    41.                     message "  &cAction bar"
    42.             if arg 2 is "title" or "all":
    43.                 set {temptitle.%player%.title} to false
    44.                 message "&bTitle deleted."
    45.             if arg 2 is "subtitle" or "all":
    46.                 set {temptitle.%player%.subtitle} to false
    47.                 message "&bSubtitle deleted."
    48.             if arg 2 is "actionbar" or "action bar" or "all":
    49.                 set {temptitle.%player%.actionbar} to false
    50.                 message "&bAction bar deleted."
    51.         if arg 1 is "test":
    52.             set {_title} to "%{temptitle.%player%.title}%"
    53.             set {_subtitle} to "%{temptitle.%player%.subtitle}%"
    54.             set {_actionbar} to "%{temptitle.%player%.actionbar}%"
    55.             if {temptitle.%player%.title} is false:
    56.                 set {_title} to "&r"
    57.             if {temptitle.%player%.subtitle} is false:
    58.                 set {_subtitle} to "&r"
    59.             if {temptitle.%player%.actionbar} is false:
    60.                 set {_actionbar} to "&r"
    61.             send player title "%{_title}%" with subtitle "%{_subtitle}%"
    62.             send a actionbar from "%{_actionbar}%" to player
    63.         if arg 1 is "send":
    64.             set {_title} to "%{temptitle.%player%.title}%"
    65.             set {_subtitle} to "%{temptitle.%player%.subtitle}%"
    66.             set {_actionbar} to "%{temptitle.%player%.actionbar}%"
    67.             if {temptitle.%player%.title} is false:
    68.                 set {_title} to "&r"
    69.             if {temptitle.%player%.subtitle} is false:
    70.                 set {_subtitle} to "&r"
    71.             if {temptitle.%player%.actionbar} is false:
    72.                 set {_actionbar} to "&r"
    73.             loop all players:
    74.                 send loop-player title "%{_title}%" with subtitle "%{_subtitle}%"
    75.                 send a actionbar from "%{_actionbar}%" to loop-player
    --- Double Post Merged, Feb 11, 2019, Original Post Date: Feb 11, 2019 ---
    Nevermind, I fixed this myself a moment after posting this. I put the "colored arg-2" in the message instead of the actual setting thing by mistake, whoops
     
Thread Status:
Not open for further replies.

Share This Page

Loading...