Just to add to the above feedback (which, again, may or may not be wanted - I'm not even sure how often RockstarRaccoon still visits), I have given this tool a major workout in the last week (some discussion about it can be found here:
viewtopic.php?t=80174 )
I have used the converter tool on many thousands of lines of DECORATE code (maybe 60,000 lines or probably more). The tool has all the problems/glitches that RockstarRaccoon said it would. I'm not complaining, merely noting that it happened (as expected). However, even though every file I tried came up with a glitch of some sort (often many glitches), the tool really does most of the heavy lifting and GZDoom's ability to pinpoint exactly where the problems were (which file files, and on which lines), made finding and correcting the problems straight forward. The vast majority of the time, the mistake was pretty obvious, as was the fix. It's just that with so much code, there were lots of glitches to deal with. That's on me as much as anything. Again, I'm still not complaining.
I did actually start to develop a "sixth sense" as to which code was likely to throw up problems. Sometimes, I would know exactly which lines were going to be problematic, at other times, I just had a "feeling" but wasn't sure exactly.
As I said before, translations often seem to lead to the tool giving up on putting ; at the end of lines, but not always. Sometimes it seems to parse them just fine. It seems to be more likely to cause a problem for complex translations, especially if they are split over several lines.
e.g. this is likely to cause a problem - weirdly, it doesn't always happen immediately, but further down in the actor, or even on the next one.
Code: Select all
TRANSLATION "112:127 = [203,0,0]:[12,0,0]",
"192:207 = [87,178,248]:[0,29,149]",
"240:247 = [0,17,109]:[0,1,32]"
Also, I think spaces at the end of lines can cause problems.
e.g. lines like this seem to often cause a problem:
It's not obvious, but there is a space after the 5 (which was clumsy of me in the original DECORATE). This would tend to generate code like this:
The brackets after the 5 are a problem, and GZDoom won't start until they are removed. There seem to be a few different cases where such brackets can end up in the code incorrectly. I haven't figured them all out. I *think* maybe comments directly after the number might also cause it.
e.g.
However, I don't think that any of the above happen 100% reliably - perhaps because of something else going on in the file - but they are common. In fact, stray () at the end of lines was one of the most common errors I got.
Sometimes
DamageType entries would appear with the specified damage type not given ""
i.e.
instead of
A similar thing happens with inventory icons. This DECORATE code...
e.g.
...would not be given "" around ARTIFLAR
Again, possibly clumsy DECORATE leads to this (i.e. if the DECORATE did not have "" (which works), then the generated ZScript won't (and that doesn't work).
I also found an actor type that never gets converted properly, and always messes up what comes after it: empty actors that inherit from something else.
e.g.
Code: Select all
ACTOR MyCoolActor2 : my MyCoolActor1
{}
Will generate this:
Code: Select all
CLASS MyCoolActor2 : my MyCoolActor1 {
Default {
}
{}
Which is borked (an extra { near the end), and everything after it will fail too.
Why would someone make such an actor? In my case, identical actors but with different models allocated to them in MODELDEF.
Sometimes other minimal inherited actors (i.e. similar to the one above but, perhaps, changing only one line) may have also caused problems, but I am less sure about that.
All that being said, I am extremely grateful for the tool. It isn't perfect; RockstarRaccoon never promised that it would be (indeed, they said it wouldn't be), but it did a lot of the dull, laborious, tedious conversion tasks for me (which is what RockstarRaccoon promised it would do) and, even though I spent a lot of time fixing up the results, it would not even have been possible for me to convert so much code without this util.
So, the conclusion is a big thank you.
