Fix obj_can_see_obj not working in release build (#350)
This commit is contained in:
parent
caea9cb4fb
commit
16b044ae31
|
@ -1799,7 +1799,7 @@ static void opObjectCanSeeObject(Program* program)
|
||||||
if (object2->elevation == object1->elevation) {
|
if (object2->elevation == object1->elevation) {
|
||||||
if (object2->tile != -1 && object1->tile != -1) {
|
if (object2->tile != -1 && object1->tile != -1) {
|
||||||
if (isWithinPerception(object1, object2)) {
|
if (isWithinPerception(object1, object2)) {
|
||||||
Object* obstacle;
|
Object* obstacle = nullptr;
|
||||||
_make_straight_path(object1, object1->tile, object2->tile, nullptr, &obstacle, 16);
|
_make_straight_path(object1, object1->tile, object2->tile, nullptr, &obstacle, 16);
|
||||||
if (obstacle == object2) {
|
if (obstacle == object2) {
|
||||||
canSee = true;
|
canSee = true;
|
||||||
|
|
Loading…
Reference in New Issue