mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-24 13:21:20 +00:00
[quake fixes] Use P_MobjWasRemoved instead of checking against NULL per Zapony's suggestion
This commit is contained in:
parent
209c545743
commit
491c77bd76
1 changed files with 1 additions and 1 deletions
|
@ -1153,7 +1153,7 @@ void R_SetupFrame(player_t *player)
|
||||||
if (quake.epicenter) {
|
if (quake.epicenter) {
|
||||||
// Calculate 3D distance from epicenter, using the camera.
|
// Calculate 3D distance from epicenter, using the camera.
|
||||||
fixed_t xydist, dist;
|
fixed_t xydist, dist;
|
||||||
if (r_viewmobj == NULL) {
|
if (P_MobjWasRemoved(r_viewmobj)) {
|
||||||
xydist = R_PointToDist2(thiscam->x, thiscam->y, quake.epicenter->x, quake.epicenter->y);
|
xydist = R_PointToDist2(thiscam->x, thiscam->y, quake.epicenter->x, quake.epicenter->y);
|
||||||
dist = R_PointToDist2(0, thiscam->z, xydist, quake.epicenter->z);
|
dist = R_PointToDist2(0, thiscam->z, xydist, quake.epicenter->z);
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue