what does GetAxes() do?

  • Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.
cool, thanks, that mostly makes sense, except that the example given:

GetAxes(rotation, X, Y, Z);
StartTrace = Location;
EndTrace = StartTrace + vector(rotation) * 10000;
Trace(HitLocation, HitNormal, EndTrace, StartTrace, True);
spawn(class'BlastMark',,,HitLocation);


never ends up using X, Y or Z after calling GetAxes and i've seen this same type of thing elsewhere, which makes me wonder if i'm missing something about the way it works. It doesn't do something to its first param too does it ("rotation" in this case)?
 

Wormbo

Administrator
Staff member
Jun 4, 2001
5,913
36
48
Germany
www.koehler-homepage.de
Originally posted by navboy
Looked around and couldn't find it anywhere in the actor hierarchy, is this a special function of some sort?

It's declared in Object (superclass of Actor, line 233):
Code:
native(229) static final function GetAxes (rotator A, out vector X, out vector Y, out vector Z);

What makes me wonder is the GetUnAxes() function right below that line. It uses the very same parameters, but what does it do?
 
hmm, well below i posted logging where i stood facing northwest and caused it to log both GetAxes and GetUnAxes, then faced west and did it again. It's not immediately obvious to me what it's doing but it almost strikes me as maybe using a left-handed coordinate system instead of a right-handed one?


facing Northwest:
ScriptLog: GetAxes gave X -0.665807,-0.744300,0.052132 Y 0.745327,-0.666699,0.000383 Z 0.034471,0.039110,0.998640 , InstigatorVelocity Dot X is 0.000000
ScriptLog: GetUnAxes gave X -0.665807,0.745327,0.034471 Y -0.744300,-0.666699,0.039110 Z 0.052132,0.000383,0.998640 , InstigatorVelocity Dot X is 0.000000


facing West:
ScriptLog: GetAxes gave X -0.999633,-0.007284,0.026075 Y 0.007286,-0.999973,0.000000 Z 0.026074,0.000190,0.999660 , InstigatorVelocity Dot X is 0.000000
ScriptLog: GetUnAxes gave X -0.999633,0.007286,0.026074 Y -0.007284,-0.999973,0.000190 Z 0.026075,0.000000,0.999660 , InstigatorVelocity Dot X is 0.000000