Fix the health of animals
This commit is contained in:
parent
1f3f64fccd
commit
a75106aea7
@ -1274,6 +1274,7 @@ bool cFinishGenPassiveMobs::TrySpawnAnimals(cChunkDesc & a_ChunkDesc, int a_RelX
|
||||
double AnimalZ = static_cast<double>(a_ChunkDesc.GetChunkZ() * cChunkDef::Width + a_RelZ + 0.5);
|
||||
|
||||
cMonster * NewMob = cMonster::NewMonsterFromType(AnimalToSpawn);
|
||||
NewMob->SetHealth(NewMob->GetMaxHealth());
|
||||
NewMob->SetPosition(AnimalX, AnimalY, AnimalZ);
|
||||
a_ChunkDesc.GetEntities().push_back(NewMob);
|
||||
LOGD("Spawning %s #%i at {%.02f, %.02f, %.02f}", NewMob->GetClass(), NewMob->GetUniqueID(), AnimalX, AnimalY, AnimalZ);
|
||||
|
Loading…
Reference in New Issue
Block a user