Solarus-Games English Forum

Solarus => Development => Topic started by: YoshiMario2000 on July 27, 2015, 09:42:18 PM

Title: Error: Failed to load data file: [string "data file"]:2592: '}' expected (to clo
Post by: YoshiMario2000 on July 27, 2015, 09:42:18 PM
Error: Failed to load data file: [string "data file"]:2592: '}' expected (to close '{' at line 2588) near ']'

I have no idea what this means. Or where to fix it.
Title: Re: Error: Failed to load data file: [string "data file"]:2592: '}' expected (to clo
Post by: DementedKirby on July 27, 2015, 10:15:28 PM
Check line 2592 to see if it's there directly or check to see if you've correctly closed all functions.
Title: Re: Error: Failed to load data file: [string "data file"]:2592: '}' expected (to clo
Post by: Christopho on July 27, 2015, 10:23:30 PM
When do you have this error message? In the engine or the editor? Does it appear when opening a particular file in the editor?
Title: Re: Error: Failed to load data file: [string "data file"]:2592: '}' expected (to clo
Post by: YoshiMario2000 on July 27, 2015, 11:08:22 PM
Quote from: Christopho on July 27, 2015, 10:23:30 PM
When do you have this error message? In the engine or the editor? Does it appear when opening a particular file in the editor?
It's in the ERROR.TXT file and seems to generate on startup of solarus.exe, but only for my quest witch I'm building
Title: Re: Error: Failed to load data file: [string "data file"]:2592: '}' expected (to clo
Post by: Christopho on July 28, 2015, 10:12:44 AM
I think there is something wrong in your dialogs file. Open it with a text editor like Notepad++ (languages/xx/text/dialogs.dat) and check lines 2588-2592.
Maybe there is a bug in the quest editor, that generated a file with a wrong syntax. Probably because of an unexpected character a dialog.
Title: Re: Error: Failed to load data file: [string "data file"]:2592: '}' expected (to clo
Post by: YoshiMario2000 on July 28, 2015, 04:25:19 PM
Found it, Apparently the dialog thought that this:

dialog{
  id = "dungeonintro.1",
  text = [[

    [Town's Temple]
]]
}



when put in the editor, Became this:

dialog{
  id = "dungeonintro.1",
  text = [[

    [Town's Temple]]]
}



Witch broke it.  So just to be safe I'll just do this for now:

dialog{
  id = "dungeonintro.1",
  text = [[

    {Town's Temple}
]]
}
Title: Re: Error: Failed to load data file: [string "data file"]:2592: '}' expected (to clo
Post by: Christopho on July 28, 2015, 05:34:46 PM
Ok, so there is a bug with the square brackets characters. Thanks for the feedback!