MV [SRD CCEX] It's saying there's an unexpected } in 2445 of an unspecified file. I can't find a file that even has } in that position.

I have figured out how to get new part categories to show, but I have not managed to get colorability to work. I found a block that defines colorability data for specific parts, but copying the block for "Mouth" and replacing the name with "Ears" does not seem to have enabled color. The block does make reference to CharacterCreator.json, but this is nowhere to be found in the json files in the project, so I have no idea what I need to do.

Nevermind. I found references to that json online which pointed to it being in the data folder rather than the js folder. For some reason I conflated the two. 😅


Now I'm getting this error. I didn't edit line 2445 of any file, so I'm not sure how this happened.

Uncaught SyntaxError: Unexpected token } in JSON at position 2445
SceneManager.onError @ rpg_managers.js:1919
rpg_managers.js:1920 chrome-extension://odlameecjipmbmbejkplpemijjgpljce/index.html 16
SceneManager.onError @ rpg_managers.js:1920
index.html:16 Uncaught SyntaxError: Unexpected token } in JSON at position 2445
at JSON.parse (<anonymous>)
at XMLHttpRequest.xhr.onload (rpg_managers.js:85)

It doesn't even clearly state which file has that error. I checked all the files referenced by the error, and no of them even have } in that position.

After a quick test, it's clear that whatever file is causing this issue is only being called by Character Creator EX. The only json I should meet that criteria don't have 2445 lines. Here is CharacterCreator.json, which only has 16 lines, and is the only json I've made any edits to. I cannot find a rogue curly bracket anywhere in it.

{
"Body":{"label":"","direction":0,"source":"Face","color":false,"condition":"true","colors":[["White",0],["Tan",0,0.8,0],["Brown",24,-1,0.5],["Black",24,-1,0.3],["Gray",24,0,0,0.35],["Blue",0,0,0.5,0.5]]},
"Clothing":{"label":"","direction":0,"source":"Walk","color":false,"condition":"true","colors":[]},
"Rear Hair":{"label":"","direction":3,"source":"Walk","color":true,"condition":"true","colors":[["Blonde",0],["Brown",-27,-0.5,0.8],["Black",-27,-1,0.3],["White",0,0,1,0.5],["Gray",0,0,0.5,0.5],["Green",60],["Teal",120],["Blue",180],["Purple",240],["Red",300]]},
"Tail":{"label":"","direction":3,"source":"Walk","color":true,"condition":"true","colors":[]},
"Wing":{"label":"","direction":3,"source":"Walk","color":true,"condition":"true","colors":[]},
"Eyebrows":{"label":"","direction":1,"source":"Face","color":true,"condition":"true","colors":[["Blonde",0],["Brown",-27,-0.5,0.8],["Black",-27,-1,0.3],["White",0,0,1,0.5],["Gray",0,0,0.5,0.5],["Green",60],["Teal",120],["Blue",180],["Purple",240],["Red",300]]},
"Nose":{"label":"","direction":0,"source":"Face","color":false,"condition":"true","colors":[["White",0],["Tan",0,0.8,0],["Brown",24,-1,0.5],["Black",24,-1,0.3],["Gray",24,0,0,0.35],["Blue",0,0,0.5,0.5]]},
"Mouth":{"label":"","direction":0,"source":"Face","color":false,"condition":"true","colors":[["White",0],["Tan",0,0.8,0],["Brown",24,-1,0.5],["Black",24,-1,0.3],["Gray",24,0,0,0.35],["Blue",0,0,0.5,0.5]]},
"Ears":{"label":"","direction":0,"source":"Face","color":false,"condition":"true","colors":[["White",0],["Tan",0,0.8,0],["Brown",24,-1,0.5],["Black",24,-1,0.3],["Gray",24,0,0,0.35],["Blue",0,0,0.5,0.5]]},
"Eyes":{"label":"","direction":0,"source":"Face","color":true,"condition":"true","colors":[["Blue",0],["Purple",60],["Red",120],["Yellow",180],["Green",240],["Teal",300],["Orange",180,1,0.8],["Sky Blue",0,1,1,0.35]]},
"Front Hair":{"direction":0,"source":"Walk","color":true,"condition":"true","colors":[["Blonde",0],["Brown",-27,-0.5,0.8],["Black",-27,-1,0.3],["White",0,0,1,0.5],["Gray",0,0,0.5,0.5],["Green",60],["Teal",120],["Blue",180],["Purple",240],["Red",300]],"label":""},
"Accessory A":{"direction":0,"source":"SV","color":true,"condition":"true","colors":[],"label":""},
"Accessory B":{"direction":0,"source":"SV","color":true,"condition":"true","colors":[],"label":""},
"Glasses":{"direction":0,"source":"SV","color":true,"condition":"true","colors":[],"label":""},
}
What did you edit?
from the looks of the list, the ast line (if it's a json file) like this:

"Glasses":{"direction":0,"source":"SV","color":true,"condition":"true","colors":[],"label":""},

has a comma on the end which shouldn't be there.
as a comma there suspect a new object below it.
from the looks of the list, the ast line (if it's a json file) like this:

"Glasses":{"direction":0,"source":"SV","color":true,"condition":"true","colors":[],"label":""},

has a comma on the end which shouldn't be there.
as a comma there suspect a new object below it.
This fixed it. I wish the error message had been more clear with what the issue had actually been. Thanks for your help.
it was clear, making files or altering json files needs to be carefull with
object as things like those is easely overlooked or missing a comma elsewhere,
hence the } error 🙂

I worked on a json file for my ULS plugin, and other uses that too.
if it's in a parameter, a } could be missing or a comma or re-adding to confirm
could fix it.

so there are things that not everyone knows about it 🙂
Trihan might know it as well if it was a json while and spot it as well 🙂

anyway, Good luck with your project.
This fixed it. I wish the error message had been more clear with what the issue had actually been. Thanks for your help.
The error message is as clear as it can be: all the interpreter knows is that it ticked along just fine until it got to a } in the JSON when it was expecting a new entry because of the comma. But the error that caught that doesn't know what was beforehand, it only knows what it encountered that it couldn't process.

Original thread: https://forums.rpgmakerweb.com/threads/srd-ccex-its-saying-theres-an-unexpected-in-2445-of-an-unspecified-file-i-cant-find-a-file-that-even-has-in-that-position.153522/