- fixed bad sector use in handle_st18

This commit is contained in:
Christoph Oelckers 2021-11-19 11:21:10 +01:00
parent 5c9327a788
commit a0950081ad

View file

@ -653,7 +653,7 @@ static void handle_st18(int sn, DDukeActor* actor)
if (i == -1)
{
auto sectp = nextsectorneighborzptr(sptr, sptr->floorz, 1, -1);
if (sectp == nullptr) sectp = nextsectorneighborzptr(sectp, sptr->floorz, 1, 1);
if (sectp == nullptr) sectp = nextsectorneighborzptr(sptr, sptr->floorz, 1, 1);
if (sectp == nullptr) return;
int j = sectp->floorz;
int q = sptr->extra;