Implented Spawn Experience Orb packet.
This commit is contained in:
@@ -17,6 +17,7 @@ Implements the 1.7.x protocol classes:
|
||||
#include "../World.h"
|
||||
#include "../WorldStorage/FastNBT.h"
|
||||
#include "../StringCompression.h"
|
||||
#include "../Entities/ExpOrb.h"
|
||||
#include "../Entities/Minecart.h"
|
||||
#include "../Entities/FallingBlock.h"
|
||||
#include "../Entities/Pickup.h"
|
||||
@@ -609,6 +610,20 @@ void cProtocol172::SendExperience (void)
|
||||
|
||||
|
||||
|
||||
void cProtocol172::SendExperienceOrb(const cEntity & a_Entity)
|
||||
{
|
||||
cPacketizer Pkt(*this, 0x11);
|
||||
Pkt.WriteVarInt(a_Entity.GetUniqueID());
|
||||
Pkt.WriteInt((int) a_Entity.GetPosX());
|
||||
Pkt.WriteInt((int) a_Entity.GetPosY());
|
||||
Pkt.WriteInt((int) a_Entity.GetPosZ());
|
||||
Pkt.WriteShort(((cExpOrb &)a_Entity).GetReward());
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
void cProtocol172::SendSoundEffect(const AString & a_SoundName, int a_SrcX, int a_SrcY, int a_SrcZ, float a_Volume, float a_Pitch) // a_Src coords are Block * 8
|
||||
{
|
||||
cPacketizer Pkt(*this, 0x29); // Sound Effect packet
|
||||
|
||||
Reference in New Issue
Block a user