Chat color and JSON problem

  • 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!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

dudle

Active Member
Jan 31, 2017
135
0
16
45
So I have a json thing in chat which just puts a button in-front of the player's name in chat, and also a chat color. The problem is that when I type a large thing, half of the message's color is fine but the rest has color of the chat in white. How may I fix this?
 
I recommend using Json.sk https://forums.skunity.com/resources/json-sk.23/ This should fix the issue, If you are using this, contact the developer of it. If you're not using that you're most likely using SkQuery/Umbaska. You can add then to the syntax to add more lines of text. This will format a new line below with colour.

Since no one replied to this. I'm guessing no one has a clue what they're talking about.

If anyone wants to understand what they mean:
Basically SkQuery/Umbaska if you input too long of a text it will cut it off and put the rest of the text on a new line (Typical mc behavior) but it doesn't colour the next line.

Example fix:
code_language.skript:
send json of "This is some text" then " &6Even more text" tooltip " Added tool tip" to player

But I recommend using that Json sk.
 
I recommend using Json.sk https://forums.skunity.com/resources/json-sk.23/ This should fix the issue, If you are using this, contact the developer of it. If you're not using that you're most likely using SkQuery/Umbaska. You can add then to the syntax to add more lines of text. This will format a new line below with colour.

Since no one replied to this. I'm guessing no one has a clue what they're talking about.

If anyone wants to understand what they mean:
Basically SkQuery/Umbaska if you input too long of a text it will cut it off and put the rest of the text on a new line (Typical mc behavior) but it doesn't colour the next line.

Example fix:
code_language.skript:
send json of "This is some text" then " &6Even more text" tooltip " Added tool tip" to player

But I recommend using that Json sk.
The problem with your example is that if it's a chat message, the user could have coloured something in their message and using
Code:
then "&6whatever"
will just reset the colour.
 
I recommend using Json.sk
Is it 1.8+ only? I'm using Spigot 1.7.10-1.8 and it gives me 7 errors when I load it.

I'm currently using the SkQuery's json btw any way to fix this issue without the json.sk thingy please?
[doublepost=1486217522,1485987209][/doublepost]Well in that case how may I do so that if a message is longer that "X" characters it puts the rest of the message in a new line? I guess this will fix that chatcolor thingy
 
Status
Not open for further replies.