diff --git a/goal_src/jak2/engine/target/target-gun.gc b/goal_src/jak2/engine/target/target-gun.gc index da96477782..1ad6787357 100644 --- a/goal_src/jak2/engine/target/target-gun.gc +++ b/goal_src/jak2/engine/target/target-gun.gc @@ -1176,20 +1176,14 @@ ) ) +(declare-type enemy basic) + +(deftype enemy-hack (basic) + ((hit-points int32 :offset 220)) + ) + (defun is-dead-enemy? ((proc process)) - (and (type-type? (-> proc type) enemy) (<= (-> (the enemy proc) hit-points) 0)) - ) - -(defun is-dead-dummy? ((proc process)) - (and (type-type? (-> proc type) gun-dummy) (<= (-> (the gun-dummy proc) hit-points) 0)) - ) - -(defun is-good-guy? ((proc process)) - (or (type-type? (-> proc type) gun-cit-a) - (type-type? (-> proc type) gun-cit-b) - (type-type? (-> proc type) gun-cit-c) - (type-type? (-> proc type) gun-cit-d) - ) + (and (type-type? (-> proc type) enemy) (<= (-> (the enemy-hack proc) hit-points) 0)) ) (defun get-trans-for-aim ((vec vector) (proc process-drawable)) @@ -1213,8 +1207,8 @@ (when (and (type-type? (-> proc type) process-focusable) ;(not (= (-> proc state name) 'knocked)) (not (is-dead-enemy? proc)) - (not (is-dead-dummy? proc)) - (not (is-good-guy? proc)) + ;(not (is-dead-dummy? proc)) + ;(not (is-good-guy? proc)) ) (let* ((pos ;(get-trans (the process-focusable proc) 2) (get-trans-for-aim (new-stack-vector0) (the process-drawable proc))