From 81c73341b24688b290c91bddcf83c3f6d3621f1b Mon Sep 17 00:00:00 2001 From: faketruth Date: Sun, 25 Dec 2011 12:55:20 +0000 Subject: The missing file! cChunkGenerator.h/cpp git-svn-id: http://mc-server.googlecode.com/svn/trunk@105 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/cChunkGenerator.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 source/cChunkGenerator.h (limited to 'source/cChunkGenerator.h') diff --git a/source/cChunkGenerator.h b/source/cChunkGenerator.h new file mode 100644 index 000000000..df29a3e60 --- /dev/null +++ b/source/cChunkGenerator.h @@ -0,0 +1,23 @@ +#pragma once + +class cChunk; +class cChunkMap; +class cChunkGenerator +{ +public: + cChunkGenerator( cChunkMap* a_pChunkMap ); + ~cChunkGenerator(); + + void GenerateChunk( int a_X, int a_Z ); + + cChunk* GetCurrentlyGenerating(); // WARNING - Be sure to Lock() before calling, and Unlock() after done with the chunk! + void Lock(); + void Unlock(); +private: + static void GenerateThread( void* a_Params ); + + cChunkMap* m_pChunkMap; + + struct sChunkGeneratorState; + sChunkGeneratorState* m_pState; +}; \ No newline at end of file -- cgit v1.2.3