#pragma once #include #include #include "World.h" #include "Block.h" #include "Math.h" #include "BlockTick.h" namespace vf { struct ExplosionConfig { float power = 4.0f; int rayGridSize = 6; }; struct BlockDrop { Vec3i pos; Block block; }; struct ExplosionResult { std::vector destroyedBlocks; std::vector drops; std::vector ignitedTnt; }; float blastResistance(Block b); Block dropForBlock(Block b); ExplosionResult explode(World& world, const Vec3i& center, const ExplosionConfig& config = {}); Vec3 explosionKnockback(const Vec3i& center, const Vec3& entityPos, float power); void igniteTnt(BlockTickScheduler& scheduler, const Vec3i& pos, int fuseTicks = 4); } // namespace vf