Skip to content

Commit f387c75

Browse files
committed
swars: Give negative buckets for being inside a building
This fixes thermal vision inside a building.
1 parent 6721402 commit f387c75

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/engindrwlstm.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -308,13 +308,13 @@ void draw_pers_e_graphic(struct Thing *p_thing, int x, int y, int z, int frame,
308308
if ((p_thing->Flag2 & TgF2_InsideBuilding) != 0) {
309309
if ((p_thing->Flag & TngF_Destroyed) != 0)
310310
return;
311-
scr_depth += BUCKETS_COUNT;
311+
scr_depth -= 10 * BUCKETS_COUNT;
312312
}
313313
}
314314
else
315315
{
316316
if ((p_thing->Flag2 & TgF2_InsideBuilding) != 0)
317-
scr_depth += BUCKETS_COUNT;
317+
scr_depth = -BUCKETS_COUNT;
318318
}
319319

320320
p_sspr = draw_item_add_sprite(DrIT_Unkn13, BUCKET_MID + scr_depth);

0 commit comments

Comments
 (0)