From 31abba9e0413f1ddb3aa15cdcf486e8ab2e8b7bc Mon Sep 17 00:00:00 2001 From: DrPerkyLegit Date: Sun, 31 May 2026 17:21:14 -0400 Subject: [PATCH] Revert "noPhysics field now works" This reverts commit e9b2f724c6fbf74cb97f44c44b7201256e83489e. --- Minecraft.World/ArmorStand.cpp | 20 ++++++++++---------- Minecraft.World/ArmorStand.h | 1 - 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/Minecraft.World/ArmorStand.cpp b/Minecraft.World/ArmorStand.cpp index 6056bc66..e83efe54 100644 --- a/Minecraft.World/ArmorStand.cpp +++ b/Minecraft.World/ArmorStand.cpp @@ -87,7 +87,7 @@ void ArmorStand::defineSynchedData() ArmorStand::~ArmorStand() {} -bool ArmorStand::hasPhysics() const { return (entityData->getByte(DATA_CLIENT_FLAGS) & FLAG_NO_GRAVITY) == 0; } + bool ArmorStand::isBaby() const { return (entityData->getByte(DATA_CLIENT_FLAGS) & FLAG_SMALL) != 0; } bool ArmorStand::isSmall() const { return isBaby(); } bool ArmorStand::isShowArms() const { return (entityData->getByte(DATA_CLIENT_FLAGS) & FLAG_SHOW_ARMS) != 0; } @@ -196,17 +196,17 @@ void ArmorStand::updateInvisibilityStatus() void ArmorStand::tick() { float lockedRot = this->yRot; - if (hasPhysics()) LivingEntity::tick(); + LivingEntity::tick(); if (onGround) { - BlockPos pos((int)floorf(x), (int)floorf(y) - 1, (int)floorf(z)); - int blockId = level->getTile(pos.getX(), pos.getY(), pos.getZ()); - if (blockId == Tile::topSnow->id) - { - int meta = level->getData(pos.getX(), pos.getY(), pos.getZ()); - float snowHeight = ((meta & 0x7) + 1) * 0.125f; - moveTo(x, floorf(y) + snowHeight, z, yRot, xRot); - } + BlockPos pos((int)floorf(x), (int)floorf(y) - 1, (int)floorf(z)); + int blockId = level->getTile(pos.getX(), pos.getY(), pos.getZ()); + if (blockId == Tile::topSnow->id) + { + int meta = level->getData(pos.getX(), pos.getY(), pos.getZ()); + float snowHeight = ((meta & 0x7) + 1) * 0.125f; + moveTo(x, floorf(y) + snowHeight, z, yRot, xRot); + } } this->yRot = lockedRot; this->yRotO = lockedRot; diff --git a/Minecraft.World/ArmorStand.h b/Minecraft.World/ArmorStand.h index 60c751fe..1e18cb47 100644 --- a/Minecraft.World/ArmorStand.h +++ b/Minecraft.World/ArmorStand.h @@ -68,7 +68,6 @@ public: explicit ArmorStand(Level* level); virtual ~ArmorStand(); - bool hasPhysics() const; bool isBaby() const; bool isSmall() const; bool isShowArms() const;