Ifsquished: Difference between revisions

From EDukeWiki
Jump to navigation Jump to search
No edit summary
Removed misinformation and added actually useful info. SQUISHABLEDISTANCE is used in GAME.CON for the player to crush shrunk enemies and has nothing to do with this conditional.
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Checks if the current [[actor]] is in a sector where the distance between the ceiling and floor is equal to or less than SQUISHABLEDISTANCE, which is [[define]]d in USER.CON.
'''ifsquished''' { do something } else { do something else }
 
Checks if the current [[actor]] is in a sector where the distance between the ceiling and floor is below a hardcoded threshold.
 
Note that this conditional check is hardcoded to display quote #10 ("Squish!") if it returns true, even if no actor has actually been killed.


[[Category:Duke3D 1.3/1.5 commands]]
[[Category:Duke3D 1.3/1.5 commands]]
[[Category:Sprite manipulation]]
[[Category:If conditions]]
[[Category:If conditions]]

Latest revision as of 11:02, 22 August 2020

ifsquished { do something } else { do something else }

Checks if the current actor is in a sector where the distance between the ceiling and floor is below a hardcoded threshold.

Note that this conditional check is hardcoded to display quote #10 ("Squish!") if it returns true, even if no actor has actually been killed.