Htflags: Difference between revisions

From EDukeWiki
Jump to navigation Jump to search
add label names
No edit summary
Line 1: Line 1:
A per-actor property, this controls special flags for sprites. In the following listing, whenever a label for a value is defined in the global CON namespace by default, it is shown after the numeric value:
A per-actor property, this controls special flags for sprites.
 
{| {{prettytable}}
'''1'''  - SFLAG_SHADOW - Generates a shadow. See [[spriteshadow]].<br />
!Internal Name!!Provided CON Label!!Value!!Description
'''2'''  - SFLAG_NVG - Turns [[spritepal|palette]] 6 whenever night vision goggles are used. See [[spritenvg]].<br />
|-
'''4'''  - SFLAG_NOSHADE - The sprite's shade is unaffected by the shade of its sector. See [[spritenoshade]].<br />
|SFLAG_SHADOW||SFLAG_SHADOW||1||Generates a shadow. See [[spriteshadow]].
'''8'''  - Is a [[defineprojectile|projectile]].<br />
|-
'''16'''  - Prevents teleporting. The sprite is not entered into the [[decal deletion queue]].<br />
|SFLAG_NVG||SFLAG_NVG||2||Turns [[spritepal|palette]] 6 whenever night vision goggles are used. See [[spritenvg]].
'''32'''  - SFLAG_BADGUY - Is an enemy. See [[useractor]].<br />
|-
'''64'''  - SFLAG_NOPAL - Sprite will be insusceptible to floor palette of sector containing this sprite. See [[spritenopal]].<br />
|SFLAG_NOSHADE||SFLAG_NOSHADE||4||The sprite's shade is unaffected by the shade of its sector. See [[spritenoshade]].
'''128''' - SFLAG_NOEVENTS - Sprite will not be run through [[event]] code.<br />
|-
'''256''' - SFLAG_NOLIGHT - Sprite will not emit hardcoded Polymer-based lights.<br />
|SFLAG_PROJECTILE||||8||Is a [[defineprojectile|projectile]].
'''512''' - SFLAG_USEACTIVATOR - ''needs description''<br />
|-
'''1024''' - internal, do not use<br />
|SFLAG_DECAL||||16||Prevents teleporting. The sprite is not entered into the [[decal deletion queue]].
'''2048''' - SFLAG_NOCLIP - Sprite will call "[[clipmove]]()" with a [[clipmask]] of 0, skipping collision detection with other sprites to increase performance. (Specifically, to prevent runtime behavior that is quadratic with the number of sprites.) Useful for particle effects.<br />
|-
SFLAG_SMOOTHMOVE - ''needs description''<br />
|SFLAG_BADGUY||SFLAG_BADGUY||32||Is an enemy. See [[useractor]].
SFLAG_NOTELEPORT - ''needs description''<br />
|-
|SFLAG_NOPAL||SFLAG_NOPAL||64||Sprite will be insusceptible to floor palette of sector containing this sprite. See [[spritenopal]].
|-
|SFLAG_NOEVENTCODE||SFLAG_NOEVENTS||128||Sprite will not be run through [[EVENT_GAME]] or [[EVENT_PREGAME]].
|-
|SFLAG_NOLIGHT||SFLAG_NOLIGHT||256||Sprite will not emit hardcoded Polymer-based lights.
|-
|SFLAG_USEACTIVATOR||SFLAG_USEACTIVATOR||512||
|-
|<font color="gray">SFLAG_NULL</font>||||<font color="gray">1024</font>||<font color="gray">null sprite in multiplayer [internal, do not use]</font>
|-
|SFLAG_NOCLIP||SFLAG_NOCLIP||2048||Sprite will call "[[clipmove]]()" with a [[clipmask]] of 0, skipping collision detection with other sprites to increase performance. (Specifically, to prevent runtime behavior that is quadratic with the number of sprites.) Useful for particle effects.
|-
|SFLAG_NOFLOORSHADOW||||4096||
|-
|SFLAG_SMOOTHMOVE||SFLAG_SMOOTHMOVE||8192||
|-
|SFLAG_NOTELEPORT||SFLAG_NOTELEPORT||16384||
|-
|SFLAG_BADGUYSTAYPUT||||32768||
|-
|SFLAG_CACHE||||65536||
|-
|SFLAG_ROTFIXED||||131072||rotation-fixed with respect to a pivot point to prevent position diverging due to roundoff error accumulation
|-
|SFLAG_HARDCODED_BADGUY||||262144
|-
|SFLAG_DIDNOSE7WATER||||524288||used temporarily
|}


'''htflags''' is a [[bitfield]], so add together the values you want and then set htflags to the sum.<br/>
'''htflags''' is a [[bitfield]], so add together the values you want and then set htflags to the sum.<br/>

Revision as of 22:45, 27 February 2014

A per-actor property, this controls special flags for sprites.

Internal Name Provided CON Label Value Description
SFLAG_SHADOW SFLAG_SHADOW 1 Generates a shadow. See spriteshadow.
SFLAG_NVG SFLAG_NVG 2 Turns palette 6 whenever night vision goggles are used. See spritenvg.
SFLAG_NOSHADE SFLAG_NOSHADE 4 The sprite's shade is unaffected by the shade of its sector. See spritenoshade.
SFLAG_PROJECTILE 8 Is a projectile.
SFLAG_DECAL 16 Prevents teleporting. The sprite is not entered into the decal deletion queue.
SFLAG_BADGUY SFLAG_BADGUY 32 Is an enemy. See useractor.
SFLAG_NOPAL SFLAG_NOPAL 64 Sprite will be insusceptible to floor palette of sector containing this sprite. See spritenopal.
SFLAG_NOEVENTCODE SFLAG_NOEVENTS 128 Sprite will not be run through EVENT_GAME or EVENT_PREGAME.
SFLAG_NOLIGHT SFLAG_NOLIGHT 256 Sprite will not emit hardcoded Polymer-based lights.
SFLAG_USEACTIVATOR SFLAG_USEACTIVATOR 512
SFLAG_NULL 1024 null sprite in multiplayer [internal, do not use]
SFLAG_NOCLIP SFLAG_NOCLIP 2048 Sprite will call "clipmove()" with a clipmask of 0, skipping collision detection with other sprites to increase performance. (Specifically, to prevent runtime behavior that is quadratic with the number of sprites.) Useful for particle effects.
SFLAG_NOFLOORSHADOW 4096
SFLAG_SMOOTHMOVE SFLAG_SMOOTHMOVE 8192
SFLAG_NOTELEPORT SFLAG_NOTELEPORT 16384
SFLAG_BADGUYSTAYPUT 32768
SFLAG_CACHE 65536
SFLAG_ROTFIXED 131072 rotation-fixed with respect to a pivot point to prevent position diverging due to roundoff error accumulation
SFLAG_HARDCODED_BADGUY 262144
SFLAG_DIDNOSE7WATER 524288 used temporarily

htflags is a bitfield, so add together the values you want and then set htflags to the sum.
This member can also be set using the per-sprite form of the spriteflags command.