Dist: Difference between revisions

From EDukeWiki
Jump to navigation Jump to search
One (talk | contribs)
No edit summary
Corrected Dist. Dist:xyz, Ldist:xy
Line 1: Line 1:
'''dist''' <RETURNVAR> <SPRITE1> <SPRITE2>
'''dist''' <RETURNVAR> <SPRITE1> <SPRITE2>


Used to determine the distance between the bases of two actors' sprites.
Used to determine the distance between two sprites.


The RETURNVAR would be equal to the distance between the base of SPRITE1 and the base of SPRITE2. It is useful for locational damage, for example.
The RETURNVAR is equal to the distance between SPRITE1 and SPRITE2. Compare with [[Ldist]], which uses only x and y coordinates.
It is useful for locational damage, for example.


[[Category:EDuke32 specific commands]]
[[Category:EDuke32 specific commands]]
[[Category:Sprite manipulation]]
[[Category:Sprite manipulation]]

Revision as of 06:46, 4 August 2010

dist <RETURNVAR> <SPRITE1> <SPRITE2>

Used to determine the distance between two sprites.

The RETURNVAR is equal to the distance between SPRITE1 and SPRITE2. Compare with Ldist, which uses only x and y coordinates. It is useful for locational damage, for example.