[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.


![image](https://github.com/user-attachments/assets/5c31bf85-97b4-437c-bc4b-dc054e60551e)

---------

Co-authored-by: water111 <awaterford1111445@gmail.com>
This commit is contained in:
water111
2025-02-01 21:23:11 -05:00
committed by GitHub
parent d5590ab638
commit 48cb9bb787
645 changed files with 5391 additions and 16694 deletions
+1 -7
View File
@@ -483,13 +483,7 @@
#f
)
((-> arg0 mode-name)
(let ((s5-1 (-> arg0 mode-name value)))
(set! (-> arg0 cam-mode) (the-as symbol (if (type? s5-1 state)
s5-1
)
)
)
)
(set! (-> arg0 cam-mode) (the-as symbol (the-as object (as-type (-> arg0 mode-name value) state))))
(set! (-> arg0 real-entity-name) #f)
#f
)
+1 -5
View File
@@ -2619,11 +2619,7 @@
)
)
((or (logtest? (-> self options) (cam-slave-options-u32 BUTT_CAM))
(let ((s3-0 (handle->process (-> *camera* settings butt-handle))))
(if (type? s3-0 process-drawable)
s3-0
)
)
(the-as object (as-type (handle->process (-> *camera* settings butt-handle)) process-drawable))
)
(vector-normalize-copy! gp-3 (-> self view-flat) 1.0)
(let ((v1-283 (handle->process (-> *camera* settings butt-handle))))