TRNSLATE lump

Moderator: GZDoom Developers

User avatar
Major Cooke
Posts: 8209
Joined: Sun Jan 28, 2007 3:55 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 10
Graphics Processor: nVidia with Vulkan support
Location: GZBoomer Town
Contact:

TRNSLATE lump

Post 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.
Gez
 
 
Posts: 17939
Joined: Fri Jul 06, 2007 3:22 pm

Re: TRNSLATE lump

Post 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.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49227
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: TRNSLATE lump

Post 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.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49227
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: TRNSLATE lump

Post by Graf Zahl »

Done, except for some access functions.
Gez
 
 
Posts: 17939
Joined: Fri Jul 06, 2007 3:22 pm

Re: TRNSLATE lump

Post by Gez »

I would have preferred a ZMAPINFO block, but it's good nonetheless
.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49227
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: TRNSLATE lump

Post 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.
User avatar
Major Cooke
Posts: 8209
Joined: Sun Jan 28, 2007 3:55 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 10
Graphics Processor: nVidia with Vulkan support
Location: GZBoomer Town
Contact:

Re: TRNSLATE lump

Post by Major Cooke »

What's the syntax for using this?
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49227
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: TRNSLATE lump

Post 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"
User avatar
DoomKrakken
Posts: 3489
Joined: Sun Oct 19, 2014 6:45 pm
Location: Plahnit Urff
Contact:

Re: TRNSLATE lump

Post 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!
User avatar
Major Cooke
Posts: 8209
Joined: Sun Jan 28, 2007 3:55 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 10
Graphics Processor: nVidia with Vulkan support
Location: GZBoomer Town
Contact:

Re: TRNSLATE lump

Post by Major Cooke »

One last question, to remove a translation, would you just use 0 or none?
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49227
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: TRNSLATE lump

Post by Graf Zahl »

The empty string will restore the actor's default.
User avatar
NeuralStunner
 
 
Posts: 12328
Joined: Tue Jul 21, 2009 12:04 pm
Preferred Pronouns: No Preference
Operating System Version (Optional): Windows 11
Graphics Processor: nVidia with Vulkan support
Location: capital N, capital S, no space
Contact:

Re: TRNSLATE lump

Post 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. :D
User avatar
Major Cooke
Posts: 8209
Joined: Sun Jan 28, 2007 3:55 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 10
Graphics Processor: nVidia with Vulkan support
Location: GZBoomer Town
Contact:

Re: TRNSLATE lump

Post by Major Cooke »

A shame string uservars can't happen, but oh well.
User avatar
DoomKrakken
Posts: 3489
Joined: Sun Oct 19, 2014 6:45 pm
Location: Plahnit Urff
Contact:

Re: TRNSLATE lump

Post 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?
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49227
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: TRNSLATE lump

Post by Graf Zahl »

I added both an ACS and a DECORATE function to set an actor's translation to one of these new ones.
Post Reply

Return to “Closed Feature Suggestions [GZDoom]”