1
0

Changed the old invulnerable methods from the wither to the new.

This commit is contained in:
Howaner
2014-04-26 17:47:25 +02:00
parent 619592b5a0
commit d50f8f6f11
5 changed files with 28 additions and 4 deletions

View File

@@ -2820,7 +2820,14 @@ void cProtocol172::cPacketizer::WriteMobMetadata(const cMonster & a_Mob)
case cMonster::mtWither:
{
WriteByte(0x54); // Int at index 20
WriteInt(((const cWither &)a_Mob).GetWitherInvulnerableTicks());
if (((const cWither &)a_Mob).IsSpawnInvulnerable())
{
WriteInt(((const cWither &)a_Mob).GetInvulnerableTicks());
}
else
{
WriteInt(0);
}
WriteByte(0x66); // Float at index 6
WriteFloat((float)(a_Mob.GetHealth()));
break;