Files
jak-project/test/decompiler/reference/engine/collide/collide-target-h_REF.gc
T
Tyler Wilding dd959d0d0d decomp: Continuing full pass of gameplay code (#839)
* decomp: finish `babak` - :code is called in `(code nav-enemy-patrol babak)`

* decomp: almost finish `process-taskable`

* blocked: mistycannon / pelican

* decomp: finish `babak-with-cannon` write a script to fix gsrc

* decomp: finish `process-taskable`

* decomp: finish `flutflut` and `yakow`

* decomp: finish `fishermans-boat`

* blocked: state decomp `training-obs`

* decomp: finish `muse`

* decomp: finish `bonelurker`

* blocked: state decomp in `quicksandlurker`| `balloonlurker`

* decomp: finish `assistant-village2`

* scripts: script to help updating goal_src

* starting to update goal_src

* tests: update ref tests

* src: more src updating

* src: waiting on `process-taskable` and `muse`

* blocked: `citb-plat` state decomp

* decomp: finish `square-platform`

* blocked: `orbit-plat` due to overlays + static data

* decomp: finish `qbert-plat`

* blocked: almost finish `misty-conveyor`, sparticle-callback

* blocked: jungle-mirrors

* blocked: state decomp in `swamp-blimp`

* decomp: finish `swamp-bat`

* decomp: finish `swamp-rat`

* decomp: finish `swamp-rat-nest`

* blocked: state decomp `kermit`

* decomp: finish `cavecrystal-light`

* decomp: finish `spiderwebs`

* blocked: state decomp `dark-crystal`

* decomp: finish `baby-spider`

* decomp: finish `mother-spider-h`

* decomp: finish `mother-spider-proj`

* blocked: state decomp in `gnawer`

* blocked: state decomp in `driller-lurker`

* blocked: `sun-exit-chamber` breaks when adding handle cast

* decomp: finish `sunken-water`

* blocked: `target-tube` ShortCircuitElement::push_to_stack

* decomp: finish `sunken-fish`

* blocked: `minecart` decomp crash when adding stack cast

* decomp: finish `assistant-village3`

* decomp: finish `sage-village3`

* blocked: `cave-trap` done but ran into `go` issue

* blocked: `spider-egg` state decomp

* decomp: finish `target-snowball`

* blocked/stuck: `target-ice` decomp issue around cpad

* pausing: ice-cube has some weird collide-shape-prim handling

* blocked: `snow-ball` state decomp

* blocked: `snow-bumper` state decomp

* decomp: finish `snow-ram-h`

* decomp: finish `yeti`

* decomp: finish `assistant-lavatube`

* re-enable the float cast log

* decomp: updating to new sparticle definitions

* decomp: address feedback up to `swamp-rat-nest`

* address remaining feedback

* all-types: move the `pointer` def

* add back temporary `hud-hidden?`
2021-09-28 20:42:00 -04:00

179 lines
12 KiB
Common Lisp
Vendored

;;-*-Lisp-*-
(in-package goal)
;; definition of type collide-history
(deftype collide-history (structure)
((intersect vector :inline :offset-assert 0)
(trans vector :inline :offset-assert 16)
(transv vector :inline :offset-assert 32)
(transv-out vector :inline :offset-assert 48)
(local-normal vector :inline :offset-assert 64)
(surface-normal vector :inline :offset-assert 80)
(time int64 :offset-assert 96)
(status uint64 :offset-assert 104)
(pat pat-surface :offset-assert 112)
(reaction-flag uint32 :offset-assert 116)
)
:method-count-assert 10
:size-assert #x78
:flag-assert #xa00000078
(:methods
(update! (_type_ collide-shape-moving vector vector vector) _type_ 9)
)
)
;; definition for method 3 of type collide-history
(defmethod inspect collide-history ((obj collide-history))
(format #t "[~8x] ~A~%" obj 'collide-history)
(format #t "~Tintersect: ~`vector`P~%" (-> obj intersect))
(format #t "~Ttrans: ~`vector`P~%" (-> obj trans))
(format #t "~Ttransv: ~`vector`P~%" (-> obj transv))
(format #t "~Ttransv-out: ~`vector`P~%" (-> obj transv-out))
(format #t "~Tlocal-normal: ~`vector`P~%" (-> obj local-normal))
(format #t "~Tsurface-normal: ~`vector`P~%" (-> obj surface-normal))
(format #t "~Ttime: ~D~%" (-> obj time))
(format #t "~Tstatus: ~D~%" (-> obj status))
(format #t "~Tpat: ~D~%" (-> obj pat))
(format #t "~Treaction-flag: ~D~%" (-> obj reaction-flag))
obj
)
;; definition of type control-info
(deftype control-info (collide-shape-moving)
((unknown-vector00 vector :inline :offset 448)
(unknown-vector01 vector :inline :offset 464)
(unknown-vector02 vector :inline :offset 480)
(unknown-quaternion00 quaternion :inline :offset 496)
(unknown-quaternion01 quaternion :inline :offset 512)
(unknown-float00 float :offset 528)
(unknown-float01 float :offset 532)
(unknown-float02 float :offset 536)
(unknown-vector10 vector :inline :offset 544)
(unknown-vector11 vector :inline :offset 560)
(unknown-vector12 vector :inline :offset 576)
(unknown-vector13 vector :inline :offset 608)
(unknown-dynamics00 dynamics :offset 656)
(unknown-surface00 surface :offset 660)
(unknown-surface01 surface :offset 664)
(unknown-cpad-info00 cpad-info :offset 668)
(unknown-float10 float :offset 672)
(unknown-float11 float :offset 676)
(unknown-float12 float :offset 680)
(unknown-float13 float :offset 684)
(unknown-vector20 vector :inline :offset 688)
(unknown-vector21 vector :inline :offset 704)
(unknown-vector22 vector :inline :offset 720)
(unknown-vector23 vector :inline :offset 736)
(unknown-vector-array00 vector 7 :inline :offset 752)
(unknown-vector30 vector :inline :offset 880)
(unknown-vector31 vector :inline :offset 896)
(unknown-float20 float :offset 912)
(unknown-float21 float :offset 916)
(unknown-dword00 uint64 :offset 920)
(unknown-matrix00 matrix :inline :offset 928)
(unknown-matrix01 matrix :inline :offset 992)
(unknown-matrix02 matrix :inline :offset 1056)
(unknown-qword00 uint128 :offset 1136)
(unknown-float30 float :offset 1140)
(unknown-vector40 vector :inline :offset 1152)
(unknown-float40 float :offset 1176)
(unknown-int00 int32 :offset 1180)
(unknown-float50 float :offset 1168)
(unknown-vector50 vector :inline :offset 1184)
(unknown-vector51 vector :inline :offset 1200)
(unknown-vector52 vector :inline :offset 1216)
(unknown-vector53 vector :inline :offset 1232)
(unknown-vector54 vector :inline :offset 1248)
(unknown-vector55 vector :inline :offset 1264)
(unknown-dword10 int64 :offset 1288)
(unknown-float60 float :offset 1300)
(unknown-float61 float :offset 1304)
(unknown-float62 float :offset 1308)
(unknown-float63 float :offset 1312)
(unknown-float64 float :offset 1316)
(unknown-dword20 int64 :offset 1320)
(unknown-dword21 int64 :offset 1328)
(unknown-vector60 vector :inline :offset 1456)
(unknown-vector61 vector :inline :offset 1504)
(unknown-float70 float :offset 1520)
(unknown-vector70 vector :inline :offset 1536)
(unknown-vector71 vector :inline :offset 1552)
(unknown-handle00 handle :offset 1600)
(unknown-sphere-array00 collide-shape-prim-sphere 3 :offset 1608)
(unknown-sphere00 collide-shape-prim-sphere :offset 1632)
(unknown-sphere01 collide-shape-prim-sphere :offset 1636)
(unknown-sphere02 collide-shape-prim-sphere :offset 1640)
(unknown-dword30 int64 :offset 1672)
(unknown-dword31 int64 :offset 1680)
(unknown-dword32 int64 :offset 1688)
(unknown-dword33 int64 :offset 1696)
(unknown-float80 float :offset 1724)
(unknown-float81 float :offset 1728)
(unknown-float82 float :offset 1732)
(unknown-vector80 vector :inline :offset 1744)
(unknown-cspace00 cspace :inline :offset 1760)
(unknown-vector90 vector :inline :offset 1776)
(unknown-vector91 vector :inline :offset 1792)
(unknown-vector92 vector :inline :offset 1824)
(unknown-cspace10 cspace :inline :offset 1808)
(unknown-symbol00 symbol :offset 1840)
(unknown-float90 float :offset 1844)
(unknown-float91 float :offset 1848)
(unknown-vector-array10 vector 16 :inline :offset 1856)
(unknown-float100 float :offset 2112)
(unknown-int10 int32 :offset 2116)
(unknown-float110 float :offset 2120)
(unknown-vector100 vector :inline :offset 2128)
(unknown-vector101 vector :inline :offset 2144)
(unknown-dword40 int64 :offset 2160)
(unknown-dword41 int64 :offset 2168)
(unknown-handle10 handle :offset 2176)
(unknown-int11 int32 :offset 2184)
(unknown-int20 int32 :offset 2188)
(unknown-vector102 vector :inline :offset 2224)
(unknown-vector103 vector :inline :offset 2240)
(unknown-vector110 vector :inline :offset 2320)
(unknown-vector111 vector :inline :offset 2336)
(unknown-int30 int32 :offset 2384)
(unknown-dword50 int64 :offset 2392)
(unknown-dword51 int64 :offset 2400)
(unknown-symbol10 symbol :offset 2428)
(unknown-halfword00 int16 :offset 2488)
(history-length int16 :offset 2490)
(history-data collide-history 128 :inline :offset-assert 2496)
(unknown-dword60 int64 :offset 18952)
(unknown-int40 int32 :offset 18880)
(unknown-dword70 int64 :offset 18888)
(unknown-dword71 int64 :offset 18896)
(unknown-dword72 int64 :offset 18912)
(pad uint32 7 :offset-assert 18960)
)
:method-count-assert 65
:size-assert #x4a2c
:flag-assert #x4100004a2c
)
;; definition for method 9 of type collide-history
;; Used lq/sq
(defmethod
update!
collide-history
((obj collide-history)
(cshape collide-shape-moving)
(xs vector)
(transv vector)
(transv-out vector)
)
(set! (-> obj intersect quad) (-> xs quad))
(set! (-> obj transv quad) (-> transv quad))
(set! (-> obj transv-out quad) (-> transv-out quad))
(set! (-> obj trans quad) (-> cshape trans quad))
(set! (-> obj local-normal quad) (-> cshape local-normal quad))
(set! (-> obj surface-normal quad) (-> cshape surface-normal quad))
(set! (-> obj time) (-> *display* base-frame-counter))
(set! (-> obj status) (-> cshape status))
(set! (-> obj reaction-flag) (-> cshape reaction-flag))
(set! (-> obj pat) (-> cshape cur-pat))
obj
)