mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/GabsPuNs-MinecraftConsoles.git
synced 2026-07-12 16:28:43 +00:00
Use BYTE Win Typedef instead of byte typedef from Minecraft.World
This commit is contained in:
@@ -19,7 +19,7 @@ TamableAnimal::~TamableAnimal()
|
||||
void TamableAnimal::defineSynchedData()
|
||||
{
|
||||
Animal::defineSynchedData();
|
||||
entityData->define(DATA_FLAGS_ID, static_cast<byte>(0));
|
||||
entityData->define(DATA_FLAGS_ID, static_cast<BYTE>(0));
|
||||
entityData->define(DATA_OWNERUUID_ID, L"");
|
||||
}
|
||||
|
||||
@@ -87,7 +87,7 @@ void TamableAnimal::spawnTamingParticles(bool success)
|
||||
}
|
||||
}
|
||||
|
||||
void TamableAnimal::handleEntityEvent(byte id)
|
||||
void TamableAnimal::handleEntityEvent(BYTE id)
|
||||
{
|
||||
if (id == EntityEvent::TAMING_SUCCEEDED)
|
||||
{
|
||||
@@ -110,14 +110,14 @@ bool TamableAnimal::isTame()
|
||||
|
||||
void TamableAnimal::setTame(bool value)
|
||||
{
|
||||
byte current = entityData->getByte(DATA_FLAGS_ID);
|
||||
BYTE current = entityData->getByte(DATA_FLAGS_ID);
|
||||
if (value)
|
||||
{
|
||||
entityData->set(DATA_FLAGS_ID, static_cast<byte>(current | 0x04));
|
||||
entityData->set(DATA_FLAGS_ID, static_cast<BYTE>(current | 0x04));
|
||||
}
|
||||
else
|
||||
{
|
||||
entityData->set(DATA_FLAGS_ID, static_cast<byte>(current & ~0x04));
|
||||
entityData->set(DATA_FLAGS_ID, static_cast<BYTE>(current & ~0x04));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -128,14 +128,14 @@ bool TamableAnimal::isSitting()
|
||||
|
||||
void TamableAnimal::setSitting(bool value)
|
||||
{
|
||||
byte current = entityData->getByte(DATA_FLAGS_ID);
|
||||
BYTE current = entityData->getByte(DATA_FLAGS_ID);
|
||||
if (value)
|
||||
{
|
||||
entityData->set(DATA_FLAGS_ID, static_cast<byte>(current | 0x01));
|
||||
entityData->set(DATA_FLAGS_ID, static_cast<BYTE>(current | 0x01));
|
||||
}
|
||||
else
|
||||
{
|
||||
entityData->set(DATA_FLAGS_ID, static_cast<byte>(current & ~0x01));
|
||||
entityData->set(DATA_FLAGS_ID, static_cast<BYTE>(current & ~0x01));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user