KatsBits Community

UnmatchedToken "({)"

kat · 1 · 22958

0 Members and 1 Guest are viewing this topic.

Offline kat

  • Administrator
  • Hero Member
  • *
    • Posts: 3132
    • KatsBits
Problem
I have a weird error. It started when I did something simple - retexturing two faces to caulk. Well, after I finished retexturing the second face, Radiant crashed (I have GTK 1.1.1, and I don't remember the error message. I get them all the time ). Well, I thought, "Oh well, no big deal. All I did was chage two textures, I'll just reload and redo it." Then I go to reload, and I get an error message about an "UnmatchedToken "({)"" (or something) and Radiant crashes again. I'm started to get frustrated now, so I load it up a second time, same error, but about a different line. Now I'm pretty mad. I open up the map file in a text editor and find weird characters (��`�, stuff like that), so, being that I had this stuff before, I deleted the brushes. [Pathogen]

Solution
An unmatched token message means that there's a "{" that lacks a matching "}" (or vice versa). The most frequent cause seems to be something going wrong at the very start of the .map file where the worldspawn info is. Open that .map file in a text editor, find an uncorrupted .map file, and copy over the missing info. You might also be able to use the map's .bak file to the same end provided there's nothing wrong with it. [Anwulf]



[Addendum] If the "UnmatchedToken" error occurs during compile the likely culprit is a brace ("{" or "}") missing from the *.map file. The error can also occur as a result of a malformed *.shader or any one of the many text-based files used in games powered by the engine but they won't necessarily crash the compiler with the "UnmatchedToken" error (although a similar error appears); for Return to Castle Wolfenstien or Enemy Territory for example the error can happen as a result of malformed *.ai, *.script, *.def files and so on, although with respect to the latter malformed or incomplete syntax tend to cause maps to crash when run in-game rather than halting the compile process. [kat]