From 36f7084e3fb4193676b14f302d0f961f2102e4ba Mon Sep 17 00:00:00 2001 From: "admin@omencraft.com" Date: Sun, 6 Nov 2011 09:23:20 +0000 Subject: Patch with diff file created by Sebi (implemented some stuff like lava physics, drops are deleted when in lava, water is now slower, lava gives actual damage etc.). Pistons now work mostly as they should. They do not yet show the motion animation and do not emit sound. They do extend, push, and retract as they should though. Right now the only way to activate a piston is to light redstone wire adjacent to it with a redstone torch. git-svn-id: http://mc-server.googlecode.com/svn/trunk@67 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/cLavaSimulator.h | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 source/cLavaSimulator.h (limited to 'source/cLavaSimulator.h') diff --git a/source/cLavaSimulator.h b/source/cLavaSimulator.h new file mode 100644 index 000000000..f1c59b939 --- /dev/null +++ b/source/cLavaSimulator.h @@ -0,0 +1,25 @@ +#pragma once + +class Vector3i; +class cWorld; +class cLavaSimulator +{ +public: + cLavaSimulator( cWorld* a_World ); + ~cLavaSimulator(); + + void Simulate( float a_Dt ); + void WakeUp( int a_X, int a_Y, int a_Z ); + +private: + void AddBlock( int a_X, int a_Y, int a_Z); + char GetHighestLevelAround( int a_X, int a_Y, int a_Z ); + + bool IsLavaBlock( char a_BlockID ); + + float m_Timer; + cWorld* m_World; + + class LavaData; + LavaData* m_Data; +}; -- cgit v1.2.3