mirror of
https://github.com/open-goal/jak-project
synced 2026-07-26 06:37:29 -04:00
d/jak2: finish cty-guard-turret-button | race-h | height-map-h and a lot of rigid-body (#1957)
Also cleaned up `data_decompiler.cpp` to make it a lot less verbose to add a special case for an array field.
This commit is contained in:
+27
-27
@@ -1332,7 +1332,7 @@
|
||||
(collide-shape-method-51 () none 51)
|
||||
(collide-shape-method-52 () none 52)
|
||||
(collide-shape-method-53 () none 53)
|
||||
(collide-shape-method-54 () none 54)
|
||||
(collide-shape-method-54 (_type_) none 54)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -1582,32 +1582,32 @@
|
||||
|
||||
;; definition of type collide-shape-moving
|
||||
(deftype collide-shape-moving (collide-shape)
|
||||
((rider-time time-frame :offset-assert 200)
|
||||
(rider-last-move vector :inline :offset-assert 208)
|
||||
(trans-old vector :inline :offset-assert 224)
|
||||
(poly-pat pat-surface :offset 272)
|
||||
(cur-pat pat-surface :offset-assert 276)
|
||||
(ground-pat pat-surface :offset-assert 280)
|
||||
(status cshape-moving-flags :offset-assert 288)
|
||||
(old-status cshape-moving-flags :offset-assert 296)
|
||||
(prev-status cshape-moving-flags :offset-assert 304)
|
||||
(reaction-flag cshape-reaction-flags :offset-assert 312)
|
||||
(reaction function :offset-assert 316)
|
||||
(no-reaction function :offset-assert 320)
|
||||
(local-normal vector :inline :offset-assert 336)
|
||||
(surface-normal vector :inline :offset-assert 352)
|
||||
(poly-normal vector :inline :offset-assert 368)
|
||||
(ground-poly-normal vector :inline :offset-assert 384)
|
||||
(gspot-pos vector :inline :offset-assert 400)
|
||||
(gspot-normal vector :inline :offset-assert 416)
|
||||
(grount-touch-point vector :inline :offset-assert 432)
|
||||
(ground-impact-vel meters :offset-assert 448)
|
||||
(surface-angle float :offset-assert 452)
|
||||
(poly-angle float :offset-assert 456)
|
||||
(touch-angle float :offset-assert 460)
|
||||
(coverage float :offset-assert 464)
|
||||
(dynam dynamics :offset-assert 468)
|
||||
(surf surface :offset-assert 472)
|
||||
((rider-time time-frame :offset-assert 200)
|
||||
(rider-last-move vector :inline :offset-assert 208)
|
||||
(trans-old vector :inline :offset-assert 224)
|
||||
(poly-pat pat-surface :offset 272)
|
||||
(cur-pat pat-surface :offset-assert 276)
|
||||
(ground-pat pat-surface :offset-assert 280)
|
||||
(status cshape-moving-flags :offset-assert 288)
|
||||
(old-status cshape-moving-flags :offset-assert 296)
|
||||
(prev-status cshape-moving-flags :offset-assert 304)
|
||||
(reaction-flag cshape-reaction-flags :offset-assert 312)
|
||||
(reaction (function control-info collide-query vector vector cshape-moving-flags) :offset-assert 316)
|
||||
(no-reaction function :offset-assert 320)
|
||||
(local-normal vector :inline :offset-assert 336)
|
||||
(surface-normal vector :inline :offset-assert 352)
|
||||
(poly-normal vector :inline :offset-assert 368)
|
||||
(ground-poly-normal vector :inline :offset-assert 384)
|
||||
(gspot-pos vector :inline :offset-assert 400)
|
||||
(gspot-normal vector :inline :offset-assert 416)
|
||||
(grount-touch-point vector :inline :offset-assert 432)
|
||||
(ground-impact-vel meters :offset-assert 448)
|
||||
(surface-angle float :offset-assert 452)
|
||||
(poly-angle float :offset-assert 456)
|
||||
(touch-angle float :offset-assert 460)
|
||||
(coverage float :offset-assert 464)
|
||||
(dynam dynamics :offset-assert 468)
|
||||
(surf surface :offset-assert 472)
|
||||
)
|
||||
:method-count-assert 68
|
||||
:size-assert #x1dc
|
||||
|
||||
+3
-3
@@ -39,9 +39,9 @@
|
||||
:size-assert #xe8
|
||||
:flag-assert #xc000000e8
|
||||
(:methods
|
||||
(touching-prims-entry-method-9 () none 9)
|
||||
(touching-prims-entry-method-10 () none 10)
|
||||
(touching-prims-entry-method-11 () none 11)
|
||||
(touching-prims-entry-method-9 (_type_ vector) vector 9)
|
||||
(touching-prims-entry-method-10 (_type_ collide-shape touching-shapes-entry) collide-shape-prim 10)
|
||||
(touching-prims-entry-method-11 (_type_ collide-shape touching-shapes-entry) collide-tri-result 11)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+1
-1
@@ -452,7 +452,7 @@
|
||||
(set! (-> collision-shape total-prims) (the-as uint 1))
|
||||
(set! (-> collision-shape root-prim) collision-mesh)
|
||||
)
|
||||
((method-of-object collision-shape collide-shape-method-54))
|
||||
(collide-shape-method-54 collision-shape)
|
||||
(set! (-> collision-shape nav-radius) (* 0.75 (-> collision-shape root-prim local-sphere w)))
|
||||
(let ((prim (-> collision-shape root-prim)))
|
||||
(set! (-> collision-shape backup-collide-as) (-> prim prim-core collide-as))
|
||||
|
||||
+1
-1
@@ -77,7 +77,7 @@
|
||||
(set! (-> collision-shape total-prims) (the-as uint 1))
|
||||
(set! (-> collision-shape root-prim) collision-mesh)
|
||||
)
|
||||
((method-of-object collision-shape collide-shape-method-54))
|
||||
(collide-shape-method-54 collision-shape)
|
||||
(set! (-> collision-shape nav-radius) (* 0.75 (-> collision-shape root-prim local-sphere w)))
|
||||
(let ((prim (-> collision-shape root-prim)))
|
||||
(set! (-> collision-shape backup-collide-as) (-> prim prim-core collide-as))
|
||||
|
||||
+1
-1
@@ -17,7 +17,7 @@
|
||||
(water water-control :offset-assert 172)
|
||||
(sound ambient-sound :offset-assert 176)
|
||||
(carry basic :offset-assert 180)
|
||||
(rbody basic :offset-assert 184)
|
||||
(rbody rigid-body-control :offset-assert 184)
|
||||
(state-flags state-flags :offset-assert 188)
|
||||
(state-time time-frame :offset-assert 192)
|
||||
)
|
||||
|
||||
-4
@@ -41,7 +41,3 @@
|
||||
|
||||
;; failed to figure out what this is:
|
||||
0
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
+70
-70
@@ -81,6 +81,7 @@
|
||||
(cm-joint-x meters :offset 32)
|
||||
(cm-joint-y meters :offset 36)
|
||||
(cm-joint-z meters :offset 40)
|
||||
(cm-joint-w float :offset 44)
|
||||
(linear-damping float :offset 8)
|
||||
(angular-damping float :offset 12)
|
||||
(bounce-factor float :offset 16)
|
||||
@@ -93,7 +94,7 @@
|
||||
(gravity meters :offset 192)
|
||||
(idle-distance meters :offset 196)
|
||||
(attack-force-scale float :offset 200)
|
||||
(name basic :offset-assert 204)
|
||||
(name symbol :offset-assert 204)
|
||||
)
|
||||
:method-count-assert 9
|
||||
:size-assert #xd0
|
||||
@@ -165,32 +166,32 @@
|
||||
|
||||
;; definition of type rigid-body
|
||||
(deftype rigid-body (structure)
|
||||
((work basic :offset-assert 0)
|
||||
(info rigid-body-info :offset-assert 4)
|
||||
(flags rigid-body-flag :offset-assert 8)
|
||||
(force-callback basic :offset-assert 12)
|
||||
(blocked-by basic :offset-assert 16)
|
||||
(time-remaining float :offset-assert 20)
|
||||
(step-count int16 :offset-assert 24)
|
||||
(position vector :inline :offset-assert 32)
|
||||
(rot vector :inline :offset-assert 48)
|
||||
(rotation quaternion :inline :offset 48)
|
||||
(lin-momentum vector :inline :offset-assert 64)
|
||||
(ang-momentum vector :inline :offset-assert 80)
|
||||
(force vector :inline :offset-assert 96)
|
||||
(torque vector :inline :offset-assert 112)
|
||||
(lin-velocity vector :inline :offset-assert 128)
|
||||
(ang-velocity vector :inline :offset-assert 144)
|
||||
(matrix matrix :inline :offset-assert 160)
|
||||
(inv-i-world matrix :inline :offset-assert 224)
|
||||
((work rigid-body-work :offset-assert 0)
|
||||
(info rigid-body-info :offset-assert 4)
|
||||
(flags rigid-body-flag :offset-assert 8)
|
||||
(force-callback (function object float none) :offset-assert 12)
|
||||
(blocked-by basic :offset-assert 16)
|
||||
(time-remaining float :offset-assert 20)
|
||||
(step-count int16 :offset-assert 24)
|
||||
(position vector :inline :offset-assert 32)
|
||||
(rot vector :inline :offset-assert 48)
|
||||
(rotation quaternion :inline :offset 48)
|
||||
(lin-momentum vector :inline :offset-assert 64)
|
||||
(ang-momentum vector :inline :offset-assert 80)
|
||||
(force vector :inline :offset-assert 96)
|
||||
(torque vector :inline :offset-assert 112)
|
||||
(lin-velocity vector :inline :offset-assert 128)
|
||||
(ang-velocity vector :inline :offset-assert 144)
|
||||
(matrix matrix :inline :offset-assert 160)
|
||||
(inv-i-world matrix :inline :offset-assert 224)
|
||||
)
|
||||
:method-count-assert 32
|
||||
:size-assert #x120
|
||||
:flag-assert #x2000000120
|
||||
(:methods
|
||||
(rigid-body-method-9 (_type_) none 9)
|
||||
(rigid-body-method-9 (_type_ collide-shape-moving float) none 9)
|
||||
(rigid-body-method-10 (_type_) none 10)
|
||||
(rigid-body-method-11 (_type_) none 11)
|
||||
(rigid-body-method-11 (_type_ collide-shape-moving) none 11)
|
||||
(rigid-body-method-12 (_type_ float) none 12)
|
||||
(rigid-body-method-13 (_type_) none 13)
|
||||
(rigid-body-method-14 (_type_ float) none 14)
|
||||
@@ -204,7 +205,7 @@
|
||||
(rigid-body-method-22 (_type_ vector vector) vector 22)
|
||||
(rigid-body-method-23 (_type_ vector) vector 23)
|
||||
(rigid-body-method-24 (_type_) none 24)
|
||||
(rigid-body-method-25 (_type_ rigid-body-info vector quaternion basic) none 25)
|
||||
(rigid-body-method-25 (_type_ rigid-body-info vector quaternion function) none 25)
|
||||
(rigid-body-method-26 (_type_ vector quaternion) none 26)
|
||||
(print-physics (_type_ object) none 27)
|
||||
(print-force-torque (_type_ object) none 28)
|
||||
@@ -291,9 +292,10 @@
|
||||
:size-assert #x130
|
||||
:flag-assert #x1a00000130
|
||||
(:methods
|
||||
(rigid-body-control-method-9 (_type_) none 9)
|
||||
(rigid-body-control-method-10 (_type_) none 10)
|
||||
(rigid-body-control-method-11 (_type_) none 11)
|
||||
(new (symbol type process) _type_ 0)
|
||||
(rigid-body-control-method-9 (_type_ collide-shape-moving float) none 9)
|
||||
(rigid-body-control-method-10 (_type_ rigid-body-object float float) object 10)
|
||||
(rigid-body-control-method-11 (_type_ collide-shape-moving) none 11)
|
||||
(rigid-body-control-method-12 (_type_ float) none 12)
|
||||
(rigid-body-control-method-13 (_type_) none 13)
|
||||
(rigid-body-control-method-14 (_type_ float) none 14)
|
||||
@@ -364,20 +366,21 @@
|
||||
)
|
||||
|
||||
;; definition for method 9 of type rigid-body-control
|
||||
(defmethod rigid-body-control-method-9 rigid-body-control ((obj rigid-body-control))
|
||||
(rigid-body-method-9 (-> obj state))
|
||||
(defmethod rigid-body-control-method-9 rigid-body-control ((obj rigid-body-control) (arg0 collide-shape-moving) (arg1 float))
|
||||
(rigid-body-method-9 (-> obj state) arg0 arg1)
|
||||
(none)
|
||||
)
|
||||
|
||||
;; definition for method 10 of type rigid-body-control
|
||||
(defmethod rigid-body-control-method-10 rigid-body-control ((obj rigid-body-control))
|
||||
(rigid-body-method-10 (-> obj state))
|
||||
(none)
|
||||
;; INFO: this function exists in multiple non-identical object files
|
||||
;; WARN: Return type mismatch none vs object.
|
||||
(defmethod rigid-body-control-method-10 rigid-body-control ((obj rigid-body-control) (arg0 rigid-body-object) (arg1 float) (arg2 float))
|
||||
(the-as object (rigid-body-method-10 (-> obj state)))
|
||||
)
|
||||
|
||||
;; definition for method 11 of type rigid-body-control
|
||||
(defmethod rigid-body-control-method-11 rigid-body-control ((obj rigid-body-control))
|
||||
(rigid-body-method-11 (-> obj state))
|
||||
(defmethod rigid-body-control-method-11 rigid-body-control ((obj rigid-body-control) (arg0 collide-shape-moving))
|
||||
(rigid-body-method-11 (-> obj state) arg0)
|
||||
(none)
|
||||
)
|
||||
|
||||
@@ -453,7 +456,7 @@
|
||||
|
||||
;; definition for method 24 of type rigid-body-control
|
||||
(defmethod rigid-body-control-method-24 rigid-body-control ((obj rigid-body-control) (arg0 rigid-body-info) (arg1 vector) (arg2 quaternion) (arg3 basic))
|
||||
(rigid-body-method-25 (-> obj state) arg0 arg1 arg2 arg3)
|
||||
(rigid-body-method-25 (-> obj state) arg0 arg1 arg2 (the-as function arg3))
|
||||
(none)
|
||||
)
|
||||
|
||||
@@ -465,7 +468,8 @@
|
||||
|
||||
;; definition of type rigid-body-object
|
||||
(deftype rigid-body-object (process-focusable)
|
||||
((info rigid-body-object-constants :offset-assert 204)
|
||||
((root-override collide-shape-moving :offset 128)
|
||||
(info rigid-body-object-constants :offset-assert 204)
|
||||
(flags rigid-body-object-flag :offset-assert 208)
|
||||
(max-time-step float :offset-assert 216)
|
||||
(incoming-attack-id uint32 :offset-assert 220)
|
||||
@@ -479,32 +483,32 @@
|
||||
:size-assert #x110
|
||||
:flag-assert #x3500900110
|
||||
(:methods
|
||||
(rigid-body-object-method-27 () none 27)
|
||||
(rigid-body-object-method-28 () none 28)
|
||||
(rigid-body-object-method-29 () none 29)
|
||||
(rigid-body-object-method-30 () none 30)
|
||||
(rigid-body-object-method-31 () none 31)
|
||||
(rigid-body-object-method-32 () none 32)
|
||||
(rigid-body-object-method-33 () none 33)
|
||||
(rigid-body-object-method-34 () none 34)
|
||||
(rigid-body-object-method-35 () none 35)
|
||||
(idle () _type_ :state 27)
|
||||
(active () _type_ :state 28)
|
||||
(rigid-body-object-method-29 (_type_) none 29)
|
||||
(rigid-body-object-method-30 (_type_) none 30)
|
||||
(rigid-body-object-method-31 (_type_ rigid-body-object-constants) none 31)
|
||||
(rigid-body-object-method-32 (_type_) none 32)
|
||||
(rigid-body-object-method-33 (_type_) none 33)
|
||||
(rigid-body-object-method-34 (_type_) none 34)
|
||||
(rigid-body-object-method-35 (_type_) none 35)
|
||||
(rigid-body-object-method-36 () none 36)
|
||||
(rigid-body-object-method-37 () none 37)
|
||||
(rigid-body-object-method-38 () none 38)
|
||||
(rigid-body-object-method-39 () none 39)
|
||||
(rigid-body-object-method-40 () none 40)
|
||||
(rigid-body-object-method-41 () none 41)
|
||||
(rigid-body-object-method-42 () none 42)
|
||||
(rigid-body-object-method-43 () none 43)
|
||||
(rigid-body-object-method-44 () none 44)
|
||||
(rigid-body-object-method-37 (_type_) none 37)
|
||||
(rigid-body-object-method-38 (_type_) none 38)
|
||||
(rigid-body-object-method-39 (_type_) none 39)
|
||||
(rigid-body-object-method-40 (_type_) none 40)
|
||||
(rigid-body-object-method-41 (_type_) none 41)
|
||||
(rigid-body-object-method-42 (_type_) none :behavior rigid-body-object 42)
|
||||
(rigid-body-object-method-43 (_type_) none 43)
|
||||
(rigid-body-object-method-44 (_type_ float) none 44)
|
||||
(rigid-body-object-method-45 () none 45)
|
||||
(rigid-body-object-method-46 () none 46)
|
||||
(rigid-body-object-method-47 () none 47)
|
||||
(rigid-body-object-method-48 () none 48)
|
||||
(rigid-body-object-method-49 () none 49)
|
||||
(rigid-body-object-method-50 () none 50)
|
||||
(rigid-body-object-method-51 () none 51)
|
||||
(rigid-body-object-method-52 () none 52)
|
||||
(rigid-body-object-method-46 (_type_ process-drawable int symbol event-message-block) none :behavior rigid-body-object 46)
|
||||
(rigid-body-object-method-47 (_type_ process-drawable attack-info object penetrate) symbol 47)
|
||||
(rigid-body-object-method-48 (_type_ object object) none 48)
|
||||
(rigid-body-object-method-49 (_type_ matrix touching-shapes-entry) none 49)
|
||||
(rigid-body-object-method-50 (_type_ float) none 50)
|
||||
(rigid-body-object-method-51 (_type_) none 51)
|
||||
(rigid-body-object-method-52 (_type_) none 52)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -568,14 +572,14 @@
|
||||
:size-assert #x408
|
||||
:flag-assert #x1100000408
|
||||
(:methods
|
||||
(rigid-body-queue-method-9 () none 9)
|
||||
(rigid-body-queue-method-10 () none 10)
|
||||
(rigid-body-queue-method-11 () none 11)
|
||||
(rigid-body-queue-method-12 () none 12)
|
||||
(rigid-body-queue-method-13 () none 13)
|
||||
(rigid-body-queue-method-14 () none 14)
|
||||
(rigid-body-queue-method-15 () none 15)
|
||||
(rigid-body-queue-method-16 () none 16)
|
||||
(rigid-body-queue-method-9 (_type_) none 9)
|
||||
(rigid-body-queue-method-10 (_type_) none 10)
|
||||
(rigid-body-queue-method-11 (_type_) none 11)
|
||||
(rigid-body-queue-method-12 (_type_ int int) none 12)
|
||||
(rigid-body-queue-method-13 (_type_) none 13)
|
||||
(rigid-body-queue-method-14 (_type_ int) none 14)
|
||||
(rigid-body-queue-method-15 (_type_) none 15)
|
||||
(validate (_type_) symbol 16)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -594,7 +598,3 @@
|
||||
|
||||
;; failed to figure out what this is:
|
||||
0
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
+1131
File diff suppressed because it is too large
Load Diff
+2
-4
@@ -16,7 +16,7 @@
|
||||
(process-focusable-method-23 (_type_) none 23)
|
||||
(process-focusable-method-24 (_type_) float 24)
|
||||
(process-focusable-method-25 (_type_) time-frame 25)
|
||||
(process-focusable-method-26 (_type_) none 26)
|
||||
(process-focusable-method-26 (_type_) float 26)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -80,10 +80,8 @@
|
||||
)
|
||||
|
||||
;; definition for method 26 of type process-focusable
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod process-focusable-method-26 process-focusable ((obj process-focusable))
|
||||
0
|
||||
(none)
|
||||
0.0
|
||||
)
|
||||
|
||||
;; definition for method 25 of type process-focusable
|
||||
|
||||
+4
-4
@@ -11,7 +11,7 @@
|
||||
(max-delay uint16 :offset-assert 8)
|
||||
(delay uint16 :offset-assert 10)
|
||||
(play-index int16 :offset-assert 12)
|
||||
(list basic :offset-assert 16)
|
||||
(list (array string) :offset-assert 16)
|
||||
)
|
||||
:method-count-assert 9
|
||||
:size-assert #x14
|
||||
@@ -128,15 +128,15 @@
|
||||
|
||||
;; definition of type speech-control
|
||||
(deftype speech-control (structure)
|
||||
((channel-array speech-channel 2 :inline :offset-assert 0)
|
||||
(speech-table uint32 57 :offset-assert 224)
|
||||
((channel-array speech-channel 2 :inline :offset-assert 0)
|
||||
(speech-table speech-type-info 57 :offset-assert 224)
|
||||
)
|
||||
:method-count-assert 17
|
||||
:size-assert #x1c4
|
||||
:flag-assert #x11000001c4
|
||||
(:methods
|
||||
(speech-control-method-9 () none 9)
|
||||
(speech-control-method-10 () none 10)
|
||||
(speech-control-method-10 (_type_ int speech-type-info) none 10)
|
||||
(speech-control-method-11 (_type_) none 11)
|
||||
(speech-control-method-12 () none 12)
|
||||
(speech-control-method-13 () none 13)
|
||||
|
||||
Reference in New Issue
Block a user