Page 1 of 2
TRNSLATE lump
Posted: Thu Sep 22, 2016 8:21 am
by Major Cooke
Instead of having to recompile ACS just to add a translation for Thing_SetTranslation, can't this be done in its own file instead? I much prefer less of a reason to recompile ACS and ruining save games for something that could be handled elsewhere.
Re: TRNSLATE lump
Posted: Thu Sep 22, 2016 10:09 am
by Gez
One of the things I wanted to do for ZDoom was setting the default translation in MAPINFO/GameInfo instead of hardcoding them. It would allow users to define more translations, too.
Re: TRNSLATE lump
Posted: Thu Sep 22, 2016 11:25 am
by Graf Zahl
Yes, it might be indeed a good idea to define a new class of translations in a dedicated lump and having them accessible from other parts of the engine.
Re: TRNSLATE lump
Posted: Sun Oct 02, 2016 5:36 am
by Graf Zahl
Done, except for some access functions.
Re: TRNSLATE lump
Posted: Sun Oct 02, 2016 5:54 am
by Gez
I would have preferred a ZMAPINFO block, but it's good nonetheless
.
Re: TRNSLATE lump
Posted: Sun Oct 02, 2016 6:08 am
by Graf Zahl
I think it's bullshit to lump every imaginable crap together in ZMAPINFO, especially if it has nothing to do with defining game flow or metadata for the levels.
The stuff that's there has all to do with defining the flow of the game, as in maps, episodes, skills and intermissions. The spawn and editor numbers are there because this is stuff that can be used to tailor the game late in the process (I occasionally have used it to replace monsters in mods where I wanted to tone down some overly hard maps.)
Translations are something entirely different, they have nothing to do with game metadata.
Re: TRNSLATE lump
Posted: Sun Oct 02, 2016 7:52 am
by Major Cooke
What's the syntax for using this?
Re: TRNSLATE lump
Posted: Sun Oct 02, 2016 8:16 am
by Graf Zahl
"translationname" = "sequence1", "sequence2", ... .
The sequences are the same as in DECORATE.
Or if you want to extend an existing translation:
"translationname" : "basename" = ...
Example
Code: Select all
GreenDemon = "16:47=112:127", "169:191=152:159"
Re: TRNSLATE lump
Posted: Sun Oct 02, 2016 8:27 am
by DoomKrakken
OH... MY... GOSH.
THIS IS PERFECT!!!!!
I never thought that creating a separate lump for defining Translations was even possible! There's definitely no need for a DECORATE counterpart now! This is equally easy!!!!!
Thank you guys so much!
Re: TRNSLATE lump
Posted: Sun Oct 02, 2016 10:32 am
by Major Cooke
One last question, to remove a translation, would you just use 0 or none?
Re: TRNSLATE lump
Posted: Sun Oct 02, 2016 10:58 am
by Graf Zahl
The empty string will restore the actor's default.
Re: TRNSLATE lump
Posted: Sun Oct 02, 2016 2:15 pm
by NeuralStunner
Sweet! This has the huge advantage of letting you reuse translations across a bunch of actors without running into the "magic numbers" problem.

Re: TRNSLATE lump
Posted: Sun Oct 02, 2016 2:40 pm
by Major Cooke
A shame string uservars can't happen, but oh well.
Re: TRNSLATE lump
Posted: Mon Oct 03, 2016 12:20 am
by DoomKrakken
So... wait a minute... in light of this new feature, is there now a way to have actors change translations, without the use of ACS? Or will we still need to use Thing_SetTranslation in order to get an actor to change its translation?
Re: TRNSLATE lump
Posted: Mon Oct 03, 2016 12:33 am
by Graf Zahl
I added both an ACS and a DECORATE function to set an actor's translation to one of these new ones.