Skip to content

Commit

Permalink
APC is no longer a valid target while it has allies in it
Browse files Browse the repository at this point in the history
  • Loading branch information
xDanilcusx committed Jan 28, 2024
1 parent 4bb7eb2 commit 1a3acec
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions code/modules/mob/living/carbon/xenomorph/ai/xeno_ai.dm
Original file line number Diff line number Diff line change
Expand Up @@ -282,18 +282,21 @@
if(distance > ai_range)
continue

if(potential_vehicle_target.health <= 0)
var/skip_vehicle = TRUE
var/skip_vehicle

var/list/interior_living_mobs = potential_vehicle_target.interior.get_passengers()
for(var/mob/living/carbon/carbon_mob in interior_living_mobs)
if(!carbon_mob.check_mob_target(src))
continue
var/list/interior_living_mobs = potential_vehicle_target.interior.get_passengers()
for(var/mob/living/carbon/human/human_mob in interior_living_mobs)
if(human_mob.stat == DEAD || human_mob.check_mob_target(src))
continue

skip_vehicle = FALSE
skip_vehicle = TRUE
break

if(skip_vehicle)
continue
if(potential_vehicle_target.health <= 0)
skip_vehicle = TRUE

if(skip_vehicle)
continue

viable_targets += potential_vehicle_target

Expand Down

0 comments on commit 1a3acec

Please sign in to comment.