Files
jak-project/test/decompiler/reference/engine/game/task/task-control-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

199 lines
7.9 KiB
Common Lisp
Vendored

;;-*-Lisp-*-
(in-package goal)
;; definition of type task-cstage
(deftype task-cstage (structure)
((game-task game-task :offset-assert 0)
(status task-status :offset-assert 8)
(flags task-flags :offset-assert 16)
(condition (function task-control symbol) :offset-assert 20)
)
:method-count-assert 16
:size-assert #x18
:flag-assert #x1000000018
(:methods
(get-task (_type_) game-task 9)
(get-status (_type_) task-status 10)
(task-available? (_type_ task-control) symbol 11)
(closed? (_type_) symbol 12)
(closed-by-default? (_type_) symbol 13)
(close-task! (_type_) int 14)
(open-task! (_type_) int 15)
)
)
;; definition for method 3 of type task-cstage
(defmethod inspect task-cstage ((obj task-cstage))
(format #t "[~8x] ~A~%" obj 'task-cstage)
(format #t "~Tgame-task: ~D~%" (-> obj game-task))
(format #t "~Tstatus: ~D~%" (-> obj status))
(format #t "~Tflags: ~D~%" (-> obj flags))
(format #t "~Tcondition: ~A~%" (-> obj condition))
obj
)
;; definition of type task-control
(deftype task-control (basic)
((current-stage int16 :offset-assert 4)
(stage (array task-cstage) :offset-assert 8)
)
:method-count-assert 19
:size-assert #xc
:flag-assert #x130000000c
(:methods
(current-task (_type_) int 9)
(current-status (_type_) int 10)
(close-current! (_type_) none 11)
(close-status! (_type_ task-status) int 12)
(first-any (_type_ symbol) int 13)
(reset! (_type_ symbol symbol) int 14)
(closed? (_type_ game-task task-status) symbol 15)
(get-reminder (_type_ int) int 16)
(save-reminder (_type_ int int) int 17)
(exists? (_type_ game-task task-status) symbol 18)
)
)
;; definition for method 3 of type task-control
(defmethod inspect task-control ((obj task-control))
(format #t "[~8x] ~A~%" obj (-> obj type))
(format #t "~Tcurrent-stage: ~D~%" (-> obj current-stage))
(format #t "~Tstage: ~A~%" (-> obj stage))
obj
)
;; definition of type ambient-control
(deftype ambient-control (structure)
((last-ambient-time uint64 :offset-assert 0)
(last-ambient basic :offset-assert 8)
(last-ambient-id uint32 :offset-assert 12)
)
:method-count-assert 12
:size-assert #x10
:flag-assert #xc00000010
(:methods
(dummy-9 (_type_ vector int float process-drawable) none 9)
(TODO-RENAME-10 (_type_ vector int float process-drawable) vector 10)
(dummy-11 (_type_ string symbol vector) symbol 11)
)
)
;; definition for method 3 of type ambient-control
(defmethod inspect ambient-control ((obj ambient-control))
(format #t "[~8x] ~A~%" obj 'ambient-control)
(format #t "~Tlast-ambient-time: ~D~%" (-> obj last-ambient-time))
(format #t "~Tlast-ambient: ~A~%" (-> obj last-ambient))
(format #t "~Tlast-ambient-id: ~D~%" (-> obj last-ambient-id))
obj
)
;; definition of type process-taskable
(deftype process-taskable (process-drawable)
((root-override collide-shape :offset 112)
(tasks task-control :offset-assert 176)
(query gui-query :inline :offset-assert 180)
(old-target-pos transformq :inline :offset-assert 208)
(cell-for-task game-task :offset-assert 256)
(cell-x handle :offset-assert 264)
(cam-joint-index int32 :offset-assert 272)
(skippable basic :offset-assert 276)
(blend-on-exit basic :offset-assert 280)
(camera handle :offset-assert 288)
(will-talk symbol :offset-assert 296)
(talk-message uint32 :offset-assert 300)
(last-talk uint64 :offset-assert 304)
(bounce-away symbol :offset-assert 312)
(ambient ambient-control :inline :offset-assert 320)
(center-joint-index int32 :offset-assert 336)
(draw-bounds-y-offset float :offset-assert 340)
(neck-joint-index int32 :offset-assert 344)
(fuel-cell-anim spool-anim :offset-assert 348)
(sound-flava uint8 :offset-assert 352)
(have-flava symbol :offset-assert 356)
(music basic :offset-assert 360)
(have-music symbol :offset-assert 364)
(been-kicked symbol :offset-assert 368)
(cur-trans-hook (function none) :offset-assert 372)
(shadow-backup shadow-geo :offset-assert 376)
)
:heap-base #x110
:method-count-assert 53
:size-assert #x17c
:flag-assert #x350110017c
(:methods
(release () _type_ :state 20)
(give-cell () _type_ :state 21)
(lose () _type_ :state 22)
(enter-playing () _type_ :state 23)
(play-accept () _type_ :state 24)
(play-reject () _type_ :state 25)
(query () _type_ :state 26)
(play-anim () _type_ :state 27)
(hidden () _type_ :state 28)
(be-clone (handle) _type_ :state 29)
(idle () _type_ :state 30)
(get-art-elem (_type_) art-element 31)
(play-anim! (_type_ symbol) basic 32)
(dummy-33 (_type_) none 33)
(TODO-RENAME-34 (_type_ symbol) symbol 34)
(dummy-35 (_type_) none 35)
(get-spool-anim-or-?? (_type_ symbol) basic 36)
(spool-push-anim (_type_) none 37)
(dummy-38 (_type_) none 38)
(should-display? (_type_) symbol 39)
(dummy-40 (_type_ object skeleton-group int int vector int) none 40)
(initialize-collision (_type_ int vector) none 41)
(dummy-42 (_type_) none 42)
(TODO-RENAME-43 (_type_) symbol 43)
(play-reminder (_type_) symbol 44)
(dummy-45 (_type_) none 45)
(dummy-46 (_type_) none 46)
(target-above-threshold? (_type_) symbol 47)
(draw-npc-shadow (_type_) none 48)
(hidden-other () _type_ :state 49)
(TODO-RENAME-50 (_type_) symbol 50)
(close-anim-file! (_type_) symbol 51)
(dummy-52 (_type_) none 52)
)
)
;; definition for method 3 of type process-taskable
(defmethod inspect process-taskable ((obj process-taskable))
(let ((t9-0 (method-of-type process-drawable inspect)))
(t9-0 obj)
)
(format #t "~T~Ttasks: ~A~%" (-> obj tasks))
(format #t "~T~Tquery: #<gui-query @ #x~X>~%" (-> obj query))
(format
#t
"~T~Told-target-pos: #<transformq @ #x~X>~%"
(-> obj old-target-pos)
)
(format #t "~T~Tcell-for-task: ~D~%" (-> obj cell-for-task))
(format #t "~T~Tcell-x: ~D~%" (-> obj cell-x))
(format #t "~T~Tcam-joint-index: ~D~%" (-> obj cam-joint-index))
(format #t "~T~Tskippable: ~A~%" (-> obj skippable))
(format #t "~T~Tblend-on-exit: ~A~%" (-> obj blend-on-exit))
(format #t "~T~Tcamera: ~D~%" (-> obj camera))
(format #t "~T~Twill-talk: ~A~%" (-> obj will-talk))
(format #t "~T~Ttalk-message: ~D~%" (-> obj talk-message))
(format #t "~T~Tlast-talk: ~D~%" (-> obj last-talk))
(format #t "~T~Tbounce-away: ~A~%" (-> obj bounce-away))
(format #t "~T~Tambient: #<ambient-control @ #x~X>~%" (-> obj ambient))
(format #t "~T~Tcenter-joint-index: ~D~%" (-> obj center-joint-index))
(format #t "~T~Tdraw-bounds-y-offset: ~f~%" (-> obj draw-bounds-y-offset))
(format #t "~T~Tneck-joint-index: ~D~%" (-> obj neck-joint-index))
(format #t "~T~Tfuel-cell-anim: ~A~%" (-> obj fuel-cell-anim))
(format #t "~T~Tsound-flava: ~D~%" (-> obj sound-flava))
(format #t "~T~Thave-flava: ~A~%" (-> obj have-flava))
(format #t "~T~Tmusic: ~A~%" (-> obj music))
(format #t "~T~Thave-music: ~A~%" (-> obj have-music))
(format #t "~T~Tbeen-kicked: ~A~%" (-> obj been-kicked))
(format #t "~T~Tcur-trans-hook: ~A~%" (-> obj cur-trans-hook))
(format #t "~T~Tshadow-backup: ~A~%" (-> obj shadow-backup))
obj
)
;; failed to figure out what this is:
0