From b82fc394dd2a40e12e3c13709fea26c2435792c9 Mon Sep 17 00:00:00 2001 From: Tycho Date: Sun, 2 Feb 2014 06:49:37 -0800 Subject: Changed Signiture of OnUpdate --- src/Blocks/BlockHandler.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/Blocks/BlockHandler.h') diff --git a/src/Blocks/BlockHandler.h b/src/Blocks/BlockHandler.h index 867c4c2c5..44b15bce1 100644 --- a/src/Blocks/BlockHandler.h +++ b/src/Blocks/BlockHandler.h @@ -5,6 +5,7 @@ #include "../Item.h" #include "WorldInterface.h" #include "ChunkInterface.h" +#include "BlockPluginInterface.h" @@ -25,7 +26,7 @@ public: /// Called when the block gets ticked either by a random tick or by a queued tick. /// Note that the coords are chunk-relative! - virtual void OnUpdate(cChunk & a_Chunk, int a_RelX, int a_RelY, int a_RelZ); + virtual void OnUpdate(cChunkInterface & cChunkInterface, cWorldInterface & a_WorldInterface, cBlockPluginInterface & a_BlockPluginInterface, cChunk & a_Chunk, int a_RelX, int a_RelY, int a_RelZ); /** Called before a block is placed into a world. The handler should return true to allow placement, false to refuse. @@ -72,7 +73,7 @@ public: virtual void ConvertToPickups(cItems & a_Pickups, NIBBLETYPE a_BlockMeta); /// Handles the dropping of a block based on what ConvertToDrops() returns. This will not destroy the block. a_Digger is the entity causing the drop; it may be NULL - virtual void DropBlock(cWorld * a_World, cEntity * a_Digger, int a_BlockX, int a_BlockY, int a_BlockZ); + virtual void DropBlock(cChunkInterface & a_ChunkInterface, cWorldInterface & a_WorldInterface, cBlockPluginInterface & a_BlockPluginInterface, cEntity * a_Digger, int a_BlockX, int a_BlockY, int a_BlockZ); /// Returns step sound name of block virtual const char * GetStepSound(void); @@ -113,7 +114,7 @@ public: By default drops if position no more suitable (CanBeAt(), DoesDropOnUnsuitable(), Drop()), and wakes up all simulators on the block. */ - virtual void Check(cChunkInterface & ChunkInterface, int a_RelX, int a_RelY, int a_RelZ, cChunk & a_Chunk); + virtual void Check(cChunkInterface & ChunkInterface, cBlockPluginInterface & a_PluginInterface, int a_RelX, int a_RelY, int a_RelZ, cChunk & a_Chunk); /// Rotates a given block meta counter-clockwise. Default: no change /// Block meta following rotation -- cgit v1.2.3