1
0
mirror of https://github.com/p2r3/bareiron.git synced 2025-10-02 07:35:08 +02:00

rewrite sand ticking

This commit is contained in:
2025-09-27 20:29:10 +02:00
parent ae6aaf3925
commit ede77674d3
3 changed files with 109 additions and 46 deletions

View File

@@ -199,11 +199,20 @@ typedef struct {
uint8_t block;
} BlockChange;
#define UPDATE_BASIC (1 << 0)
// the sand at this position will be moved down immediately when this is processed
#define UPDATE_FALL_SAND (1 << 1)
// the sand below this block will fall soon
#define UPDATE_CHECK_SAND_FALL (1 << 2)
#define UPDATE_NOW (UPDATE_BASIC | UPDATE_CHECK_SAND_FALL)
typedef struct {
short update_kind;
short x;
short z;
uint8_t y;
uint8_t awaitTicks;
uint8_t await_ticks;
} DeferredBlockUpdate;
#pragma pack(push, 1)