Files
jak-project/goal_src/jak2/engine/process-drawable/process-focusable.gc
T
Tyler Wilding d264779173 d/jak2: finish glist | glist-h | camera | cam-interface | cam-states-dbg | cam-combiner | cam-debug | cam-start (#1829)
* d/jak2: finish `glist` and `glist-h` partially done `time-of-day`

* d/jak2: finish `camera` and `cam-interface`

* d/jak2: partially finish `cam-master` `cam-states`, and `cam-update` finish `cam-states-dbg` `cam-combiner` `cam-debug` and `cam-start`

* tests: update ref tests

* scripts: add scripts to automatically update gsrc files

* d/jak2: update gsrc
2022-08-31 19:22:47 -04:00

118 lines
2.4 KiB
Common Lisp

;;-*-Lisp-*-
(in-package goal)
;; name: process-focusable.gc
;; name in dgo: process-focusable
;; dgos: ENGINE, GAME
(defenum focus-status
:bitfield #t
:type uint32
(fs0 0) ;; if set, all collide checks fail
(fs1 1) ;; if set, all collide checks fail
(fs2 2)
(fs3 3)
(fs4 4)
(fs5 5)
(fs6 6)
(fs7 7)
(fs8 8)
(fs9 9)
(fs10 10)
(fs11 11)
(fs12 12)
(fs13 13)
(fs14 14)
(fs15 15)
(fs16 16)
(fs17 17)
(fs18 18)
(fs19 19)
(fs20 20)
(fs21 21)
(fs22 22)
(fs23 23)
(fs24 24)
(fs25 25)
(fs26 26)
(fs27 27)
(fs28 28)
(fs29 29)
(fs30 30)
(fs31 31)
)
;; DECOMP BEGINS
(deftype process-focusable (process-drawable)
((focus-status focus-status :offset-assert 200)
)
:heap-base #x50
:method-count-assert 27
:size-assert #xcc
:flag-assert #x1b005000cc
(:methods
(get-trans (_type_ int) vector 20)
(get-quat (_type_) quaternion 21)
(get-transv (_type_) vector 22)
(process-focusable-method-23 (_type_) none 23)
(process-focusable-method-24 (_type_) none 24)
(process-focusable-method-25 (_type_) int 25)
(process-focusable-method-26 (_type_) none 26)
)
)
(defmethod get-trans process-focusable ((obj process-focusable) (arg0 int))
(let ((gp-0 (-> obj root)))
(the-as vector (cond
((zero? arg0)
(-> gp-0 trans)
)
((and (= arg0 1) (type? gp-0 collide-shape-moving))
(-> (the-as collide-shape-moving gp-0) gspot-pos)
)
((and (or (= arg0 2) (= arg0 3)) (type? gp-0 collide-shape))
(-> (the-as collide-shape gp-0) root-prim prim-core)
)
(else
(-> gp-0 trans)
)
)
)
)
)
(defmethod get-transv process-focusable ((obj process-focusable))
(-> obj root transv)
)
(defmethod get-quat process-focusable ((obj process-focusable))
(-> obj root quat)
)
(defmethod process-focusable-method-23 process-focusable ((obj process-focusable))
0
(none)
)
(defmethod process-focusable-method-24 process-focusable ((obj process-focusable))
0
(none)
)
(defmethod process-focusable-method-26 process-focusable ((obj process-focusable))
0
(none)
)
(defmethod process-focusable-method-25 process-focusable ((obj process-focusable))
0
)
0