mirror of
https://github.com/open-goal/jak-project
synced 2026-07-09 23:01:56 -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:
+4
-6
@@ -1814,12 +1814,10 @@
|
||||
(s4-1 (the-as anim-test-sequence (-> s2-2 base)))
|
||||
)
|
||||
(when (not (logtest? (-> (the-as anim-test-seq-item gp-0) flags) 1))
|
||||
(let ((v1-57 s3-0)
|
||||
(a1-13 (+ (-> arg1 xpos) (* (-> *ANIM_TESTER-bank* EDIT_STATS_X) (-> *DISP_LIST-bank* CHAR_WIDTH))))
|
||||
(a0-29 (-> arg1 ypos))
|
||||
)
|
||||
(set! (-> v1-57 origin x) (the float a1-13))
|
||||
(set! (-> v1-57 origin y) (the float a0-29))
|
||||
(set-origin!
|
||||
s3-0
|
||||
(+ (-> arg1 xpos) (* (-> *ANIM_TESTER-bank* EDIT_STATS_X) (-> *DISP_LIST-bank* CHAR_WIDTH)))
|
||||
(-> arg1 ypos)
|
||||
)
|
||||
(cond
|
||||
((and (< (-> (the-as anim-test-seq-item gp-0) speed) 0) (< -100 (-> (the-as anim-test-seq-item gp-0) speed)))
|
||||
|
||||
+2
-14
@@ -1001,13 +1001,7 @@
|
||||
(draw-string "..." s1-0 s5-0)
|
||||
(set! arg4 (and (zero? arg3) arg4))
|
||||
(when arg4
|
||||
(let ((v1-12 s5-0)
|
||||
(a1-5 20)
|
||||
(a0-10 204)
|
||||
)
|
||||
(set! (-> v1-12 origin x) (the float a1-5))
|
||||
(set! (-> v1-12 origin y) (the float a0-10))
|
||||
)
|
||||
(set-origin! s5-0 20 204)
|
||||
(draw-string-adv (-> arg0 name) s1-0 s5-0)
|
||||
(draw-string-adv ":" s1-0 s5-0)
|
||||
(draw-string (-> arg0 display-str) s1-0 s5-0)
|
||||
@@ -1115,13 +1109,7 @@
|
||||
(font-color menu)
|
||||
)
|
||||
)
|
||||
(let ((v1-16 (-> arg0 context font))
|
||||
(a1-5 s3-1)
|
||||
(a0-18 s2-1)
|
||||
)
|
||||
(set! (-> v1-16 origin x) (the float a1-5))
|
||||
(set! (-> v1-16 origin y) (the float a0-18))
|
||||
)
|
||||
(set-origin! (-> arg0 context font) s3-1 s2-1)
|
||||
(set! sv-16 (-> *display* frames (-> *display* on-screen) frame debug-buf))
|
||||
(set! sv-32 (-> sv-16 base))
|
||||
(draw-string ">" sv-16 (-> arg0 context font))
|
||||
|
||||
Reference in New Issue
Block a user