diff options
author | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-08-24 09:58:26 +0200 |
---|---|---|
committer | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-08-24 09:58:26 +0200 |
commit | e92b9e7ecbdf2918aab59d4eeb7bb5966430b264 (patch) | |
tree | 1a998d44e5faab91c54ea8517dd9fa02b3732ef7 /source/cMonster.cpp | |
parent | Added plugin name to deprecation messages (diff) | |
download | cuberite-e92b9e7ecbdf2918aab59d4eeb7bb5966430b264.tar cuberite-e92b9e7ecbdf2918aab59d4eeb7bb5966430b264.tar.gz cuberite-e92b9e7ecbdf2918aab59d4eeb7bb5966430b264.tar.bz2 cuberite-e92b9e7ecbdf2918aab59d4eeb7bb5966430b264.tar.lz cuberite-e92b9e7ecbdf2918aab59d4eeb7bb5966430b264.tar.xz cuberite-e92b9e7ecbdf2918aab59d4eeb7bb5966430b264.tar.zst cuberite-e92b9e7ecbdf2918aab59d4eeb7bb5966430b264.zip |
Diffstat (limited to '')
-rw-r--r-- | source/cMonster.cpp | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/source/cMonster.cpp b/source/cMonster.cpp index a7c05977e..24d790dc3 100644 --- a/source/cMonster.cpp +++ b/source/cMonster.cpp @@ -11,8 +11,6 @@ #include "cMonsterConfig.h" #include "MersenneTwister.h" -#include "packets/cPacket_SpawnMob.h" - #include "Vector3f.h" #include "Vector3i.h" #include "Vector3d.h" @@ -78,18 +76,9 @@ bool cMonster::IsA( const char* a_EntityType ) -cPacket * cMonster::GetSpawnPacket(void) const +void cMonster::SpawnOn(cClientHandle & a_Client) { - cPacket_SpawnMob * Spawn = new cPacket_SpawnMob; - Spawn->m_UniqueID = GetUniqueID(); - Spawn->m_Type = m_MobType; - *Spawn->m_Pos = ((Vector3i)(m_Pos)) * 32; - Spawn->m_Yaw = 0; - Spawn->m_Pitch = 0; - Spawn->m_MetaDataSize = 1; - Spawn->m_MetaData = new char[Spawn->m_MetaDataSize]; - Spawn->m_MetaData[0] = 0x7f; // not on fire/crouching/riding - return Spawn; + a_Client.SendSpawnMob(*this); } |