mirror of
https://github.com/open-goal/jak-project
synced 2026-08-14 20:43:54 -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:
+8
-22
@@ -218,13 +218,9 @@
|
||||
)
|
||||
(-> (the-as pair (-> (the-as pair (-> (the-as pair s4-0) cdr)) cdr)) car)
|
||||
(-> (the-as pair (-> (the-as pair (-> (the-as pair (-> (the-as pair s4-0) cdr)) cdr)) cdr)) car)
|
||||
(let* ((s3-0 (-> (the-as symbol v1-0) value))
|
||||
(v1-1 (if (type? s3-0 level-load-info)
|
||||
s3-0
|
||||
)
|
||||
)
|
||||
(a0-11 (-> (the-as pair (-> (the-as pair s4-0) cdr)) cdr))
|
||||
)
|
||||
(let ((v1-1 (as-type (-> (the-as symbol v1-0) value) level-load-info))
|
||||
(a0-11 (-> (the-as pair (-> (the-as pair s4-0) cdr)) cdr))
|
||||
)
|
||||
(when (and v1-1 (-> (the-as level-load-info v1-1) borrow))
|
||||
(case s5-0
|
||||
(('alias)
|
||||
@@ -2350,15 +2346,9 @@
|
||||
)
|
||||
)
|
||||
(set! (-> gp-0 origin x) 120.0)
|
||||
(let ((v1-7 gp-0))
|
||||
(set! (-> v1-7 scale) 0.7)
|
||||
)
|
||||
(let ((v1-8 gp-0))
|
||||
(set! (-> v1-8 width) (the float 300))
|
||||
)
|
||||
(let ((v1-9 gp-0))
|
||||
(set! (-> v1-9 height) (the float 35))
|
||||
)
|
||||
(set-scale! gp-0 0.7)
|
||||
(set-width! gp-0 300)
|
||||
(set-height! gp-0 35)
|
||||
(set! (-> gp-0 flags) (font-flags shadow kerning middle middle-vert large))
|
||||
(let ((s4-0 (if (logtest? (-> this params flags) (resetter-flag text-message))
|
||||
(the-as int (-> this params text-message))
|
||||
@@ -2374,16 +2364,12 @@
|
||||
)
|
||||
)
|
||||
(when (= (-> this params message) (resetter-message mission-fail-or-retry))
|
||||
(let ((v1-17 gp-0))
|
||||
(set! (-> v1-17 height) (the float 95))
|
||||
)
|
||||
(set-height! gp-0 95)
|
||||
(let ((s5-1 print-game-text))
|
||||
(format (clear *temp-string*) (lookup-text! *common-text* (text-id text-008b) #f) 1)
|
||||
(s5-1 *temp-string* gp-0 #f 44 (bucket-id hud-draw-hud-alpha))
|
||||
)
|
||||
(let ((v1-19 gp-0))
|
||||
(set! (-> v1-19 height) (the float 155))
|
||||
)
|
||||
(set-height! gp-0 155)
|
||||
(let ((s5-2 print-game-text))
|
||||
(format (clear *temp-string*) (lookup-text! *common-text* (text-id text-0081) #f) 1)
|
||||
(s5-2 *temp-string* gp-0 #f 44 (bucket-id hud-draw-hud-alpha))
|
||||
|
||||
Reference in New Issue
Block a user