mirror of
https://github.com/zhenyan121/Cubed.git
synced 2026-08-08 17:57:02 +08:00
fix: correct velocity clamping and hitbox loading
Preserve sign when clamping velocity; negative velocities now clamp to zero instead of flipping direction. Support loading hitbox definitions from JSON arrays and objects. Tune pig entity movement, spawn height, and wander probabilities.
This commit is contained in:
@@ -179,7 +179,7 @@ void ServerWorld::send_chunk(int task_id, const std::string& uuid,
|
||||
void ServerWorld::init_world() {
|
||||
|
||||
m_entity_manager.init();
|
||||
m_entity_manager.add_entity("cubed:pig", {0, 90, 0});
|
||||
m_entity_manager.add_entity("cubed:pig", {0, 225, 0});
|
||||
register_timer("player disconnect", 5, [this]() {
|
||||
std::vector<std::string> disconnect;
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user