Merged from revision: 7270

- Fixed previous creature site habitat data not cleared resulting in incorrect creature spawning sectors (by Buggler)

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7271 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
Wanne
2014-06-10 19:41:04 +00:00
parent 9242b972c9
commit 17821ea3f8
+7
View File
@@ -427,6 +427,13 @@ creatureplacementEndElementHandle(void *userData, const XML_Char *name)
gCreaturePlacements[pData->curIndex].Habitat[y].ubZ = pData->curPlacementInfo.Habitat[y].ubZ;
gCreaturePlacements[pData->curIndex].Habitat[y].ubComposition = pData->curPlacementInfo.Habitat[y].ubComposition;
gCreaturePlacements[pData->curIndex].Habitat[y].fValid = pData->curPlacementInfo.Habitat[y].fValid;
// Clear pData Habitat Array as different creature site has different number of habitats
pData->curPlacementInfo.Habitat[y].sX = 0;
pData->curPlacementInfo.Habitat[y].sY = 0;
pData->curPlacementInfo.Habitat[y].ubZ = 0;
pData->curPlacementInfo.Habitat[y].ubComposition = 0;
pData->curPlacementInfo.Habitat[y].fValid = 0;
}
}
}