mirror of
https://github.com/openmoh/openmohaa.git
synced 2025-05-06 19:01:04 +03:00
Actor Improvements p3_3
This commit is contained in:
parent
c665915d0f
commit
ec4ae7d79d
20 changed files with 322 additions and 503 deletions
|
@ -741,13 +741,13 @@ float vectoyaw( const vec3_t vec ) {
|
|||
if (vec[YAW] == 0 && vec[PITCH] == 0) {
|
||||
yaw = 0;
|
||||
} else {
|
||||
if (vec[PITCH]) {
|
||||
//if (vec[PITCH]) {
|
||||
yaw = ( atan2( vec[YAW], vec[PITCH]) * 180 / M_PI );
|
||||
} else if (vec[YAW] > 0) {
|
||||
yaw = 90;
|
||||
} else {
|
||||
yaw = 270;
|
||||
}
|
||||
//} else if (vec[YAW] > 0) {
|
||||
// yaw = 90;
|
||||
//} else {
|
||||
// yaw = 270;
|
||||
//}
|
||||
if (yaw < 0) {
|
||||
yaw += 360;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue