I m using the below plugins ( GzDialog.js) ) that needed to load a JSON of dialogs.
preload() {
this.load.json("scriptdata", "./assets/script.json");
}
I got this error
phaser.js:16099 Invalid JSON: scriptdata
I m just using the same JSON file as the author below… when i run his repo on phaser: “3.22.0”, there were no errors … I m on 3.55.2 at the moment …
{
"_description": "The script object contains a list of dialog responses for game characters. Top level properties reference the character doing the speaking. Child properties are the key name of the object spoken in response to.",
"zeta": {
"objectA": "Can't leave yet. I have a mission to complete.",
"objectB": "Ow!",
"labsign": "Hmm. This may be the entrance to the secret lab.",
"sportmodel": "It's just a weather balloon. Nothing to see here.",
"jello": "This old jalopy wouldn't get me to Alpha Centauri.",
"tr3b": "Never seen this one before. Hmm, it says TR-3B.",
"strawhat": "This one's a real classic. Aww. There's a big hole in the side. That's really going to wreck the resale value."
}
}