Mercurial > mm7
changeset 2162:5e1f535bad58
ODM_ProcessPartyActions continue
author | Ritor1 |
---|---|
date | Tue, 14 Jan 2014 17:29:20 +0600 |
parents | 86c9c8e207d5 |
children | 9aa0a5d90454 |
files | Outdoor.cpp |
diffstat | 1 files changed, 11 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/Outdoor.cpp Mon Jan 13 17:32:00 2014 +0600 +++ b/Outdoor.cpp Tue Jan 14 17:29:20 2014 +0600 @@ -3996,20 +3996,20 @@ { *(float *)&v128 = _walk_speed; - float sin_y = sinf(2 * 3.141592653589 * _angle_y / 2048.0), - cos_y = cosf(2 * 3.141592653589 * _angle_y / 2048.0); + float sin_y = sinf(2 * 3.141592653589 * _angle_y / 2048.0); + float cos_y = cosf(2 * 3.141592653589 * _angle_y / 2048.0); int dx = cos_y * pParty->uWalkSpeed * fWalkSpeedMultiplier; int dy = sin_y * pParty->uWalkSpeed * fWalkSpeedMultiplier; - if (pParty->bFlying) + if (pParty->bFlying)//лететь вперёд { v2 += 4 * dx; v1 += 4 * dy; v128 = v1; } - else if (partyAtHighSlope && !bmodel_standing_on_pid) + else if (partyAtHighSlope && !bmodel_standing_on_pid)//сбегание со склона { v2 += dx; v1 += dy; @@ -4019,8 +4019,13 @@ } else { - v2 += 2 * dx; - v1 += 2 * dy; + v2 += (unsigned __int64)(stru_5C6E00->Cos(_angle_y) + * (signed __int64)(signed int)(2 * (unsigned __int64)(signed __int64)((double)_walk_speed * fWalkSpeedMultiplier))) >> 16; + v1 += (unsigned __int64)((signed int)stru_5C6E00->Sin(_angle_y) + * (signed __int64)(signed int)(2 * (unsigned __int64)(signed __int64)((double)_walk_speed * fWalkSpeedMultiplier))) >> 16; + + /*v2 += 2 * dx;//original -228, now -222 it's temporarily + v1 += 2 * dy;//original -2295, now -2292*/ v128 = v1; party_running_flag = true;