How to fix a JSON Text in Minecraft? [duplicate]
I've been trying to make a command using JSON for a map, obviously i'm testing commands in case they try and break on me. I tried making a multi-colored tellraw command and it either does one part, or the other here's the command
/tellraw @a {"text":"(YOU!)","color":"blue","Bold":"true","text":"Rawr.","color":"red","bold":"true"}
I've tried making it to were its like
/tellraw @a {"text":"(YOU!)","color":"blue","Bold":"true"},{"text":"Rawr.","color":"red","bold":"true"}
but it still doesn't work, anyone can pick up and show my mistakes i've made?
Best Answer
Your syntax is incorrect because to chain multiple json
string definitions together, you need to arrange them in an array.
Arrays are defined using the square []
brackets.
A compound bracket; curly {}
brackets can only be used for nesting other constants.
In theory, you need to do this:
/tellraw @a [{"text":"(YOU!)","color":"blue","Bold":"true"},{"text":"Rawr.","color":"red","bold":"true"}]
^ ^
Might I also add, multiple strings in an array are explictly added, so (without color), your text will look like this:
(YOU!)Rawr.
You may want to add a space into one of the strings to denote seperation.
Pictures about "How to fix a JSON Text in Minecraft? [duplicate]"
How do I edit a JSON file in Minecraft?
28:07. Raw JSON text is the format Minecraft uses to send and display rich text to players. It can also be sent by players themselves using commands and data packs. Raw JSON text is written in JSON, a human-readable data format.What is JSON text in Minecraft?
You can use the /tellraw command to send a private JSON message to a player or group of players in Minecraft. This function allows you to format color, bold and italics for the message.How do you use JSON messages in Minecraft?
Minecraft Json ViewerMinecraft JSON Tutorial [Datapack/Command]
More answers regarding how to fix a JSON Text in Minecraft? [duplicate]
Answer 2
try this:
tellraw @p {text:"YOU!",color:blue,bold:true,extra:[{text:"Rawr.",color:red,bold:true}]}
P.S: If you want to make another line on the text:"Rawr."
part, just change the text:"Rawr."
part into text:"\nRawr."
.
Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.
Images: Skylar Kang, Karolina Grabowska, Karolina Grabowska, cottonbro