diff options
author | andrew <xdotftw@gmail.com> | 2014-03-24 11:29:19 +0100 |
---|---|---|
committer | andrew <xdotftw@gmail.com> | 2014-03-24 11:29:19 +0100 |
commit | 6b77dc74ade3d8088da09d26c1b701d92ef28e9e (patch) | |
tree | 78e16164d1668d628ef0f545a5e62f5cbc1025fc /src/WorldStorage/WSSAnvil.cpp | |
parent | Plugins can set flying speed. (diff) | |
download | cuberite-6b77dc74ade3d8088da09d26c1b701d92ef28e9e.tar cuberite-6b77dc74ade3d8088da09d26c1b701d92ef28e9e.tar.gz cuberite-6b77dc74ade3d8088da09d26c1b701d92ef28e9e.tar.bz2 cuberite-6b77dc74ade3d8088da09d26c1b701d92ef28e9e.tar.lz cuberite-6b77dc74ade3d8088da09d26c1b701d92ef28e9e.tar.xz cuberite-6b77dc74ade3d8088da09d26c1b701d92ef28e9e.tar.zst cuberite-6b77dc74ade3d8088da09d26c1b701d92ef28e9e.zip |
Diffstat (limited to 'src/WorldStorage/WSSAnvil.cpp')
-rw-r--r-- | src/WorldStorage/WSSAnvil.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/WorldStorage/WSSAnvil.cpp b/src/WorldStorage/WSSAnvil.cpp index 7a2366755..2516ac07a 100644 --- a/src/WorldStorage/WSSAnvil.cpp +++ b/src/WorldStorage/WSSAnvil.cpp @@ -1238,7 +1238,7 @@ void cWSSAnvil::LoadEntityFromNBT(cEntityList & a_Entities, const cParsedNBT & a { LoadWitchFromNBT(a_Entities, a_NBT, a_EntityTagIdx); } - else if (strncmp(a_IDTag, "Wither", a_IDTagLength) == 0) + else if (strncmp(a_IDTag, "WitherBoss", a_IDTagLength) == 0) { LoadWitherFromNBT(a_Entities, a_NBT, a_EntityTagIdx); } @@ -2250,6 +2250,12 @@ void cWSSAnvil::LoadWitherFromNBT(cEntityList & a_Entities, const cParsedNBT & a return; } + int CurrLine = a_NBT.FindChildByName(a_TagIdx, "Invul"); + if (CurrLine > 0) + { + Monster->SetNumInvulnerableTicks(a_NBT.GetInt(CurrLine)); + } + a_Entities.push_back(Monster.release()); } |