diff options
author | Mattes D <github@xoft.cz> | 2015-07-31 16:49:10 +0200 |
---|---|---|
committer | Mattes D <github@xoft.cz> | 2015-07-31 16:49:10 +0200 |
commit | 6e4122e551eeb41d3e950b363dd837d5586fe560 (patch) | |
tree | b5ee221d8a8e63c7d3b7868da1db19bf717a6ffd /src/Simulator/SandSimulator.h | |
parent | Merge pull request #2400 from cuberite/OffloadBadChunks (diff) | |
download | cuberite-6e4122e551eeb41d3e950b363dd837d5586fe560.tar cuberite-6e4122e551eeb41d3e950b363dd837d5586fe560.tar.gz cuberite-6e4122e551eeb41d3e950b363dd837d5586fe560.tar.bz2 cuberite-6e4122e551eeb41d3e950b363dd837d5586fe560.tar.lz cuberite-6e4122e551eeb41d3e950b363dd837d5586fe560.tar.xz cuberite-6e4122e551eeb41d3e950b363dd837d5586fe560.tar.zst cuberite-6e4122e551eeb41d3e950b363dd837d5586fe560.zip |
Diffstat (limited to '')
-rw-r--r-- | src/Simulator/SandSimulator.h | 31 |
1 files changed, 21 insertions, 10 deletions
diff --git a/src/Simulator/SandSimulator.h b/src/Simulator/SandSimulator.h index 8fff659ed..68ba718bd 100644 --- a/src/Simulator/SandSimulator.h +++ b/src/Simulator/SandSimulator.h @@ -3,13 +3,25 @@ #include "Simulator.h" -/// Per-chunk data for the simulator, specified individual chunks to simulate; Data is not used + + + + +// fwd: +class cChunk; + + + + + +/** Per-chunk data for the simulator, specified individual chunks to simulate; Data is not used */ typedef cCoordWithIntList cSandSimulatorChunkData; -#include "Chunk.h" -/// Despite the class name, this simulator takes care of all blocks that fall when suspended in the air. + + +/** Despite the class name, this simulator takes care of all blocks that fall when suspended in the air. */ class cSandSimulator : public cSimulator { @@ -21,23 +33,22 @@ public: virtual void SimulateChunk(std::chrono::milliseconds a_Dt, int a_ChunkX, int a_ChunkZ, cChunk * a_Chunk) override; virtual bool IsAllowedBlock(BLOCKTYPE a_BlockType) override; - /// Returns true if a falling-able block can start falling through the specified block type + /** Returns true if a falling-able block can start falling through the specified block type */ static bool CanStartFallingThrough(BLOCKTYPE a_BlockType); - /// Returns true if an already-falling block can pass through the specified block type (e. g. torch) + /** Returns true if an already-falling block can pass through the specified block type (e. g. torch) */ static bool CanContinueFallThrough(BLOCKTYPE a_BlockType); - /// Returns true if the falling block rematerializing will replace the specified block type (e. g. tall grass) + /** Returns true if the falling block rematerializing will replace the specified block type (e. g. tall grass) */ static bool IsReplacedOnRematerialization(BLOCKTYPE a_BlockType); - /// Returns true if the specified block breaks falling blocks while they fall through it (e. g. halfslabs) + /** Returns true if the specified block breaks falling blocks while they fall through it (e. g. halfslabs) */ static bool DoesBreakFallingThrough(BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta); /** Called when a block finishes falling at the specified coords, either by insta-fall, or through cFallingBlock entity. It either rematerializes the block (a_FallingBlockType) at the specified coords, or creates a pickup, - based on the block currently present in the world at the dest specified coords - */ + based on the block currently present in the world at the dest specified coords. */ static void FinishFalling( cWorld * a_World, int a_BlockX, int a_BlockY, int a_BlockZ, BLOCKTYPE a_FallingBlockType, NIBBLETYPE a_FallingBlockMeta @@ -50,7 +61,7 @@ protected: virtual void AddBlock(int a_BlockX, int a_BlockY, int a_BlockZ, cChunk * a_Chunk) override; - /// Performs the instant fall of the block - removes it from top, Finishes it at the bottom + /** Performs the instant fall of the block - removes it from top, Finishes it at the bottom */ void DoInstantFall(cChunk * a_Chunk, int a_RelX, int a_RelY, int a_RelZ); }; |