ACSUtils Wiki

An ACS library for ZDoom-based ports

User Tools

Site Tools


math

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
math [2019/04/20 19:58] – [Significant square roots and logarithms] korshunmath [2019/07/04 20:43] – [AnglesToVector] korshun
Line 315: Line 315:
  
 <note important>Remember that ZDoom uses inverted pitches on actors. ACSUtils functions don't invert pitches.</note> <note important>Remember that ZDoom uses inverted pitches on actors. ACSUtils functions don't invert pitches.</note>
 +
 +=== Example ===
 +
 +<code>
 +AnglesToVector(GetActorAngle(0), -GetActorPitch(0));
 +int dirX = r1;
 +int dirY = r2;
 +int dirZ = r3;
 +</code>
 +
 +
 ===== Logarithms ===== ===== Logarithms =====
  
Line 347: Line 358:
 <note important>Only bases higher than ''1.0'' are supported.</note> <note important>Only bases higher than ''1.0'' are supported.</note>
  
-<note important>Using ''ilogb'' with bases very close to ''1.0'' may produce a result that doesn't fit into a fixed.</note>+<note important>Using these functions with bases very close to ''1.0'' may produce a result that doesn't fit into a fixed.</note>
  
 Note that even the integer version has a fixed-point base. Note that even the integer version has a fixed-point base.
  
math.txt · Last modified: 2019/08/26 21:26 by korshun