A_SetTranslation
Jump to navigation
Jump to search
void A_SetTranslation (name transname)
Usage
Applies a TRNSLATE-defined translation to the calling actor. Unlike Thing_SetTranslation, this accepts an actual name instead of an ID.
Parameters
- transname: the name of the translation to use.
Examples
This is a regular zombie which has a pain state that allows it to be "glitched", randomly changing its stats, as well as changing its translation.
ACTOR GlitchyZombie : ZombieMan { States { Pain.Glitch: POSS G 1 A_PlaySound("Glitch/Explode") POSS G 1 A_GiveInventory("Glitcho", 1) POSS G 1 A_SetHealth(random(1, 200)) POSS G 1 A_SetSpecies("Glitchy") POSS G 1 A_SetMass(random(0, 1000)) POSS G 1 A_SetSpeed(random(10, 40)) POSS G 1 A_ChangeFlag("SPRITEFLIP", 1) POSS G 1 A_ChangeFlag("NOTIMEFREEZE", 1) POSS G 1 A_ChangeFlag("BRIGHT", 1) POSS G 1 A_SetTranslation("Glitch") POSS G 3 A_Pain Goto See } }