mirror of
https://github.com/alexbatalov/fallout2-ce.git
synced 2024-11-19 14:11:15 +00:00
Fix getting elevation of freed object
This commit is contained in:
parent
c0908cf14f
commit
737076a126
@ -1578,7 +1578,6 @@ static int _anim_set_end(int animationSequenceIndex)
|
||||
AnimationSequence* animationSequence;
|
||||
AnimationDescription* animationDescription;
|
||||
int i;
|
||||
Rect v27;
|
||||
|
||||
if (animationSequenceIndex == -1) {
|
||||
return -1;
|
||||
@ -1599,8 +1598,10 @@ static int _anim_set_end(int animationSequenceIndex)
|
||||
for (i = 0; i < animationSequence->length; i++) {
|
||||
animationDescription = &(animationSequence->animations[i]);
|
||||
if (animationDescription->kind == ANIM_KIND_HIDE && ((i < animationSequence->animationIndex) || (animationDescription->extendedFlags & ANIMATION_SEQUENCE_FORCED))) {
|
||||
objectDestroy(animationDescription->owner, &v27);
|
||||
tileWindowRefreshRect(&v27, animationDescription->owner->elevation);
|
||||
Rect rect;
|
||||
int elevation = animationDescription->owner->elevation;
|
||||
objectDestroy(animationDescription->owner, &rect);
|
||||
tileWindowRefreshRect(&rect, elevation);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user