About Store Forum Documentation Contact



Post Reply 
Matrix rotation.
Author Message
Dampire Offline
Member

Post: #1
Matrix rotation.
I need to make a bullet, which fly forward and rotates on its axis. How I can do it?
When I do so
Code:
m.setRotateX(Time.time()* angle_delta);
      m.move(new_pos);
bullet has no direction...
When I do so
Code:
m.setRotateX(Time.time()* angle_delta);
      m.setPosDir(new_pos, dir);
bullet has no rotation.
08-03-2010 10:29 AM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #2
RE: Matrix rotation.
in the main loop you can do m.orn().rotateX(Time.d())
08-03-2010 11:46 AM
Find all posts by this user Quote this message in a reply
Dampire Offline
Member

Post: #3
RE: Matrix rotation.
Yep, it's work. Thank's.
But the code is a bit different
Code:
m.orn.rotateZVec(Time.d());
In any case, thankssmile
08-03-2010 03:59 PM
Find all posts by this user Quote this message in a reply
Arikin Offline
Member

Post: #4
RE: Matrix rotation.
Huh, I've similar problem, but this solution doesn't work. I have Player class based on Chr struct... When e.g. I look up, head goes up too... And I need rotate whole Player as head is rotating. I tried many codes in many places but it doesn't work. Can you help me?
08-11-2010 06:41 PM
Find all posts by this user Quote this message in a reply
Post Reply