mirror of
https://github.com/DrBeef/Raze.git
synced 2024-11-15 17:01:51 +00:00
- Add nullptr check to Interp_Sprite_Z
reversion so I can load older saves before this was reverted.
This commit is contained in:
parent
00ffc8b6a2
commit
bc6dd4ae3e
1 changed files with 2 additions and 2 deletions
|
@ -55,7 +55,7 @@ double Get(int index, DCoreActor* actor, int type)
|
|||
case Interp_Wall_PanX: return wall[index].xpan_;
|
||||
case Interp_Wall_PanY: return wall[index].ypan_;
|
||||
|
||||
case Interp_Sprite_Z: return actor->spr.pos.Z;
|
||||
case Interp_Sprite_Z: return actor ? actor->spr.pos.Z : 0;
|
||||
default: return 0;
|
||||
}
|
||||
}
|
||||
|
@ -79,7 +79,7 @@ void Set(int index, DCoreActor* actor, int type, double val)
|
|||
case Interp_Wall_PanX: wall[index].xpan_ = float(val); break;
|
||||
case Interp_Wall_PanY: wall[index].ypan_ = float(val); break;
|
||||
|
||||
case Interp_Sprite_Z: actor->spr.pos.Z = xs_CRoundToInt(val); break;
|
||||
case Interp_Sprite_Z: if (actor) actor->spr.pos.Z = xs_CRoundToInt(val); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue