2014-03-15 01:45:25 +00:00
|
|
|
|
|
|
|
#include "Globals.h" // NOTE: MSVC stupidness requires this to be the same across all modules
|
|
|
|
|
|
|
|
#include "HangingEntity.h"
|
|
|
|
#include "ClientHandle.h"
|
|
|
|
#include "Player.h"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-10-21 20:02:30 +00:00
|
|
|
cHangingEntity::cHangingEntity(eEntityType a_EntityType, eBlockFace a_Facing, double a_X, double a_Y, double a_Z) :
|
|
|
|
cEntity(a_EntityType, a_X, a_Y, a_Z, 0.8, 0.8),
|
2015-03-13 22:29:27 +00:00
|
|
|
m_Facing(cHangingEntity::BlockFaceToProtocolFace(a_Facing))
|
2014-03-15 01:45:25 +00:00
|
|
|
{
|
|
|
|
SetMaxHealth(1);
|
|
|
|
SetHealth(1);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void cHangingEntity::SpawnOn(cClientHandle & a_ClientHandle)
|
|
|
|
{
|
2015-03-13 22:29:27 +00:00
|
|
|
SetYaw(GetProtocolFacing() * 90);
|
2014-03-15 01:45:25 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|