User:Jekyll Grim Payne/Actor properties modified
Jump to navigation
Jump to search
Behavior
- Health value
Related field(s) in ZScript | Data type | How to read | How to modify |
---|---|---|---|
health | int | Readable directly | A_SetHealth |
- Defines the health a monster or any other shootable item starts with.
- Default is 1000.
- Warning: Modifying this property directly dynamically is not the same as healing or dealing damage. See GiveBody for healing and DamageMobj for dealing damage.
- GibHealth value
Related field(s) in ZScript | Data type | How to read | How to modify |
---|---|---|---|
gibhealth | int | GetGibHealth | Modifiable directly |
- Defines the (negative) health below which this actor enters the extreme death sequence. If this is not set the value depends on the game, as defined in the GameInfo definition with the gibfactor property. In Doom it is the negative of the spawn health, in the other games the half of the negative of the spawn health.
- WoundHealth value
Related field(s) in ZScript | Data type | How to read | How to modify |
---|---|---|---|
WoundHealth | int | Readable directly | Modifiable directly |
- Defines the health below which the actor enters the Wound state. The default is 6.
- ReactionTime value
Related field(s) in ZScript | Data type | How to read | How to modify |
---|---|---|---|
ReactionTime | int | Readable directly | Modifiable directly A_Countdown |
- Time in tics (1/35 seconds) a monster takes to attack after being alerted. Attacking a monster will cause it to return attack immediately, regardless of reaction time. A negative value will cause a monster to never attack unless attacked first. There is normally no need to change this value but it can be used as a counter for A_Countdown.
- Default is 8.
- PainChance value
Related field(s) in ZScript | Data type | How to read | How to modify |
---|---|---|---|
PainChance | int | Readable directly | Modifiable directly A_Countdown |
- PainChance damagetype, value
- Probability of entering the pain state (256 = always, 0 = never). You can also specify PainChance per damage type. Sources of damage that have the FORCEPAIN flag ignore this property.
- Default is 0.
- PainThreshold value
- Minimum amount of damage required by the actor to potentially enter its Pain state. Sources of damage that have the FORCEPAIN flag ignore this property.
- Default is 0.
- DamageFactor type, value
- DamageFactor value
- If the actor takes damage of the specified type, that damage is multiplied by the specified value.
- A comma is required between type and value. value can be a decimal value; zero means the actor is completely immune to this kind of damage.
- Default is 1.0.
- The maximum this value can go is 32767. DamageFactor is ignored if the damage is 1,000,000 or more.
- See also Custom damage types
- If no type is provided, the factor applies to all damage types, not specified for the actor.
- SelfDamageFactor value
- A multiplier for self-inflicted damage. This is ignored if the damage is 1,000,000 or more.
- Default is 1.0.
- DamageMultiply value
- Generic damage multiplier. This is typically used on actors (e.g monsters) to strengthen or weaken the damage they deal from their attacks.
- Default is 1.0.
- Damage value
- Damage (expression) (DECORATE only)
- For a projectile defines the damage it inflicts upon impact. The formula is random(1,8) * damage, or random(1,4) * damage if the STRIFEDAMAGE flag is set.
- This also defines the damage for actors which attack like the Lost Soul. The formula for this is random(1,8) * damage.
- damage is also used to define how many bullets are fired by the generic hitscan attack function A_BulletAttack.
- Custom damage formulas can be specified by enclosing the value completely within parenthesis. For example: damage (random(4,8) * 5 + 6). This bypasses the normal calculation and does the exact damage resulting from the custom formula. Also, ACS_ExecuteWithResult and user variables can be used as part of the damage expression; this allows for more sophisticated damage calculations to be performed. The damage formula is evaluated at the moment the actor causes damage (e.g. projectile/hitscan impact).
- Warning: Custom damage expressions can be defined but will NOT actually work in ZScript (even though console log will not display any errors). Use DamageFunction (described below) to use a custom expression in ZScript.
- Default is 0.
- DamageFunction (expression) (ZScript only)
- DamageFunction FormulaName() (ZScript only)
- Similar to Damage, it defines the damage of the actor. What is passed is always treated as an expression, be it a single value or a formula, and is not subject to randomization like the case can be with Damage. This property and Damage are considered to be the same property, i.e. an actor can only have one or the other, but not both.
- Deal exact damage without randomization:
DamageFunction (10);
- Uses an expression for customized randomization:
DamageFunction (5 * random(3,5));
- Uses a custom damage function (which is a custom function that returns an int):
Default { DamageFunction MyDamageCalculation(); } int MyDamageCalculation() { // Some kind of custom calculation return someIntegerValue; //return an int }
- Note that the function must be defined as a normal function, outside of the Default block. The function can use any name.
- PoisonDamage value [, duration [, period]]
- Gives a projectile poison damage. Poison damage is not inflicted all at once, but affects the victim for a certain amount of time. The value specified here defines the time the poisoning effect lasts. Remember, poison damage only affects players if only value is specified (Hexen-style poison). Otherwise, it also affects other actors (ZDoom-style poison).
- Poison damage is inflicted every period tics (the default value of 0 means once per second). If a non-zero duration is given, it is used for the total length of the poisoning, otherwise the length depends on the value. See also ADDITIVEPOISONDAMAGE and ADDITIVEPOISONDURATION.
- PoisonDamageType type
- Changes the damage type of poison, overriding its default type.
- RadiusDamageFactor value
- Defines the factor radius damage on this actor is multiplied by.
- RipperLevel value
- Used by projectiles or anything capable of performing with the RIPPER flag. Specifies the 'level' or how high up a projectile can rip through in terms of monsters with different minimum and maximum values.
- A projectile that is below a monster's minimum or above maximum means that projectile will not rip through them. All ripper properties are ignored if the DONTRIP flag is present on the monster, though, and will not rip regardless of level through that particular monster.
- When used on a monster, however, and no min or max is defined, only that specific level can rip through it.
- The value can be negative for this, RipLevelMin and RipLevelMax.
- RipLevelMin value
- Used by monsters. Only projectiles that meet this level or higher can rip through this monster. Default is 0.
- RipLevelMax value
- Used by monsters. Only projectiles that meet this level or lower can rip through this monster. Default is 0, which means anything above the minimum can rip through it.
- DesignatedTeam number
- Assigns the actor to the specified team by its number from TEAMINFO. In team play, the actor will not take friendly fire from teammates unless the teamdamage console variable is set. If the monster is friendly, it will not target teammates.
- Default is no team.
- Speed value
- Defines how fast an actor moves. For projectiles this is the distance it moves per tic (1/35 seconds). For monsters it defines the size of one step done in A_Chase. Player's movement speed also depends on the Player.ForwardMove property.
- Default is 0.
- VSpeed value
- Gives an actor an initial vertical momentum. The higher the value, the more momentum. This is mainly used for special effect actors (e.g. weapon puffs) with the NOGRAVITY flag to make them float upwards.
- FastSpeed value
- Defines the speed for 'fast monsters' and nightmare mode. Please note that if you use this with a monster that monster will have the different speed for the rest of its life. Fast Monster's mode will make monsters and projectiles use their FastSpeed property instead of their defined speed when +fastmonsters or +alwaysfast flag is used. Fast monsters halves the duration of actor states with the Fast keyword. Fast monsters can be set in many ways like using the +ALWAYSFAST flag or +fastmonsters.
- FloatSpeed value
- Defines the speed the object floats up/down when FLOAT flag is set.
- Default is 4.
- Species string
- Defines the species the monster belongs to. This determines infighting behavior, since a monster's missile do not inflict harm (except through splash damage) to other monsters belonging to the same species by default.
- When used with keys, this property allows for new keys to open the same locks as the keys they are referencing with the property, without the need to redefine the locks to add the new keys. For example, setting the key's species to RedCard will allow it to open locks as if it were a red keycard.
- Default is None that makes the game to look up the actor this actor inherits from and has this property set to something else.
- Accuracy value
- Defines the object's accuracy. The higher the value, the more accurate the object is said to be.
- For players, this value is factored into the accuracy calculation for Strife's native weapon-firing functions.
- For monsters and other actors, this value has no predetermined effect, but it can be referenced in other places via the accuracy DECORATE variable and the APROP_Accuracy actor property.
- Stamina value
- Defines the object's stamina.
- For players, each point of stamina will add one point to the player's maximum health pool. The value is also used in the damage calculation for Strife's punch dagger.
- For monsters and other actors, this value has no predetermined effect, but it can be referenced in other places via the stamina DECORATE variable and the APROP_Stamina actor property.
- Activation flags
- Defines how the actor will execute its special. In addition to that, some of these flags allow the actor to call its Activate and Deactivate virtual functions. The details are covered on the Activation page.
- The following flags are available (multiple flags can be combined with
|
between them):
- THINGSPEC_Default — default behavior. This allows the actor to execute its special by being killed, used (with the USESPECIAL flag) or bumped (with the BUMPSPECIAL flag). The trigger (bumper/user/killer) is considered the activator, and only players can trigger this actor.
- THINGSPEC_ThingActs — the actor itself is considered the activator.
- THINGSPEC_TriggerActs — the trigger is considered the activator. This is the default behavior except for specials activated upon the thing's death in maps with the ActivateOwnDeathSpecials level flag. This flag overrides the MAPINFO flag.
- THINGSPEC_ThingTargets — the actor changes its target field to the activator when triggered.
- THINGSPEC_TriggerTargets — the activator changes its target field to this actor when it triggers it.
- THINGSPEC_MonsterTrigger — monsters are allowed to trigger this actor.
- THINGSPEC_MissileTrigger — missiles are allowed to trigger this actor.
- THINGSPEC_ClearSpecial — the actor's special is cleared after execution.
- THINGSPEC_NoDeathSpecial — the actor's special will not execute on death. (This means that it can only be executed by the player provided the actor has USESPECIAL or BUMPSPECIAL.)
- THINGSPEC_Activate — same as THINGSPEC_Default but in addition to that, if the actor is triggered by the player via USESPECIAL or BUMPSPECIAL, the actor will call its Activate ZScript virtual (only once).
- THINGSPEC_Deactivate — same as THINGSPEC_Default but in addition to that, if the actor is triggered by the player via USESPECIAL or BUMPSPECIAL, the actor will call its Deactivate ZScript virtual (only once).
- THINGSPEC_Switch — same as THINGSPEC_Default but in addition to that, if the actor is triggered by the player via USESPECIAL or BUMPSPECIAL, the actor will alternate between calling its Activate and Deactivate virtuals when triggered. By default, it will call Activate the first time it's triggered, but if this is used in conjunction with THINGSPEC_Deactivate, it will call Deactivate first instead.
- Note, for the USESPECIAL/BUMPSPECIAL flags to be effective, the actor also needs the SOLID flag.
- TeleFogSourceType classname
- Defines the fog to leave behind when an actor teleports away. Can be changed with A_SetTeleFog.
- Default is TeleportFog.
- TeleFogDestType classname
- Defines the fog the actor will spawn once it arrives. Can be changed with A_SetTeleFog.
- Default is TeleportFog.
- Threshold value
- Defines how long an actor will stick to one target after switching targets caused by infighting. e.g. if an imp changes targets because it was shot by a zombieman, it must call A_Chase this many times before it's ready to switch again. Note that further attacks which cause pain from the same target reset this value, making them stick with that target longer. QUICKTORETALIATE overwrites this property, and the property is adjustable with A_SetChaseThreshold. Note that this property is reset to DefThreshold, allowing monsters to have flexible infighting timers.
- DefThreshold value
- Sets the default threshold reset value when the actor switches monster infighting. Adjustable with A_SetChaseThreshold.
- FriendlySeeBlocks value
- (Warning: setting this property to high values is not recommended, as it could have a negative impact on performance.)
- Defines the maximum radius that a friendly monster or unfriendly monster with SEEFRIENDLYMONSTERS on can see enemies within. This is measured in blocks of 128x128 map units.
- Default is 10 (1280 map units).
- ShadowAimFactor value
- Defines how much the actors' aim is degraded when shooting at actors with SHADOW and/or SHADOWBLOCK. Allowing the shooter to be better or worse at shooting shadow actors than normal. Default is 1.0.
- ShadowPenaltyFactor value
- Used by actors with SHADOW and/or SHADOWBLOCK to increase or decrease the amount by which they worsen the aim of actors shooting at or through them by. Default is 1.0.