mirror of
https://github.com/open-goal/jak-project
synced 2026-08-05 17:44:39 -04:00
[decompiler] as-type and font method support (#3855)
Add support for `as-type` macro, and detecting inline font methods. This works in all three games but I've only updated jak 3's goal_src for now. Eventually I will go back and work through the others, but I want to get more decompiler features in first.  --------- Co-authored-by: water111 <awaterford1111445@gmail.com>
This commit is contained in:
+9
-32
@@ -237,13 +237,9 @@
|
||||
(defmethod link-art! ((this art-group))
|
||||
(when this
|
||||
(countdown (s5-0 (-> this length))
|
||||
(let* ((s3-0 (-> this data s5-0))
|
||||
(s4-0 (if (type? s3-0 art-joint-anim)
|
||||
(the-as art-joint-anim s3-0)
|
||||
)
|
||||
)
|
||||
(s2-0 #f)
|
||||
)
|
||||
(let ((s4-0 (as-type (-> this data s5-0) art-joint-anim))
|
||||
(s2-0 #f)
|
||||
)
|
||||
(when s4-0
|
||||
(let ((s3-1 7))
|
||||
(while (begin (label cfg-24) (nonzero? s3-1))
|
||||
@@ -290,13 +286,9 @@
|
||||
(defmethod unlink-art! ((this art-group))
|
||||
(when this
|
||||
(countdown (s5-0 (-> this length))
|
||||
(let* ((s3-0 (-> this data s5-0))
|
||||
(s4-0 (if (type? s3-0 art-joint-anim)
|
||||
(the-as art-joint-anim s3-0)
|
||||
)
|
||||
)
|
||||
(s3-1 #f)
|
||||
)
|
||||
(let ((s4-0 (as-type (-> this data s5-0) art-joint-anim))
|
||||
(s3-1 #f)
|
||||
)
|
||||
(when s4-0
|
||||
(let ((s2-0 7))
|
||||
(while (begin (label cfg-13) (nonzero? s2-0))
|
||||
@@ -2068,12 +2060,7 @@
|
||||
)
|
||||
)
|
||||
(when (= arg5 -99.0)
|
||||
(let ((s2-1 arg0))
|
||||
(set! sv-28 (if (type? s2-1 process-drawable)
|
||||
(the-as process-drawable s2-1)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! sv-28 (as-type arg0 process-drawable))
|
||||
(set! arg5 (if sv-28
|
||||
(vector-vector-distance (target-pos 0) (-> sv-28 root trans))
|
||||
-1.0
|
||||
@@ -2106,12 +2093,7 @@
|
||||
(((gui-action queue) (gui-action play) (gui-action playing) (gui-action fade))
|
||||
(let ((f30-0 (-> arg0 priority)))
|
||||
(when (= f30-0 -99.0)
|
||||
(let* ((s2-0 (get-process arg0))
|
||||
(v1-10 (if (type? s2-0 process-drawable)
|
||||
(the-as process-drawable s2-0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-10 (as-type (get-process arg0) process-drawable)))
|
||||
(set! f30-0 (cond
|
||||
((= (-> arg0 id) (-> this ids (-> arg0 channel)))
|
||||
-1.0
|
||||
@@ -2285,12 +2267,7 @@
|
||||
(when (and (logtest? (-> arg0 flags) (gui-connection-flags gcf1 fo-curve fo-min fo-max))
|
||||
(logtest? (-> arg0 flags) (gui-connection-flags gcf0))
|
||||
)
|
||||
(let* ((s5-1 (get-process arg0))
|
||||
(s4-1 (if (type? s5-1 process-drawable)
|
||||
s5-1
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((s4-1 (the-as process (as-type (get-process arg0) process-drawable))))
|
||||
(when (and s4-1 (nonzero? (-> (the-as process-drawable s4-1) root)))
|
||||
(when *sound-player-enable*
|
||||
(let ((s5-2 (the-as sound-rpc-set-param (get-sound-buffer-entry))))
|
||||
|
||||
Reference in New Issue
Block a user