2012-10-06 20:04:58 +00:00
|
|
|
|
2012-06-14 13:06:06 +00:00
|
|
|
#pragma once
|
|
|
|
|
2015-06-26 22:24:51 +00:00
|
|
|
#include "Simulator/Simulator.h"
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-10-06 20:04:58 +00:00
|
|
|
|
|
|
|
|
2014-09-16 19:29:31 +00:00
|
|
|
class cRedstoneSimulatorChunkData
|
|
|
|
{
|
|
|
|
public:
|
2014-09-26 16:00:34 +00:00
|
|
|
virtual ~cRedstoneSimulatorChunkData() = 0;
|
2015-06-26 22:24:51 +00:00
|
|
|
};
|
2012-10-06 20:04:58 +00:00
|
|
|
|
2014-09-26 16:00:34 +00:00
|
|
|
inline cRedstoneSimulatorChunkData::~cRedstoneSimulatorChunkData() {}
|
|
|
|
|
2014-10-25 20:54:00 +00:00
|
|
|
|
2015-06-26 22:24:51 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
2012-10-06 20:04:58 +00:00
|
|
|
class cRedstoneSimulator :
|
2014-10-25 20:54:00 +00:00
|
|
|
public cSimulator
|
2012-06-14 13:06:06 +00:00
|
|
|
{
|
2014-10-25 20:54:00 +00:00
|
|
|
typedef cSimulator super;
|
2012-06-14 13:06:06 +00:00
|
|
|
public:
|
2015-06-26 22:24:51 +00:00
|
|
|
|
2014-10-25 20:54:00 +00:00
|
|
|
cRedstoneSimulator(cWorld & a_World) :
|
2015-06-26 22:24:51 +00:00
|
|
|
super(a_World)
|
2014-09-11 16:48:21 +00:00
|
|
|
{
|
|
|
|
}
|
2015-06-26 22:24:51 +00:00
|
|
|
|
|
|
|
virtual void Simulate(float a_Dt) = 0;
|
|
|
|
virtual void SimulateChunk(std::chrono::milliseconds a_Dt, int a_ChunkX, int a_ChunkZ, cChunk * a_Chunk) = 0;
|
|
|
|
virtual bool IsAllowedBlock(BLOCKTYPE a_BlockType) = 0;
|
2017-08-17 13:48:38 +00:00
|
|
|
virtual void AddBlock(Vector3i a_Block, cChunk * a_Chunk) = 0;
|
2015-06-26 22:24:51 +00:00
|
|
|
|
2014-09-28 14:36:00 +00:00
|
|
|
virtual cRedstoneSimulatorChunkData * CreateChunkData() = 0;
|
2013-11-18 22:30:34 +00:00
|
|
|
|
2015-06-26 22:24:51 +00:00
|
|
|
};
|