Reorganised the redstone simulator
-> Many thanks to @worktycho for the idea, and @Haxi52 for the implementation plan! * Uses classes and inheritance now * Speed should be improved
This commit is contained in:
@@ -17,8 +17,7 @@
|
||||
|
||||
cDropSpenserEntity::cDropSpenserEntity(BLOCKTYPE a_BlockType, int a_BlockX, int a_BlockY, int a_BlockZ, cWorld * a_World) :
|
||||
super(a_BlockType, a_BlockX, a_BlockY, a_BlockZ, ContentsWidth, ContentsHeight, a_World),
|
||||
m_ShouldDropSpense(false),
|
||||
m_IsPowered(false)
|
||||
m_ShouldDropSpense(false)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -114,19 +113,6 @@ void cDropSpenserEntity::Activate(void)
|
||||
|
||||
|
||||
|
||||
void cDropSpenserEntity::SetRedstonePower(bool a_IsPowered)
|
||||
{
|
||||
if (a_IsPowered && !m_IsPowered)
|
||||
{
|
||||
Activate();
|
||||
}
|
||||
m_IsPowered = a_IsPowered;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
bool cDropSpenserEntity::Tick(std::chrono::milliseconds a_Dt, cChunk & a_Chunk)
|
||||
{
|
||||
UNUSED(a_Dt);
|
||||
|
||||
Reference in New Issue
Block a user