D3DXMatrixTranslation(&matTransp,xpos,ypos,zpos);
D3DXMatrixRotationAxis(&matRot,&D3DXVECTOR3(0,0,zpos),-nagib);
D3DXMatrixRotationX(&matRot1, -D3DXToRadian(uX));
D3DXMatrixRotationY(&matRot2, -D3DXToRadian(uY));
D3DXMatrixMultiply(&matRot3, &matRot2, &matRot1);
D3DXMatrixMultiply(&matWorld, &matRot,&matTransp);
D3DXMatrixMultiply(&matWorld, &matRot3,&matWorld);
D3DDevice8->SetTransform(D3DTS_WORLD,&matWorld);
mes2->Render();
spaceship movements
OK! Can anyone tell me in short how to move my spaceship?
here is my code, but its not working very well!
What''s not working very well?
You have to give us more details.......
KaM1KaZ3
You have to give us more details.......
KaM1KaZ3
sorry, my mistake..
my camera is above ship constantly so its moving with my ship.
When I go left or right for 360 degrees only camera moves. my ship stays behind camera. i made my ship roll (90 degrees on z axe) so thats fine, but if my ship roll i want to be able to move with camera for 360 degrees. thats my problem..
tnx again..
my camera is above ship constantly so its moving with my ship.
When I go left or right for 360 degrees only camera moves. my ship stays behind camera. i made my ship roll (90 degrees on z axe) so thats fine, but if my ship roll i want to be able to move with camera for 360 degrees. thats my problem..
tnx again..
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement