forked from mirror/openmw-tes3mp
[Server] Remove GetAngleY & remove Y parameter from SetAngle
This commit is contained in:
parent
89f6c6df96
commit
186e5fe33e
2 changed files with 2 additions and 14 deletions
|
@ -3,7 +3,6 @@
|
||||||
#include <components/openmw-mp/NetworkMessages.hpp>
|
#include <components/openmw-mp/NetworkMessages.hpp>
|
||||||
#include <apps/openmw-mp/Player.hpp>
|
#include <apps/openmw-mp/Player.hpp>
|
||||||
#include <apps/openmw-mp/Networking.hpp>
|
#include <apps/openmw-mp/Networking.hpp>
|
||||||
#include <components/openmw-mp/Log.hpp>
|
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
@ -68,14 +67,6 @@ double PositionFunctions::GetAngleX(unsigned short pid) noexcept
|
||||||
return player->position.rot[0];
|
return player->position.rot[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
double PositionFunctions::GetAngleY(unsigned short pid) noexcept
|
|
||||||
{
|
|
||||||
Player *player;
|
|
||||||
GET_PLAYER(pid, player, 0.0f);
|
|
||||||
|
|
||||||
return player->position.rot[1];
|
|
||||||
}
|
|
||||||
|
|
||||||
double PositionFunctions::GetAngleZ(unsigned short pid) noexcept
|
double PositionFunctions::GetAngleZ(unsigned short pid) noexcept
|
||||||
{
|
{
|
||||||
Player *player;
|
Player *player;
|
||||||
|
@ -94,13 +85,12 @@ void PositionFunctions::SetPos(unsigned short pid, double x, double y, double z)
|
||||||
player->position.pos[2] = z;
|
player->position.pos[2] = z;
|
||||||
}
|
}
|
||||||
|
|
||||||
void PositionFunctions::SetAngle(unsigned short pid, double x, double y, double z) noexcept
|
void PositionFunctions::SetAngle(unsigned short pid, double x, double z) noexcept
|
||||||
{
|
{
|
||||||
Player *player;
|
Player *player;
|
||||||
GET_PLAYER(pid, player, );
|
GET_PLAYER(pid, player, );
|
||||||
|
|
||||||
player->position.rot[0] = x;
|
player->position.rot[0] = x;
|
||||||
player->position.rot[1] = y;
|
|
||||||
player->position.rot[2] = z;
|
player->position.rot[2] = z;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
\
|
\
|
||||||
{"GetAngle", PositionFunctions::GetAngle},\
|
{"GetAngle", PositionFunctions::GetAngle},\
|
||||||
{"GetAngleX", PositionFunctions::GetAngleX},\
|
{"GetAngleX", PositionFunctions::GetAngleX},\
|
||||||
{"GetAngleY", PositionFunctions::GetAngleY},\
|
|
||||||
{"GetAngleZ", PositionFunctions::GetAngleZ},\
|
{"GetAngleZ", PositionFunctions::GetAngleZ},\
|
||||||
\
|
\
|
||||||
{"SetPos", PositionFunctions::SetPos},\
|
{"SetPos", PositionFunctions::SetPos},\
|
||||||
|
@ -30,11 +29,10 @@ public:
|
||||||
|
|
||||||
static void GetAngle(unsigned short pid, float *x, float *y, float *z) noexcept;
|
static void GetAngle(unsigned short pid, float *x, float *y, float *z) noexcept;
|
||||||
static double GetAngleX(unsigned short pid) noexcept;
|
static double GetAngleX(unsigned short pid) noexcept;
|
||||||
static double GetAngleY(unsigned short pid) noexcept;
|
|
||||||
static double GetAngleZ(unsigned short pid) noexcept;
|
static double GetAngleZ(unsigned short pid) noexcept;
|
||||||
|
|
||||||
static void SetPos(unsigned short pid, double x, double y, double z) noexcept;
|
static void SetPos(unsigned short pid, double x, double y, double z) noexcept;
|
||||||
static void SetAngle(unsigned short pid, double x, double y, double z) noexcept;
|
static void SetAngle(unsigned short pid, double x, double z) noexcept;
|
||||||
|
|
||||||
static void SendPos(unsigned short pid) noexcept;
|
static void SendPos(unsigned short pid) noexcept;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue