diff options
author | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-03-14 21:56:09 +0100 |
---|---|---|
committer | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-03-14 21:56:09 +0100 |
commit | 0b24efeb005e293a026f2ac8666020cea8316578 (patch) | |
tree | 4523c34112fbec3f056337191c00bddb6f7253d0 /source/ChunkSender.h | |
parent | Fixed the server not waiting for the world to save completely before stopping (diff) | |
download | cuberite-0b24efeb005e293a026f2ac8666020cea8316578.tar cuberite-0b24efeb005e293a026f2ac8666020cea8316578.tar.gz cuberite-0b24efeb005e293a026f2ac8666020cea8316578.tar.bz2 cuberite-0b24efeb005e293a026f2ac8666020cea8316578.tar.lz cuberite-0b24efeb005e293a026f2ac8666020cea8316578.tar.xz cuberite-0b24efeb005e293a026f2ac8666020cea8316578.tar.zst cuberite-0b24efeb005e293a026f2ac8666020cea8316578.zip |
Diffstat (limited to '')
-rw-r--r-- | source/ChunkSender.h | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/source/ChunkSender.h b/source/ChunkSender.h index 3c77c4210..b5b58b854 100644 --- a/source/ChunkSender.h +++ b/source/ChunkSender.h @@ -26,7 +26,7 @@ Note that it may be called by world's BroadcastToChunk() if the client is still #pragma once
#include "cIsThread.h"
-#include "cChunk.h"
+#include "ChunkDef.h"
#include "packets/cPacket.h"
@@ -42,7 +42,7 @@ class cClientHandle; class cChunkSender:
public cIsThread,
- public cChunkDataCallback
+ public cChunkDataCollector
{
typedef cIsThread super;
public:
@@ -101,18 +101,17 @@ protected: cEvent m_evtRemoved; // Set when removed clients are safe to be deleted
// Data about the chunk that is being sent:
- char m_BlockData[cChunk::c_BlockDataSize];
- char m_BiomeData[cChunk::c_ChunkWidth * cChunk::c_ChunkWidth];
+ // NOTE that m_BlockData[] is inherited from the cChunkDataCollector
+ BLOCKTYPE m_BiomeData[cChunkDef::Width * cChunkDef::Width];
PacketList m_Packets; // Accumulator for the entity-packets to send
// cIsThread override:
virtual void Execute(void) override;
- // cChunkDataCallback overrides:
+ // cChunkDataCollector overrides:
// (Note that they are called while the ChunkMap's CS is locked - don't do heavy calculations here!)
- virtual void BlockData(const char * a_Data) override;
- virtual void Entity(cEntity * a_Entity) override;
- virtual void BlockEntity(cBlockEntity * a_Entity) override;
+ virtual void Entity (cEntity * a_Entity) override;
+ virtual void BlockEntity (cBlockEntity * a_Entity) override;
/// Sends the specified chunk to a_Client, or to all chunk clients if a_Client == NULL
void SendChunk(int a_ChunkX, int a_ChunkY, int a_ChunkZ, cClientHandle * a_Client);
|