1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

ABMs: Make catch-up behaviour optional

Default is true for backwards compatibility
Update lua_api.txt
This commit is contained in:
paramat 2015-10-13 05:17:33 +01:00
parent 2364449d7a
commit 3b9f99e0d6
5 changed files with 33 additions and 14 deletions

View file

@ -155,6 +155,8 @@ public:
virtual float getTriggerInterval() = 0;
// Random chance of (1 / return value), 0 is disallowed
virtual u32 getTriggerChance() = 0;
// Whether to modify chance to simulate time lost by an unnattended block
virtual bool getSimpleCatchUp() = 0;
// This is called usually at interval for 1/chance of the nodes
virtual void trigger(ServerEnvironment *env, v3s16 p, MapNode n){};
virtual void trigger(ServerEnvironment *env, v3s16 p, MapNode n,