Back here again after a long hiatus (due to studying and lack of time to code for fun), but now back to make a 3D rail shooter
.
I have read through the DBC Tutorials.doc
that Latch put together and understand the issue DBC has with 3D animations where the angle passes through 120 degrees (Unfortunately the math is beyond my understanding).
Anyway, I was wondering if it is possible to use QuatMath.dll to correct the angles generated by set object keyframe
. I understand I could just use zrotate object to achieve the same effect as what I am doing in my code, but I was thinking of using angle correction in general with "set object keyframe".
sync on
sync rate 60
set display mode 1024,768,32
autocam off
load object "continue.x",1
load image "continue.jpg",1
texture object 1,1
rotate limb 1,1,0,0,0
set object keyframe 1,0
rotate limb 1,1,0,0,270
set object keyframe 1,10
rotate limb 1,1,0,0,180
set object keyframe 1,20
rem This is the problem keyframe (that needs correction)
rotate limb 1,1,0,0,90
set object keyframe 1,30
loop object 1
set object speed 1,2
position object 1,0.0,0.0,0.0
position camera 0,50,-160
point camera 0,0,0
do
text 0,0,STR$(screen fps())
color backdrop rgb(0,0,0)
sync
loop