fix: remove byte type alias

This commit is contained in:
Tropical
2026-03-06 05:03:37 -06:00
parent 09eae49d21
commit 15af35eef2
208 changed files with 700 additions and 701 deletions

View File

@@ -340,7 +340,7 @@ Entity::Entity(Level *level, bool useSmallId) // 4J - added useSmallId parameter
// resetPos();
setPos(0, 0, 0);
entityData->define(DATA_SHARED_FLAGS_ID, (byte) 0);
entityData->define(DATA_SHARED_FLAGS_ID, (uint8_t) 0);
entityData->define(DATA_AIR_SUPPLY_ID, TOTAL_AIR_SUPPLY); // 4J Stu - Brought forward from 1.2.3 to fix 38654 - Gameplay: Player will take damage when air bubbles are present if resuming game from load/autosave underwater.
// 4J Stu - We cannot call virtual functions in ctors, as at this point the object
@@ -1677,7 +1677,7 @@ void Entity::lerpMotion(double xd, double yd, double zd)
this->zd = zd;
}
void Entity::handleEntityEvent(byte eventId)
void Entity::handleEntityEvent(uint8_t eventId)
{
}
@@ -1781,14 +1781,14 @@ bool Entity::getSharedFlag(int flag)
void Entity::setSharedFlag(int flag, bool value)
{
byte currentValue = entityData->getByte(DATA_SHARED_FLAGS_ID);
uint8_t currentValue = entityData->getByte(DATA_SHARED_FLAGS_ID);
if (value)
{
entityData->set(DATA_SHARED_FLAGS_ID, (byte) (currentValue | (1 << flag)));
entityData->set(DATA_SHARED_FLAGS_ID, (uint8_t) (currentValue | (1 << flag)));
}
else
{
entityData->set(DATA_SHARED_FLAGS_ID, (byte) (currentValue & ~(1 << flag)));
entityData->set(DATA_SHARED_FLAGS_ID, (uint8_t) (currentValue & ~(1 << flag)));
}
}