no message

git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@967 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
driAn
2007-04-23 19:43:02 +00:00
parent d18443005d
commit a1417b9b65
2 changed files with 7 additions and 3 deletions
+4 -2
View File
@@ -251,14 +251,16 @@ void moveplayer(physent *pl, int moveres, bool local, int curtime)
d = bounce->vel;
d.mul(speed);
if(water) { d.x /= 6; d.y /= 6; }
// rotate
float rotspeed = bounce->rotspeed*d.magnitude();
pl->pitch = fmod(pl->pitch+rotspeed, 360.0f);
pl->yaw = fmod(pl->yaw+rotspeed, 360.0f);
}
else // fake physics for player ents to create the great cube movement(TM)
else // fake physics for player ents to create _the_ cube movement (tm)
{
int move = pl->onladder && !pl->onfloor && pl->move == -1 ? 0 : pl->move; // fix movement on ladder
int move = pl->onladder && !pl->onfloor && pl->move == -1 ? 0 : pl->move; // movement on ladder
d.x = (float)(move*cosf(RAD*(pl->yaw-90)));
d.y = (float)(move*sinf(RAD*(pl->yaw-90)));