1
0

Removed obsoleted functions

This commit is contained in:
Tiger Wang
2014-01-16 19:00:49 +00:00
parent 5d03e49c13
commit 74645fdfaa
34 changed files with 67 additions and 74 deletions

View File

@@ -1396,7 +1396,7 @@ void cPlayer::TossItem(
}
}
double vX = 0, vY = 0, vZ = 0;
EulerToVector(-GetRotation(), GetPitch(), vZ, vX, vY);
EulerToVector(-GetRot().x, GetPitch(), vZ, vX, vY);
vY = -vY * 2 + 1.f;
m_World->SpawnItemPickups(Drops, GetPosX(), GetEyeHeight(), GetPosZ(), vX * 3, vY * 3, vZ * 3, true); // 'true' because created by player
}
@@ -1528,7 +1528,7 @@ bool cPlayer::LoadFromDisk()
Json::Value & JSON_PlayerRotation = root["rotation"];
if (JSON_PlayerRotation.size() == 3)
{
SetRotation ((float)JSON_PlayerRotation[(unsigned int)0].asDouble());
SetYaw ((float)JSON_PlayerRotation[(unsigned int)0].asDouble());
SetPitch ((float)JSON_PlayerRotation[(unsigned int)1].asDouble());
SetRoll ((float)JSON_PlayerRotation[(unsigned int)2].asDouble());
}
@@ -1591,7 +1591,7 @@ bool cPlayer::SaveToDisk()
JSON_PlayerPosition.append(Json::Value(GetPosZ()));
Json::Value JSON_PlayerRotation;
JSON_PlayerRotation.append(Json::Value(GetRotation()));
JSON_PlayerRotation.append(Json::Value(GetRot().x));
JSON_PlayerRotation.append(Json::Value(GetPitch()));
JSON_PlayerRotation.append(Json::Value(GetRoll()));