Files
jak-project/goal_src/jak3/engine/ui/progress/progress-draw.gc
T
Jordan 427c952558 [Jak 2 and Jak 3]: Fixing menu text boundaries and drawing alignments for Automatic and Custom aspect ratios (#4380)
This PR fixes the alignment of text and other elements in several menus
of Jak 3 (as well as some of Jak 2) when using Automatic or Custom
aspect ratios. It also cleans up some of the relevant functions which
are used to draw these menus (although I'm still learning how to clean
goal code).

I mostly used french text for testing (since the french text seems to
push the font boundaries to their limits a bit more).
I used Automatic 16:9 and Custom 4:1 aspect ratios for testing to see if
my changes scale to other aspect ratios properly, comparing with PS2 4:3
for reference.



### Jak 3

### Image Color Scale

Before:
- The black/white color scale would get stretched (beyond the limits of
the menu in 4x1)
<img width="1280" height="758" alt="color-scale-16x9-broken"
src="https://github.com/user-attachments/assets/4b3b897e-1417-42da-86a1-dd78926ccb73"
/>
<img width="1283" height="747" alt="color-scale-4x1-broken"
src="https://github.com/user-attachments/assets/44d192ba-5afe-43ae-9419-021123478a31"
/>

Reference (PS2 4:3 in OpenGoal):
<img width="1278" height="773" alt="color-scale-reference"
src="https://github.com/user-attachments/assets/d9bd8f4e-8f69-49a9-8a99-3fcd3d7a4097"
/>

After fixes:

<img width="1283" height="765" alt="color-scale-16x9-fixed"
src="https://github.com/user-attachments/assets/99422d7f-d688-4d91-8ce0-6ad0b7cb10df"
/>
<img width="1282" height="762" alt="color-scale-4x1-fixed"
src="https://github.com/user-attachments/assets/6011f30a-0c31-4ea9-afe1-735ec36f3d32"
/>




### Secrets menu

Before:
- The secret titles touch their costs (#4233).
- The alignment of the top line showing orbs available/cost and total
orbs collected is broken (more noticeable in 4:1)
- The alignment of the titles for groups of secrets is broken (more
noticeable in 4:1)
- The indentation for secret titles relative to the group of secrets is
also broken (again, more noticeable in 4:1)
<img width="1286" height="758" alt="secrets-broken-16x9"
src="https://github.com/user-attachments/assets/bd6c7dab-ce95-4349-bf1d-2a09f82fcbfe"
/>
<img width="1287" height="751" alt="secrets-broken-4x1"
src="https://github.com/user-attachments/assets/3e1ce842-19ba-49b3-92f9-52034ae1982f"
/>

Reference (PS2 4:3 in OpenGoal):

<img width="1280" height="761" alt="Screenshot from 2026-08-16 22-58-22"
src="https://github.com/user-attachments/assets/7326a1c7-b479-4fb7-9450-377a05ab7963"
/>

After fixes:
<img width="1280" height="722" alt="secrets-fixed-16x9"
src="https://github.com/user-attachments/assets/0a66d45f-3aa3-4cc8-ac88-c6aef20f1319"
/>
<img width="1286" height="713" alt="secrets-fixed-4x1"
src="https://github.com/user-attachments/assets/e8740739-42ac-4a12-aad1-e6620dfc73ed"
/>



### Secrets purchase menu

Before: 

- The text for the secret you're purchasing can get cut off if too big.
- As before, the top line showing orb cost/orbs collected is misaligned.
<img width="1288" height="754" alt="secrets-purchase-broken-16x9"
src="https://github.com/user-attachments/assets/49b709e3-c015-42ba-b0aa-034769286d77"
/>
<img width="1281" height="756" alt="secrets-purchase-broken-4x1"
src="https://github.com/user-attachments/assets/0c3c5e02-048a-4188-ada7-2413c384224b"
/>

Reference (PS2 4:3 in OpenGoal):

<img width="1286" height="753" alt="secrets-purchase-reference"
src="https://github.com/user-attachments/assets/bb0b1d1a-87f6-4343-8a82-2e1f968943cd"
/>

After fixes:
<img width="1286" height="759" alt="secrets-purchase-fixed-16x9"
src="https://github.com/user-attachments/assets/1d73593f-1d58-407e-9ce6-2da5bf0fd84b"
/>
<img width="1283" height="750" alt="secrets-purchase-fixed-4x1"
src="https://github.com/user-attachments/assets/85c7e14d-c6b2-4b21-83e5-173af5cba185"
/>


### Save/Load/Create Hero Mode Save menu

Here I show the load game screen only but the bugs were the same among
all 3 as the code is shared. The fixes apply to all 3 as well 😃

Before:

- The header text is cut off in french. 
- There is a faint red rectangle to the right of the menu (look closely!
It's a bit clearer and goes beyond the menu in 4x1).
- The left yellow boxes around the save-games that are not selected do
not scale properly (more noticeable in 4x1).

<img width="1284" height="749" alt="load-broken-Automatic"
src="https://github.com/user-attachments/assets/2ae3bd8b-42ec-49bc-9851-cbaace4ce64b"
/>
<img width="1285" height="751" alt="load-broken-4x1"
src="https://github.com/user-attachments/assets/655de844-748c-43f9-a2e8-d779fe3a8e19"
/>

Reference (PS2 4:3 in OpenGoal):
<img width="1281" height="762" alt="load-screen-4x3"
src="https://github.com/user-attachments/assets/e4e320c9-999a-44a7-8b3e-34cfdbeef5a1"
/>



After Fixes:

- Now headers that exceed the width of the menu screen will be shrunken
down to fit. This will hopefully work for any other menus that need it
as well 😃
- No more red rectangle on the right, and the yellow box to the left
around the save games scales properly.

<img width="1286" height="754" alt="load-fixed-automatic"
src="https://github.com/user-attachments/assets/1a48d811-5684-4f7e-a12a-19e896e30b48"
/>
<img width="1288" height="749" alt="load-fixed-4x1"
src="https://github.com/user-attachments/assets/f5a68cb1-576a-4927-977b-b3419aaf7c23"
/>


### Missions menu 

Before:

- Mission text is sometimes cut off on the right
- Mission text is shifted to the right (more noticeable in 4x1)

<img width="1286" height="753" alt="missions-alignment-broken-16x9"
src="https://github.com/user-attachments/assets/37175eb7-e191-4c09-bb72-b40819acd99b"
/>
<img width="1281" height="750" alt="missions-alignment-broken-16x9-2"
src="https://github.com/user-attachments/assets/482f351a-7386-4211-8434-cf60c0691fdb"
/>
<img width="1286" height="756" alt="missions-broken-4x1"
src="https://github.com/user-attachments/assets/4cbfa4d0-999b-4265-bed0-957958663037"
/>
<img width="1290" height="750" alt="missions-broken-4x1-2"
src="https://github.com/user-attachments/assets/4889b498-d6aa-4e6c-87fc-4dfadeac5827"
/>

Reference (PS2 4:3 in OpenGoal):
<img width="1284" height="768" alt="missions-reference-1"
src="https://github.com/user-attachments/assets/91a526c8-08c2-4a62-8219-09e967fab9c2"
/>
<img width="1276" height="755" alt="missions-reference-2"
src="https://github.com/user-attachments/assets/65c4e944-5b1f-479a-bf7c-eca19c81f5d6"
/>


After:
<img width="1281" height="760" alt="missions-fixed-16x9"
src="https://github.com/user-attachments/assets/a972daf0-1872-46f0-a829-cd8d292df1d6"
/>
<img width="1282" height="750" alt="missions-fixed-16x9-2"
src="https://github.com/user-attachments/assets/973611d6-a72c-43f8-b2f3-034e83f6c416"
/>
<img width="1289" height="760" alt="missions-alignment-fixed-4x1"
src="https://github.com/user-attachments/assets/699c5dbc-8c39-468d-9e14-94007a789e48"
/>
<img width="1281" height="755" alt="missions-alignment-fixed-4x1-2"
src="https://github.com/user-attachments/assets/89216187-d453-4d3e-8e8b-5ae365e7227d"
/>


### Jak 2 

### Secrets menu orb icon
Position was wrong in Automatic and some (but strangely, not all) Custom
Aspect ratios. A correction for the aspect ratio was also being applied
in the setter.

Before:
<img width="1284" height="755" alt="image"
src="https://github.com/user-attachments/assets/0a15e238-1d98-4ba7-86ce-b295e8d78d7a"
/>

After:
<img width="1283" height="755" alt="image"
src="https://github.com/user-attachments/assets/bd97de44-ef41-426c-a76f-d4fe99a35285"
/>

### Missions menu
- Indentation was not working, even in 4:3, due to a typo.
- Width was broken in Automatic and Custom

Before:
<img width="1281" height="753" alt="Screenshot from 2026-08-19 01-05-54"
src="https://github.com/user-attachments/assets/6f5e3cc4-3522-45a5-a45b-34a46a7db544"
/>

After:
<img width="1287" height="761" alt="image"
src="https://github.com/user-attachments/assets/cae5498b-6ca4-40ab-a31c-feb8899bc1e7"
/>
2026-08-28 16:42:47 +02:00

4390 lines
159 KiB
Common Lisp

;;-*-Lisp-*-
(in-package goal)
;; name: progress-draw.gc
;; name in dgo: progress-draw
;; dgos: GAME
;; DECOMP BEGINS
(define *progress-list-level* (new 'global 'progress-list-level))
;; WARN: disable def twice: 28. This may happen when a cond (no else) is nested inside of another conditional, but it should be rare.
(defmethod length ((this progress-list-level))
(let ((gp-0 0))
(let* ((v1-0 (-> this act))
(act (cond
((= v1-0 1)
(the-as game-task-node-flag (game-task-node-flag act1))
)
((= v1-0 2)
(the-as game-task-node-flag (game-task-node-flag act2))
)
((= v1-0 3)
(the-as game-task-node-flag (game-task-node-flag act3))
)
(else
(the-as game-task-node-flag (game-task-node-flag act1 act2 act3))
)
)
)
)
(dotimes (s3-0 (-> *game-info* play-list length))
(let* ((v1-3 (-> *game-info* play-list s3-0))
(a0-6 (-> this mode))
(a0-8 (cond
((= a0-6 'select-pre-start)
(or (-> v1-3 play-continue) (-> v1-3 pre-play-continue))
)
((or (= a0-6 'select-kiosk-start) (= a0-6 'select-kiosk-start-special))
(-> v1-3 kiosk-play-continue)
)
(else
(-> v1-3 play-continue)
)
)
)
)
(if (and a0-8 (and (-> v1-3 play-continue)
(let ((a1-5 (-> *game-info* sub-task-list (-> v1-3 play-node) flags)))
(logtest? a1-5 (the-as int act))
)
(lookup-text! *common-text* (-> v1-3 text-name) #t)
)
)
(+! gp-0 1)
)
)
)
)
gp-0
)
)
;; WARN: disable def twice: 29. This may happen when a cond (no else) is nested inside of another conditional, but it should be rare.
(defmethod progress-list-method-9 ((this progress-list-level) (arg0 int))
(let* ((s4-0 0)
(v1-0 (-> this act))
(act (cond
((= v1-0 1)
(the-as game-task-node-flag (game-task-node-flag act1))
)
((= v1-0 2)
(the-as game-task-node-flag (game-task-node-flag act2))
)
((= v1-0 3)
(the-as game-task-node-flag (game-task-node-flag act3))
)
(else
(the-as game-task-node-flag (game-task-node-flag act1 act2 act3))
)
)
)
)
(dotimes (s2-0 (-> *game-info* play-list length))
(let* ((s1-0 (-> *game-info* play-list s2-0))
(v1-3 (-> this mode))
(v1-5 (cond
((= v1-3 'select-pre-start)
(or (-> s1-0 play-continue) (-> s1-0 pre-play-continue))
)
((or (= v1-3 'select-kiosk-start) (= v1-3 'select-kiosk-start-special))
(-> s1-0 kiosk-play-continue)
)
(else
(-> s1-0 play-continue)
)
)
)
)
(when (and v1-5 (and (-> s1-0 play-continue)
(let ((a0-11 (-> *game-info* sub-task-list (-> s1-0 play-node) flags)))
(logtest? a0-11 (the-as int act))
)
(lookup-text! *common-text* (-> s1-0 text-name) #t)
)
)
(if (= s4-0 arg0)
(return s1-0)
)
(+! s4-0 1)
)
)
)
)
(the-as game-task-info #f)
)
;; WARN: Return type mismatch int vs object.
(defmethod progress-method-53 ((this progress) (arg0 font-context))
(let ((v1-1 (get-scissor-stack-top this)))
(let ((a0-1 arg0)
(f0-0 (-> v1-1 x))
(f1-0 (-> v1-1 y))
)
(set! (-> a0-1 origin x) f0-0)
(set! (-> a0-1 origin y) f1-0)
)
(let ((a0-2 arg0))
(set! (-> a0-2 width) (- (-> v1-1 z) (-> v1-1 x)))
)
(set! (-> arg0 height) (- (-> v1-1 w) (-> v1-1 y)))
)
0
)
(defmethod get-language-by-idx ((this progress) (arg0 int))
(if (and (= (scf-get-territory) 1) (zero? (-> this languages arg0)))
11
(the-as int (-> this languages arg0))
)
)
;; WARN: Return type mismatch int vs object.
(defmethod adjust-font-origin-y ((this progress) (arg0 font-context) (arg1 float))
(let ((v1-1 (get-scissor-stack-top this)))
(set! (-> arg0 origin y) (+ (-> v1-1 y) (* (- (-> v1-1 w) (-> v1-1 y)) arg1)))
)
0
)
;; WARN: Return type mismatch int vs object.
(defmethod set-selected-color ((this progress))
(with-pp
(let ((gp-0 33))
;; og:preserve-this high fps fix
(if (< (seconds 0.027) (logand (the int (* DISPLAY_FPS_RATIO (-> pp clock integral-frame-counter))) 15))
(set-font-color
(the-as font-color gp-0)
(new 'static 'rgba :r #xff :g #xff :b #xff :a #x80)
(new 'static 'rgba :r #xff :g #xff :b #xff :a #x80)
(new 'static 'rgba :r #xff :g #xff :b #xff :a #x80)
(new 'static 'rgba :r #xff :g #xff :b #xff :a #x80)
)
(set-font-color
(the-as font-color gp-0)
(new 'static 'rgba :r #x60 :g #x60 :b #x60 :a #x80)
(new 'static 'rgba :r #x60 :g #x60 :b #x60 :a #x80)
(new 'static 'rgba :r #x60 :g #x60 :b #x60 :a #x80)
(new 'static 'rgba :r #x60 :g #x60 :b #x60 :a #x80)
)
)
gp-0
)
)
)
;; WARN: Return type mismatch int vs object.
(defmethod draw-button-text ((this progress) (arg0 font-context) (arg1 string))
(let ((f0-1 (- 1.0 (-> this menu-transition))))
(set-scale! arg0 0.5)
(set! (-> arg0 alpha) f0-1)
)
(print-game-text arg1 arg0 #f 44 (bucket-id hud-draw-hud-alpha))
0
)
(defmethod progress-method-45 ((this progress)
(arg0 font-context)
(arg1 float)
(arg2 float)
(arg3 string)
(arg4 float)
(arg5 float)
(arg6 int)
)
(let ((v1-0 arg0))
(set! (-> v1-0 width) 10000.0)
)
(set-scale! arg0 arg4)
(let ((sv-16 get-string-length))
(format (clear *temp-string*) "~S" arg3)
(let ((f0-2 (-> (sv-16 *temp-string* arg0) length)))
(let ((v1-5 arg0))
(set! (-> v1-5 width) arg1)
)
(cond
((< arg1 f0-2)
(if (< (/ arg1 f0-2) arg5)
(set-scale! arg0 arg4)
(set-scale! arg0 (/ (* arg1 arg4) f0-2))
)
)
(else
(set-scale! arg0 arg4)
)
)
)
)
(let ((s2-1 print-game-text))
(format (clear *temp-string*) "~S" arg3)
(let ((f30-0 (s2-1 *temp-string* arg0 #t arg6 (bucket-id hud-draw-hud-alpha))))
(+! (-> arg0 origin y) (* 0.5 (- arg2 f30-0)))
(let ((f28-0 (-> arg0 origin y)))
(let ((s3-1 print-game-text))
(format (clear *temp-string*) "~S" arg3)
(s3-1 *temp-string* arg0 #f arg6 (bucket-id hud-draw-hud-alpha))
)
(set! (-> arg0 origin y) f28-0)
)
f30-0
)
)
)
;; WARN: Return type mismatch int vs object.
(defmethod draw-highlight-bar ((this progress) (arg0 font-context) (arg1 int) (arg2 int) (arg3 float))
(let* ((v1-1 (get-scissor-stack-top this))
(a1-1 (the int (-> v1-1 x)))
(a3-1 (the int (- (-> v1-1 z) (-> v1-1 x))))
(f0-6 (- 1.0 (-> this menu-transition)))
)
(with-dma-buffer-add-bucket ((s3-0 (-> *display* frames (-> *display* on-screen) global-buf))
(bucket-id particles)
)
(draw-sprite2d-xy
s3-0
a1-1
arg1
a3-1
arg2
(new 'static 'rgba :r #x80 :g #x80 :b #x40 :a (the int (* 64.0 f0-6)))
#x3fffff
)
)
)
0
)
;; WARN: Return type mismatch int vs object.
(defmethod draw-bg-box-outline ((this progress) (arg0 progress-box) (arg1 float))
(with-dma-buffer-add-bucket ((s4-0 (-> *display* frames (-> *display* on-screen) global-buf))
;; og:preserve-this changed from particles bucket
(bucket-id hud-draw-hud-alpha)
)
(case (get-aspect-ratio)
(('aspect4x3)
(set! (-> arg0 aspect4x3 color w) (the int arg1))
(draw-box-prim-only (-> arg0 aspect4x3) s4-0)
)
(('aspect16x9)
(set! (-> arg0 aspect16x9 color w) (the int arg1))
(draw-box-prim-only (-> arg0 aspect16x9) s4-0)
)
)
)
0
)
;; WARN: Return type mismatch int vs object.
(defmethod draw-bg-box-alpha-2 ((this progress) (arg0 progress-box) (arg1 float))
(with-dma-buffer-add-bucket ((s4-0 (-> *display* frames (-> *display* on-screen) global-buf))
(bucket-id particles)
)
(case (get-aspect-ratio)
(('aspect4x3)
(set! (-> arg0 aspect4x3 color w) (the int arg1))
(draw-box-alpha-2 (-> arg0 aspect4x3) s4-0)
)
(('aspect16x9)
(set! (-> arg0 aspect16x9 color w) (the int arg1))
(draw-box-alpha-2 (-> arg0 aspect16x9) s4-0)
)
)
)
0
)
;; WARN: Return type mismatch int vs object.
(defmethod draw-bg-box-alpha-1 ((this progress) (arg0 progress-box) (arg1 float))
(with-dma-buffer-add-bucket ((s4-0 (-> *display* frames (-> *display* on-screen) global-buf))
;; og:preserve-this changed from bucket6
(bucket-id tex-hud-hud-alpha)
)
(case (get-aspect-ratio)
(('aspect4x3)
(set! (-> arg0 aspect4x3 color w) (the int arg1))
(draw-box-alpha-1 (-> arg0 aspect4x3) s4-0)
)
(('aspect16x9)
(set! (-> arg0 aspect16x9 color w) (the int arg1))
(draw-box-alpha-1 (-> arg0 aspect16x9) s4-0)
)
)
)
0
)
;; WARN: Return type mismatch int vs object.
(defmethod draw-header ((this progress) (arg0 font-context) (arg1 float) (arg2 text-id))
(progress-method-33 this (-> *progress-work* header))
(let ((s3-0 (get-scissor-stack-top this)))
(let ((s1-0 *progress-work*))
(draw-bg-box-alpha-2 this (-> s1-0 header) (* 64.0 arg1))
(draw-bg-box-outline this (-> s1-0 header) (* 128.0 arg1))
)
(let ((a0-5 arg0))
(set! (-> a0-5 flags) (font-flags kerning middle large))
)
(let ((a0-6 arg0))
(set! (-> a0-6 color) (font-color font-color-32))
)
(let ((v1-12 arg0)
(f0-5 (+ 10.0 (-> s3-0 x)))
(f1-3 (-> s3-0 y))
)
(set! (-> v1-12 origin x) f0-5)
(set! (-> v1-12 origin y) f1-3)
)
(progress-method-45
this
arg0
(+ (- -20.0 (-> s3-0 x)) (-> s3-0 z))
45.0
(lookup-text! *common-text* arg2 #f)
0.95
0.1
32
)
)
(progress-method-34 this)
0
)
;; WARN: Return type mismatch int vs object.
(defmethod progress-method-47 ((this progress) (arg0 font-context) (arg1 symbol) (arg2 symbol))
(set-scale! arg0 0.5)
(let ((a0-2 arg0))
(set! (-> a0-2 flags) (font-flags kerning large))
)
(set! (-> arg0 origin x) 250.0)
(case (get-aspect-ratio)
(('aspect4x3)
(when arg1
(set! (-> arg0 origin y) 104.0)
(let ((s4-1 print-game-text))
(format (clear *temp-string*) "~33L~C" 160)
(s4-1 *temp-string* arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
(when arg2
(set! (-> arg0 origin y) 305.0)
(let ((s5-1 print-game-text))
(format (clear *temp-string*) "~33L~C" 162)
(s5-1 *temp-string* arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
)
(('aspect16x9)
(when arg1
(set! (-> arg0 origin y) 70.0)
(let ((s4-3 print-game-text))
(format (clear *temp-string*) "~33L~C" 160)
(s4-3 *temp-string* arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
(when arg2
(set! (-> arg0 origin y) 338.0)
(let ((s5-2 print-game-text))
(format (clear *temp-string*) "~33L~C" 162)
(s5-2 *temp-string* arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
)
)
0
)
;; WARN: Return type mismatch int vs object.
(defmethod draw-prev-next-footer ((this progress) (arg0 font-context) (arg1 float))
(let ((s3-0 *progress-work*))
(progress-method-33 this (-> s3-0 footer))
(draw-bg-box-alpha-2 this (-> s3-0 footer) (* 64.0 arg1))
(draw-bg-box-outline this (-> s3-0 footer) (* 128.0 arg1))
)
(let ((a0-4 arg0))
(set! (-> a0-4 color) (font-color font-color-33))
)
(set-scale! arg0 0.6)
(let ((s4-1 (get-scissor-stack-top this)))
(let ((v1-8 arg0)
(f0-6 (+ 10.0 (-> s4-1 x)))
(f1-4 (+ (-> s4-1 y) (* 0.5 (- (- (-> s4-1 w) (-> s4-1 y)) (* 32.0 (-> arg0 scale))))))
)
(set! (-> v1-8 origin x) f0-6)
(set! (-> v1-8 origin y) f1-4)
)
(let ((v1-9 arg0))
(set! (-> v1-9 width) (+ (- -20.0 (-> s4-1 x)) (-> s4-1 z)))
)
(let ((a0-11 arg0))
(set! (-> a0-11 flags) (font-flags kerning large))
)
(let ((s3-1 print-game-text))
(format
(clear *temp-string*)
"~S~S"
(lookup-text! *common-text* (text-id progress-footer-prev-l1) #f)
(lookup-text! *common-text* (text-id progress-prev) #f)
)
(s3-1 *temp-string* arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
(set! (-> arg0 origin x) (+ -10.0 (-> s4-1 z)))
)
(let ((a0-17 arg0))
(set! (-> a0-17 flags) (font-flags kerning right large))
)
(let ((s4-2 print-game-text))
(format
(clear *temp-string*)
"~S~S"
(lookup-text! *common-text* (text-id progress-next) #f)
(lookup-text! *common-text* (text-id progress-footer-next-r1) #f)
)
(s4-2 *temp-string* arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
(progress-method-34 this)
0
)
;; WARN: Return type mismatch int vs object.
(defmethod draw-yes-no-style-footer ((this progress) (arg0 font-context) (arg1 text-id) (arg2 text-id))
(local-vars (a0-5 string))
(cond
((-> this yes-no-choice)
(format
(clear *temp-string*)
"~33L~S~44L ~S"
(lookup-text! *common-text* arg1 #f)
(lookup-text! *common-text* arg2 #f)
)
(set! a0-5 *temp-string*)
)
(else
(format
(clear *temp-string*)
"~44L~S ~33L~S"
(lookup-text! *common-text* arg1 #f)
(lookup-text! *common-text* arg2 #f)
)
(set! a0-5 *temp-string*)
)
)
(print-game-text a0-5 arg0 #f 44 (bucket-id hud-draw-hud-alpha))
0
)
;; ERROR: Stack slot load at 80 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 96 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 160 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 176 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 80 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 96 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 160 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 176 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 160 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 176 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 160 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 176 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 80 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 96 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 160 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 176 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 80 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 96 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 160 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 176 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 160 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 176 mismatch: defined as size 4, got size 16
;; WARN: Return type mismatch int vs object.
(defmethod progress-method-50 ((this progress)
(arg0 font-context)
(arg1 text-id)
(arg2 text-id)
(arg3 text-id)
(arg4 symbol)
(arg5 symbol)
(arg6 float)
)
(let ((sv-32 arg5)
(s1-0 arg6)
(sv-16 (fmax 0.0 (* 2.0 (- 0.5 (-> this menu-transition)))))
(sv-20 (the-as string #f))
(sv-24 (get-scissor-stack-top this))
)
(set! (-> arg0 alpha) sv-16)
(let ((a0-2 arg0))
(set! (-> a0-2 flags) (font-flags kerning middle large))
)
(let ((f30-0 0.0))
(set! sv-20
(cond
(sv-32
(let ((a0-3 arg0))
(set! (-> a0-3 color) (font-color font-color-32))
)
(set! (-> arg0 origin x) (+ 10.0 (-> sv-24 x)))
(let ((f28-0 (progress-method-45
this
arg0
(+ (- -20.0 (-> sv-24 x)) (-> sv-24 z))
(the-as float 24.5)
(lookup-text! *common-text* arg1 #f)
s1-0
0.75
35
)
)
)
(set! f30-0 (/ f28-0 2))
(set-scale! arg0 (/ (-> arg0 scale) 2))
(draw-highlight-bar this arg0 (the int (+ -1.0 (-> arg0 origin y))) (the int (+ 2.0 f28-0)) sv-16)
(+! (-> arg0 origin y) f28-0)
)
(set! sv-20 (cond
((-> this yes-no-choice)
(format
(clear *temp-string*)
"~33L~S ~44L~S"
(lookup-text! *common-text* arg2 #f)
(lookup-text! *common-text* arg3 #f)
)
*temp-string*
)
(else
(format
(clear *temp-string*)
"~44L~S~33L ~S"
(lookup-text! *common-text* arg2 #f)
(lookup-text! *common-text* arg3 #f)
)
*temp-string*
)
)
)
sv-20
)
(else
(cond
(arg4
(let ((a0-16 arg0))
(set! (-> a0-16 color) (font-color font-color-33))
)
)
(else
(let ((a0-17 arg0))
(set! (-> a0-17 color) (font-color font-color-32))
)
)
)
(set! (-> arg0 origin x) (+ 10.0 (-> sv-24 x)))
(let* ((sv-128 this)
(sv-112 (method-of-object sv-128 progress-method-45))
(sv-144 arg0)
(sv-160 (+ (- -20.0 (-> sv-24 x)) (-> sv-24 z)))
(sv-176 (the-as float 24.5))
(t0-3 (the-as object (lookup-text! *common-text* arg1 #f)))
)
(let ((f28-1 (sv-112 sv-128 sv-144 sv-160 sv-176 (the-as string t0-3) s1-0 0.75 35)))
(when arg4
(let* ((a0-20 this)
(t9-14 (method-of-object a0-20 draw-highlight-bar))
(a1-12 arg0)
(a2-12 (the int (+ -1.0 (-> arg0 origin y))))
(a3-6 (the int (+ 1.0 f28-1)))
)
(set! t0-3 sv-16)
(t9-14 a0-20 a1-12 a2-12 a3-6 (the-as float t0-3))
)
)
(+! (-> arg0 origin y) f28-1)
)
(cond
((-> this yes-no-choice)
(format
(clear *temp-string*)
"~1L~S~44L ~S"
(lookup-text! *common-text* arg2 #f)
(lookup-text! *common-text* arg3 #f)
(the-as none t0-3)
)
*temp-string*
)
(else
(format
(clear *temp-string*)
"~44L~S ~1L~S~1L"
(lookup-text! *common-text* arg2 #f)
(lookup-text! *common-text* arg3 #f)
(the-as none t0-3)
)
*temp-string*
)
)
)
)
)
)
(draw-button-text this arg0 sv-20)
(+! (-> arg0 origin y) f30-0)
)
)
0
)
;; WARN: Return type mismatch int vs object.
(defmethod progress-method-51 ((this progress) (arg0 font-context))
(let ((v1-1 (get-scissor-stack-top this)))
(let ((a0-1 arg0)
(f0-0 (-> v1-1 x))
(f1-1 (+ (-> v1-1 y) (* 0.5 (- (-> v1-1 w) (-> v1-1 y)))))
)
(set! (-> a0-1 origin x) f0-0)
(set! (-> a0-1 origin y) f1-1)
)
(let ((a0-2 arg0))
(set! (-> a0-2 width) (- (-> v1-1 z) (-> v1-1 x)))
)
)
(set-scale! arg0 0.6)
(let ((a0-4 arg0))
(set! (-> a0-4 flags) (font-flags kerning middle large))
)
(if (< (mod (current-time) 300) 210)
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-loading) #f)
arg0
#f
44
(bucket-id hud-draw-hud-alpha)
)
)
0
)
;; WARN: Return type mismatch int vs object.
(defmethod draw-slider-option ((this progress)
(arg0 font-context)
(arg1 string)
(arg2 float)
(arg3 float)
(arg4 float)
(arg5 float)
(arg6 float)
)
(let ((sv-80 arg3)
(s1-0 arg4)
(s5-0 arg5)
)
(let* ((sv-96 arg6)
(sv-112 (get-scissor-stack-top this))
(s0-0 (new 'stack 'hud-sprite))
(f30-0 (* (- (-> sv-112 z) (-> sv-112 x)) s1-0))
)
(let ((s1-1 (- (- 256 (if sv-96
10
0
)
)
(the int (/ f30-0 2))
)
)
(sv-128 (the int (+ (-> sv-112 y) (* (- (-> sv-112 w) (-> sv-112 y)) sv-80))))
)
1.0
(let* ((f28-0 f30-0)
(f24-0 (-> *video-params* relative-x-scale-reciprical))
(f26-0 (-> *video-params* relative-x-scale))
(sv-160 (-> *display* frames (-> *display* on-screen) global-buf))
(sv-176 (-> sv-160 base))
)
(set! (-> s0-0 tid) (the-as texture-id (get-texture hud-sliderbackground progress-minimap)))
(if (-> s0-0 tid)
(set! (-> s0-0 scale-x) (/ (* f30-0 f24-0) (the float (-> (the-as texture (-> s0-0 tid)) w))))
)
(set! (-> s0-0 scale-y) 0.7)
(let ((v1-28 (-> s0-0 color-ptr)))
(set! (-> v1-28 0) 128)
(set! (-> v1-28 1) 128)
(set! (-> v1-28 2) 128)
(set! (-> v1-28 3) (the int (* 128.0 arg2)))
)
(set-vector! (-> s0-0 pos) s1-1 sv-128 #x3fffff 0)
(draw s0-0 sv-160 (-> *level* level-default) #t)
(let ((f24-1 0.2))
(set! (-> s0-0 tid) (the-as texture-id (get-texture hud-sliderframe progress-minimap)))
(set! (-> s0-0 scale-x) f24-1)
(set! (-> s0-0 scale-y) 1.33)
(if (-> s0-0 tid)
(set! f28-0 (- f30-0 (* f24-1 f26-0 (the float (-> (the-as texture (-> s0-0 tid)) w)))))
)
)
(let* ((v1-39 (the int (* f28-0 s5-0)))
(a1-3 (+ s1-1 (the int (* 18.0 f26-0)) v1-39))
(a3-2 (the int (- f28-0 (the float v1-39))))
(t1-1 (shr (shl (the int (* 128.0 arg2)) 56) 32))
)
(draw-sprite2d-xy sv-160 a1-3 (+ sv-128 7) a3-2 9 (the-as rgba t1-1) #x3fffff)
)
(set-vector! (-> s0-0 pos) (+ s1-1 (the int (* f28-0 s5-0))) (+ sv-128 -4) #x3fffff 0)
(draw s0-0 sv-160 (-> *level* level-default) #t)
(when sv-96
(let ((sv-144 (-> *font-work* color-table 32 color 0)))
(set! (-> s0-0 tid) (the-as texture-id (get-texture hud-speaker-empty progress-minimap)))
(set! (-> s0-0 scale-x) 1.0)
(set! (-> s0-0 scale-y) 1.0)
(let ((v1-55 (-> s0-0 color-ptr)))
(set! (-> v1-55 0) (the-as int (-> sv-144 r)))
(set! (-> v1-55 1) (the-as int (-> sv-144 g)))
(set! (-> v1-55 2) (the-as int (-> sv-144 b)))
(set! (-> v1-55 3) (the int (* 128.0 arg2)))
)
)
(set-vector! (-> s0-0 pos) (+ s1-1 -20) (+ sv-128 -5) #x3fffff 0)
(draw s0-0 sv-160 (-> *level* level-default) #t)
(set! (-> s0-0 tid) (the-as texture-id (get-texture hud-speaker-full progress-minimap)))
(set! (-> s0-0 scale-x) 1.0)
(set! (-> s0-0 scale-y) 1.0)
(set-vector! (-> s0-0 pos) (+ (the int f30-0) 8 s1-1) (+ sv-128 -5) #x3fffff 0)
(draw s0-0 sv-160 (-> *level* level-default) #t)
)
(let ((a3-6 (-> sv-160 base)))
(when (!= sv-176 a3-6)
(let ((v1-68 (the-as object (-> sv-160 base))))
(set! (-> (the-as dma-packet v1-68) dma) (new 'static 'dma-tag :id (dma-tag-id next)))
(set! (-> (the-as dma-packet v1-68) vif0) (new 'static 'vif-tag))
(set! (-> (the-as dma-packet v1-68) vif1) (new 'static 'vif-tag))
(set! (-> sv-160 base) (&+ (the-as pointer v1-68) 16))
)
(dma-bucket-insert-tag
(-> *display* frames (-> *display* on-screen) bucket-group)
(bucket-id hud-draw-hud-alpha)
sv-176
(the-as (pointer dma-tag) a3-6)
)
)
)
)
(let ((f0-43 0.5))
(set-scale! arg0 f0-43)
(let ((a0-56 arg0))
(set! (-> a0-56 flags) (font-flags kerning large))
)
(let ((v1-79 arg0)
(f1-14 (the float s1-1))
(f2-3 (+ -20.0 (the float sv-128)))
)
(set! (-> v1-79 origin x) f1-14)
(set! (-> v1-79 origin y) f2-3)
)
(let ((f0-44 (progress-method-45 this arg0 f30-0 (* 32.0 f0-43) arg1 f0-43 0.75 32)))
(if (= (-> this option-index) (-> this current-index))
(draw-highlight-bar this arg0 (the int (+ -2.0 (-> arg0 origin y))) (the int (+ 4.0 f0-44)) arg2)
)
)
)
)
(+! (-> arg0 origin x) f30-0)
)
(let ((a0-62 arg0))
(set! (-> a0-62 flags) (font-flags kerning right large))
)
(let ((s4-1 print-game-text))
(format (clear *temp-string*) "~D%" (the int (* 100.0 s5-0)))
(s4-1 *temp-string* arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
(set! (-> arg0 flags) (font-flags kerning large))
0
)
(defmethod draw-icon-array! ((this progress-icon-array) (arg0 int) (arg1 int) (arg2 float) (arg3 float) (arg4 rgba) (arg5 float))
(let ((sv-96 arg0)
(sv-112 arg1)
(s5-0 arg2)
(s4-0 arg3)
(s1-0 arg4)
(s0-0 arg5)
(s3-0 (new 'stack 'hud-sprite))
(s2-0 (new 'stack 'vector4w))
)
(set-vector! s2-0 sv-96 sv-112 0 1)
(let ((v1-3 (-> s3-0 color-ptr)))
(set! (-> v1-3 0) (the-as int (-> s1-0 r)))
(set! (-> v1-3 1) (the-as int (-> s1-0 g)))
(set! (-> v1-3 2) (the-as int (-> s1-0 b)))
(set! (-> v1-3 3) (the int (* s0-0 (the float (-> s1-0 a)))))
)
(set! (-> s3-0 pos z) #xffffff)
(set! (-> s3-0 pos w) 1)
(set! (-> s3-0 scale-x) s5-0)
(set! (-> s3-0 scale-y) s4-0)
(dotimes (s1-1 (-> this length))
(let ((s0-1 (-> this icons s1-1)))
(set! (-> s3-0 tid) (the-as texture-id (lookup-texture-by-id (-> s0-1 tex-id))))
(set! (-> s3-0 flags) (the-as hud-sprite-flags (-> s0-1 flags)))
(set-as-offset-from!
(the-as hud-sprite (-> s3-0 pos))
s2-0
(the int (* (the float (-> s0-1 offset x)) s5-0))
(the int (* (the float (-> s0-1 offset y)) s4-0))
)
(let* ((sv-128 (-> *display* frames (-> *display* on-screen) global-buf))
(sv-144 (-> sv-128 base))
)
(draw s3-0 sv-128 (-> *level* level-default) #t)
(let ((a3-3 (-> sv-128 base)))
(when (!= sv-144 a3-3)
(let ((v1-24 (the-as object (-> sv-128 base))))
(set! (-> (the-as dma-packet v1-24) dma) (new 'static 'dma-tag :id (dma-tag-id next)))
(set! (-> (the-as dma-packet v1-24) vif0) (new 'static 'vif-tag))
(set! (-> (the-as dma-packet v1-24) vif1) (new 'static 'vif-tag))
(set! (-> sv-128 base) (&+ (the-as pointer v1-24) 16))
)
(dma-bucket-insert-tag
(-> *display* frames (-> *display* on-screen) bucket-group)
(-> s0-1 bucket)
sv-144
(the-as (pointer dma-tag) a3-3)
)
)
)
)
)
)
)
0
(none)
)
(defmethod draw-option ((this menu-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
0
(none)
)
(defmethod draw-option ((this menu-bigmap-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
0
(none)
)
;; WARN: Return type mismatch symbol vs none.
(defun sort-task-node-result ((arg0 int))
(let ((v1-1 (-> *game-info* mission-list))
(a1-1 (max 0 (+ arg0 -1)))
)
(let ((a0-3 0))
(while (> a1-1 0)
(while (< a0-3 a1-1)
(when (and (logtest? (-> v1-1 a0-3 flags) (game-task-node-flag closed))
(logtest? (-> v1-1 (+ a0-3 1) flags) (game-task-node-flag closed))
(< (-> v1-1 a0-3 close-time) (-> v1-1 (+ a0-3 1) close-time))
)
(let ((a2-19 (-> v1-1 a0-3)))
(set! (-> v1-1 a0-3) (-> v1-1 (+ a0-3 1)))
(set! (-> v1-1 (+ a0-3 1)) a2-19)
)
)
(+! a0-3 1)
)
(+! a1-1 -1)
(set! a0-3 0)
)
)
)
(none)
)
(defun find-mission-text-at-index ((arg0 progress) (arg1 int))
(local-vars (v1-74 symbol))
(when (< arg1 (-> arg0 current-line-index))
(set! (-> arg0 current-task-index) (length (-> *game-info* sub-task-list)))
(set! (-> arg0 current-line-index) -1)
(set! (-> arg0 current-task) (game-task unknown))
(set! (-> arg0 first-closed-line-index) -1)
(set! (-> arg0 extra-text-state) -1)
(set! (-> arg0 num-open-tasks-found) 0)
(set! (-> arg0 num-closed-tasks-found) 0)
0
)
(let ((s4-0 (-> *game-info* sub-task-list)))
0
(let ((s3-0 (the-as game-task-node-info #f)))
(while (and (> (-> arg0 current-task-index) 0) (!= (-> arg0 current-line-index) arg1))
(cond
((or (= (-> arg0 extra-text-state) -1) (= (-> arg0 extra-text-state) 3))
(+! (-> arg0 current-task-index) -1)
(let ((s2-0 (-> s4-0 (-> arg0 current-task-index))))
(when (and (!= (-> s2-0 task) (-> arg0 current-task)) (nonzero? (-> s2-0 description)))
(cond
((and (>= (-> arg0 first-closed-line-index) 0) (game-task-node-info-method-12 s2-0))
(set! (-> arg0 current-task) (-> s2-0 task))
)
((or (and (>= (-> arg0 first-closed-line-index) 0) (logtest? (-> s2-0 flags) (game-task-node-flag closed)))
(and (< (-> arg0 first-closed-line-index) 0) (game-task-node-info-method-12 s2-0))
)
(set! (-> arg0 current-task) (-> s2-0 task))
(set! s3-0 (-> s4-0 (-> arg0 current-task-index)))
(-> s4-0 (-> arg0 current-task-index) description)
(if (< (-> arg0 first-closed-line-index) 0)
(+! (-> arg0 num-open-tasks-found) 1)
(set! (-> arg0 num-closed-tasks-found) 1)
)
(+! (-> arg0 current-line-index) 1)
)
)
)
)
(when (and (zero? (-> arg0 current-task-index)) (!= (-> arg0 current-line-index) arg1))
(set! (-> arg0 current-task-index) (length (-> *game-info* sub-task-list)))
(cond
((< (-> arg0 first-closed-line-index) 0)
(set! (-> arg0 first-closed-line-index) arg1)
(+! (-> arg0 extra-text-state) (if (nonzero? (-> arg0 num-open-tasks-found))
2
1
)
)
)
(else
(+! (-> arg0 extra-text-state) (if (nonzero? (-> arg0 num-closed-tasks-found))
2
1
)
)
)
)
)
)
((zero? (-> arg0 extra-text-state))
114
(+! (-> arg0 extra-text-state) 1)
(+! (-> arg0 current-line-index) 1)
)
((= (-> arg0 extra-text-state) 1)
968
#t
(let ((v1-73 (the-as symbol (-> arg0 num-open-tasks-found))))
(set! v1-73 v1-73)
(cmove-#f-zero v1-74 v1-73 v1-73)
)
(+! (-> arg0 extra-text-state) 1)
(+! (-> arg0 current-line-index) 1)
)
((= (-> arg0 extra-text-state) 4)
114
(+! (-> arg0 extra-text-state) 1)
(+! (-> arg0 current-line-index) 1)
)
((= (-> arg0 extra-text-state) 5)
969
(+! (-> arg0 extra-text-state) 2)
(+! (-> arg0 current-line-index) 1)
)
(else
0
(+! (-> arg0 extra-text-state) 1)
(+! (-> arg0 current-line-index) 1)
)
)
)
(cond
((= (-> arg0 current-line-index) arg1)
(empty)
s3-0
)
(else
(the-as game-task-node-info #f)
)
)
)
)
)
(defmethod draw-option ((this menu-missions-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(local-vars (sv-288 text-id))
(let ((sv-176 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(let ((sv-180 (new 'stack 'game-task-node-info))
(sv-184 (new 'stack 'game-task-node-info))
)
(set! (-> arg0 current-task-index) (length (-> *game-info* sub-task-list)))
(set! (-> arg0 current-line-index) -1)
(set! (-> arg0 current-task) (game-task unknown))
(set! (-> arg0 first-closed-line-index) -1)
(set! (-> arg0 extra-text-state) -1)
(set! (-> arg0 num-open-tasks-found) 0)
(set! (-> arg0 num-closed-tasks-found) 0)
(set! (-> arg1 alpha) sv-176)
(set! (-> *game-info* mission-list 0) sv-180)
(set! (-> sv-180 description) (text-id progress-missions-todo))
(set! (-> sv-184 description) (text-id progress-missions-completed))
(progress-method-33 arg0 (-> *progress-work* body-footer))
(let* ((s3-0 (get-scissor-stack-top arg0))
(sv-188 (- (-> s3-0 w) (-> s3-0 y)))
)
(let ((sv-192 1))
(let ((sv-200 #t)
(sv-208 (length (-> *game-info* sub-task-list)))
(sv-216 (-> *game-info* mission-list))
)
(dotimes (s2-0 sv-208)
(let ((v0-6 (find-mission-text-at-index arg0 s2-0)))
(when v0-6
(when (and (logtest? (-> v0-6 flags) (game-task-node-flag closed)) sv-200)
(set! sv-200 (the-as symbol #f))
(set! (-> sv-216 sv-192) sv-184)
(+! sv-192 1)
)
(set! (-> sv-216 sv-192) v0-6)
(+! sv-192 1)
)
)
)
)
(set! (-> arg0 total-num-tasks) sv-192)
)
(sort-task-node-result (-> arg0 total-num-tasks))
(let ((a0-17 arg1))
(set! (-> a0-17 flags) (font-flags kerning large))
)
(set-scale! arg1 0.5)
(let ((f30-0 14.0)
(s2-1 get-string-length)
)
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (text-id progress-missions-complete-icon) #f))
(let ((f30-1 (+ f30-0 (-> (s2-1 *temp-string* arg1) length))))
(let ((v1-45 arg1))
(set! (-> v1-45 width) (+ (- (- -10.0 f30-1) (-> s3-0 x)) (-> s3-0 z)))
)
(let* ((s2-2 (-> *game-info* mission-list))
(s1-2 (max 0 (the int (-> this current-index))))
(s0-1 (-> s2-2 s1-2))
(a1-10
(if (and (logtest? (-> s0-1 flags) (game-task-node-flag closed)) (task-complete? *game-info* (-> s0-1 task)))
(-> *game-info* play-list (-> s0-1 task) text-name)
(-> s0-1 description)
)
)
(sv-256 (lookup-text! *common-text* a1-10 #f))
(s0-2 print-game-text)
)
(format (clear *temp-string*) "~S" sv-256)
(let ((f28-0 (s0-2 *temp-string* arg1 #t 44 (bucket-id hud-draw-hud-alpha))))
(let* ((v1-60 arg1)
(f0-14 (+ 10.0 (-> s3-0 x)))
(f1-6 4.0)
(f2-2 (-> this current-index))
(f1-8 (+ (- f1-6 (* f28-0 (- f2-2 (* (the float (the int (/ f2-2 1.0))) 1.0)))) (-> s3-0 y)))
)
(set! (-> v1-60 origin x) f0-14)
(set! (-> v1-60 origin y) f1-8)
)
(set! (-> arg1 height) sv-188)
(while (and (< (-> arg1 origin y) (-> s3-0 w)) (< s1-2 (-> arg0 total-num-tasks)))
(let ((sv-272 (-> s2-2 s1-2)))
(set! sv-288
(cond
((and (logtest? (-> sv-272 flags) (game-task-node-flag closed)) (task-complete? *game-info* (-> sv-272 task)))
(set! sv-288 (-> *game-info* play-list (-> sv-272 task) text-name))
sv-288
)
(else
(-> sv-272 description)
)
)
)
(let ((s0-3 (lookup-text! *common-text* sv-288 #f)))
(set! (-> arg1 origin x) (+ 10.0 (-> s3-0 x)))
(cond
((or (= sv-288 (text-id progress-missions-todo)) (= sv-288 (text-id progress-missions-completed)))
(let ((a0-41 arg1))
(set! (-> a0-41 color) (font-color font-color-34))
)
)
(else
(let ((sv-304 print-game-text))
(let ((sv-320 format)
(sv-336 (clear *temp-string*))
(sv-352 "~S")
)
(sv-320 sv-336 sv-352 (lookup-text!
*common-text*
(if (logtest? (-> sv-272 flags) (game-task-node-flag closed))
(text-id progress-missions-complete-icon)
(text-id progress-missions-todo-icon)
)
#f
)
)
)
(sv-304 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(let ((a0-46 arg1))
(set! (-> a0-46 color) (font-color font-color-32))
)
(set! (-> arg1 origin x) (+ (-> s3-0 x) f30-1))
)
)
(let ((f26-0 (-> arg1 origin y))
(sv-368 print-game-text)
)
(format (clear *temp-string*) "~S" s0-3)
(set! (-> arg1 origin y) (+ f26-0 (sv-368 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))))
)
)
)
(+! s1-2 1)
)
(set! (-> this on-screen) (< (-> arg1 origin y) (-> s3-0 w)))
(seek!
(-> this current-index)
(-> this target-index)
(* (/ (-> this scroll-speed) f28-0) (seconds-per-frame))
)
)
)
)
)
)
)
(progress-method-34 arg0)
(let ((s3-1 *progress-work*))
(draw-header arg0 arg1 sv-176 (text-id progress-missions))
(draw-bg-box-alpha-2 arg0 (-> s3-1 footer) (* 64.0 sv-176))
(draw-bg-box-outline arg0 (-> s3-1 footer) (* 128.0 sv-176))
)
)
(progress-method-47
arg0
arg1
(!= (-> this current-index) 0.0)
(and (not (-> this on-screen)) (!= (-> this current-index) (the float (+ (-> arg0 total-num-tasks) -1))))
)
0
(none)
)
(defmethod highscore-time->string ((this highscore-page-info) (arg0 float))
0
0
0
(let* ((gp-0 (the int (/ arg0 60)))
(v1-5 (- arg0 (* 60.0 (the float gp-0))))
(s5-0 (the int v1-5))
(v1-6 (- v1-5 (the float s5-0)))
(s3-0 (the int (* 100.0 v1-6)))
)
(format (clear *temp-string*) "~d:~2,'0,d:~2,'0,d" gp-0 s5-0 s3-0)
)
*temp-string*
)
(defmethod highscore-page-info-method-10 ((this highscore-page-info) (arg0 font-context) (arg1 float) (arg2 float) (arg3 float))
(let ((v1-3 (-> *highscore-info-array* (-> this game-score))))
(let ((a1-2 arg0)
(f0-0 arg2)
(f1-0 arg3)
)
(set! (-> a1-2 origin x) f0-0)
(set! (-> a1-2 origin y) f1-0)
)
(cond
((logtest? (-> v1-3 flags) (highscore-flags hf2))
(print-game-text (highscore-time->string this (/ arg1 300)) arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
((logtest? (-> v1-3 flags) (highscore-flags hf3))
(let ((s4-1 print-game-text))
(format (clear *temp-string*) "~,,1Mm" arg1)
(s4-1 *temp-string* arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
(else
(let ((s4-2 print-game-text))
(format (clear *temp-string*) "~D" (the int arg1))
(s4-2 *temp-string* arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
)
)
0
(none)
)
(defmethod highscore-page-info-method-11 ((this highscore-page-info) (arg0 font-context) (arg1 int) (arg2 float) (arg3 float) (arg4 float))
(set! (-> arg0 origin x) arg3)
(let ((a0-1 arg0))
(set! (-> a0-1 flags) (font-flags kerning large))
)
(let ((s1-0 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (the-as text-id arg1) #f))
(s1-0 *temp-string* arg0 #f 44 (bucket-id hud-draw-hud-alpha))
)
(let ((a0-6 arg0))
(set! (-> a0-6 flags) (font-flags kerning right large))
)
(highscore-page-info-method-10 this arg0 arg2 arg4 (-> arg0 origin y))
0
(none)
)
(defmethod highscore-page-info-method-9 ((this highscore-page-info) (arg0 progress) (arg1 font-context) (arg2 float) (arg3 float))
(let ((s3-0 (get-scissor-stack-top arg0)))
(let ((f28-0 (-> *video-params* relative-x-scale))
(sv-16 (-> *highscore-info-array* (-> this game-score)))
(f30-0 (- (-> s3-0 z) (-> s3-0 x)))
(s0-0 *progress-work*)
)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning large))
)
(set-scale! arg1 0.675)
(let ((a0-5 arg1))
(set! (-> a0-5 color) (font-color font-color-32))
)
(set! (-> arg1 origin x) (+ 10.0 arg2 (-> s3-0 x)))
(adjust-font-origin-y arg0 arg1 0.01)
(let ((v1-11 arg1))
(set! (-> v1-11 width) (* 0.75 f30-0))
)
(let ((sv-32 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> this text) #f))
(sv-32 *temp-string* arg1 #f 32 (bucket-id hud-draw-hud-alpha))
)
(draw-icon-array!
(-> *progress-icon-arrays* (-> this icon))
(the int (+ (- (-> s3-0 z) (* (-> this icon-offsetx) f28-0)) arg2))
(the int (+ (-> s3-0 y) (-> this icon-offsety)))
(-> this icon-scalex)
(-> this icon-scaley)
(new 'static 'rgba :r #x80 :g #x80 :b #x80 :a (the int (* 128.0 arg3)))
arg3
)
(when (not (logtest? (-> sv-16 flags) (highscore-flags hf1)))
(let ((f28-1 (* 20.0 f28-0))
(f26-0 (+ 50.0 (-> s3-0 y)))
(sv-96 (the int (+ 48.0 (-> s3-0 y))))
(sv-112 (logior #x808080 (shr (shl (the int (* 128.0 arg3)) 56) 32)))
(f24-0 0.25)
(f22-0 (+ 10.0 arg2 (-> s3-0 x)))
)
(set-scale! arg1 0.45)
(let ((f20-0 f22-0))
(draw-icon-array! (-> *progress-icon-arrays* 63) (the int f20-0) sv-96 f24-0 f24-0 (the-as rgba sv-112) arg3)
(highscore-page-info-method-10 this arg1 (-> sv-16 gold-score) (+ f20-0 f28-1) f26-0)
)
(let ((f20-1 (+ f22-0 (* 0.333 f30-0))))
(draw-icon-array! (-> *progress-icon-arrays* 64) (the int f20-1) sv-96 f24-0 f24-0 (the-as rgba sv-112) arg3)
(highscore-page-info-method-10 this arg1 (-> sv-16 silver-score) (+ f20-1 f28-1) f26-0)
)
(let ((f30-1 (+ f22-0 (* 0.667 f30-0))))
(draw-icon-array! (-> *progress-icon-arrays* 65) (the int f30-1) sv-96 f24-0 f24-0 (the-as rgba sv-112) arg3)
(highscore-page-info-method-10 this arg1 (-> sv-16 bronze-score) (+ f30-1 f28-1) f26-0)
)
)
)
(draw-bg-box-alpha-2 arg0 (-> s0-0 highscore-1) (* 16.0 arg3))
(draw-bg-box-outline arg0 (-> s0-0 highscore-1) (* 128.0 arg3))
(draw-bg-box-outline arg0 (-> s0-0 highscore-0) (* 128.0 arg3))
(progress-method-33 arg0 (-> s0-0 highscore-body))
)
(let ((f30-2 (+ 10.0 arg2 (-> s3-0 x)))
(f28-2 (+ -10.0 arg2 (-> s3-0 z)))
(s3-1 (get-game-score-ref *game-info* (the-as int (-> this game-score))))
)
(set-scale! arg1 0.6)
(adjust-font-origin-y arg0 arg1 0.03)
(highscore-page-info-method-11 this arg1 56 (-> s3-1 0) f30-2 f28-2)
(set-scale! arg1 0.5)
(adjust-font-origin-y arg0 arg1 0.18)
(highscore-page-info-method-11 this arg1 57 (-> s3-1 1) f30-2 f28-2)
(set-scale! arg1 0.45)
(adjust-font-origin-y arg0 arg1 0.31)
(highscore-page-info-method-11 this arg1 58 (-> s3-1 2) f30-2 f28-2)
(set-scale! arg1 0.425)
(adjust-font-origin-y arg0 arg1 0.43)
(highscore-page-info-method-11 this arg1 59 (-> s3-1 3) f30-2 f28-2)
(adjust-font-origin-y arg0 arg1 0.545)
(highscore-page-info-method-11 this arg1 60 (-> s3-1 4) f30-2 f28-2)
(adjust-font-origin-y arg0 arg1 0.66)
(highscore-page-info-method-11 this arg1 61 (-> s3-1 5) f30-2 f28-2)
(adjust-font-origin-y arg0 arg1 0.775)
(highscore-page-info-method-11 this arg1 62 (-> s3-1 6) f30-2 f28-2)
(adjust-font-origin-y arg0 arg1 0.89)
(highscore-page-info-method-11 this arg1 63 (-> s3-1 7) f30-2 f28-2)
)
)
(progress-method-34 arg0)
0
(none)
)
(defmethod draw-option ((this menu-highscores-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition)))))
(s4-0 *progress-work*)
)
(set! (-> arg1 alpha) f30-0)
(let ((a0-1 arg1))
(set! (-> a0-1 flags) (font-flags kerning middle large))
)
(progress-method-33 arg0 (-> s4-0 body-footer))
(progress-method-53 arg0 arg1)
(let ((f28-0 (the float (menu-highscores-option-method-12 this))))
(let* ((f0-2 (-> this current-index))
(f26-0 (- f0-2 (* (the float (the int (/ f0-2 f28-0))) f28-0)))
(f0-4 (+ 1.0 f26-0))
(f0-5 (- f0-4 (* (the float (the int (/ f0-4 f28-0))) f28-0)))
(s2-0 (-> this pages (the int f26-0)))
(s3-1 (-> this pages (the int f0-5)))
(s1-0 (get-scissor-stack-top arg0))
(f0-8 (- (-> s1-0 z) (-> s1-0 x)))
)
(when (!= f28-0 0.0)
(let ((f26-1 (* (- 1.0 (- f26-0 (* (the float (the int (/ f26-0 1.0))) 1.0))) f0-8)))
(set! (-> arg1 origin x) (+ (- f26-1 f0-8) (-> s1-0 x)))
((method-of-type highscore-page-info highscore-page-info-method-9)
(the-as highscore-page-info s2-0)
arg0
arg1
(- f26-1 f0-8)
f30-0
)
(when (< 1.0 f28-0)
(set! (-> arg1 origin x) (+ f26-1 (-> s1-0 x)))
((method-of-type highscore-page-info highscore-page-info-method-9)
(the-as highscore-page-info s3-1)
arg0
arg1
f26-1
f30-0
)
)
)
)
)
(progress-method-34 arg0)
(draw-header arg0 arg1 f30-0 (text-id progress-highscores))
(cond
((< 1.0 f28-0)
(draw-prev-next-footer arg0 arg1 f30-0)
)
(else
(draw-bg-box-alpha-2 arg0 (-> s4-0 footer) (* 64.0 f30-0))
(draw-bg-box-outline arg0 (-> s4-0 footer) (* 128.0 f30-0))
)
)
)
)
0
(none)
)
(defmethod inventory-item-method-10 ((this inventory-item) (arg0 progress) (arg1 font-context) (arg2 float) (arg3 float) (arg4 symbol))
(let ((s5-0 #x20000000))
(when (item-obtained? this)
(if arg4
(set! s5-0 (the-as int (the-as uint #x80ffffff)))
(set! s5-0 (the-as int (the-as uint #x80808080)))
)
)
(let ((s3-1 (new 'stack 'vector2))
(v1-9 (get-scissor-stack-top arg0))
(f0-0 (-> this icon-scale))
)
(set! (-> s3-1 x) (+ (-> v1-9 x) (* (- (-> v1-9 z) (-> v1-9 x)) (-> this offset x)) arg2))
(set! (-> s3-1 y) (+ (-> v1-9 y) (* (- (-> v1-9 w) (-> v1-9 y)) (-> this offset y))))
(draw-icon-array!
(-> *progress-icon-arrays* (-> this icon))
(the int (-> s3-1 x))
(the int (-> s3-1 y))
f0-0
f0-0
(the-as rgba s5-0)
arg3
)
)
)
0
(none)
)
(defmethod inventory-item-group-method-10 ((this inventory-item-group) (arg0 progress) (arg1 font-context) (arg2 float) (arg3 float) (arg4 int))
(dotimes (s0-0 (-> this items length))
(when (and arg4 (have-items? this))
(set-scale! arg1 0.45)
(adjust-font-origin-y arg0 arg1 0.9)
(let ((sv-16 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> this name) #f))
(sv-16 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
(inventory-item-method-10 (-> this items s0-0) arg0 arg1 arg2 arg3 (the-as symbol arg4))
)
0
(none)
)
(defmethod inventory-screen-method-9 ((this inventory-screen) (arg0 progress) (arg1 font-context) (arg2 float) (arg3 float))
(set-scale! arg1 0.45)
(let ((a0-2 arg1))
(set! (-> a0-2 color) (font-color font-color-32))
)
(adjust-font-origin-y arg0 arg1 0.01)
(let ((s1-0 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> this name) #f))
(s1-0 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(dotimes (s1-1 (-> this groups length))
(inventory-item-group-method-10
(-> this groups s1-1)
arg0
arg1
arg2
arg3
(the-as int (= s1-1 (-> this current-index)))
)
)
0
(none)
)
(defmethod draw-option ((this menu-inventory) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(set! (-> arg1 alpha) f30-0)
(let ((a0-1 arg1))
(set! (-> a0-1 flags) (font-flags kerning middle large))
)
(progress-method-33 arg0 (-> *progress-work* body-footer))
(progress-method-53 arg0 arg1)
(let* ((f0-2 (the float (-> this screens length)))
(f28-0 (-> this current-index))
(f1-3 (+ 1.0 f28-0))
(f0-4 (- f1-3 (* (the float (the int (/ f1-3 f0-2))) f0-2)))
(s3-0 (-> this screens (the int f28-0)))
(s4-1 (-> this screens (the int f0-4)))
(s2-0 (get-scissor-stack-top arg0))
(f0-7 (- (-> s2-0 z) (-> s2-0 x)))
(f28-1 (* (- 1.0 (- f28-0 (* (the float (the int (/ f28-0 1.0))) 1.0))) f0-7))
)
(set! (-> arg1 origin x) (+ (- f28-1 f0-7) (-> s2-0 x)))
(inventory-screen-method-9 s3-0 arg0 arg1 (- f28-1 f0-7) f30-0)
(set! (-> arg1 origin x) (+ f28-1 (-> s2-0 x)))
(inventory-screen-method-9 s4-1 arg0 arg1 f28-1 f30-0)
)
(progress-method-34 arg0)
(draw-header arg0 arg1 f30-0 (text-id progress-inventory))
(draw-prev-next-footer arg0 arg1 f30-0)
)
0
(none)
)
(defmethod controls-string-info-method-9 ((this controls-string-info)
(arg0 progress)
(arg1 font-context)
(arg2 float)
(arg3 float)
(arg4 float)
(arg5 float)
(arg6 float)
)
(let ((sv-48 arg4)
(s0-0 arg5)
(s3-0 arg6)
(s2-0 (get-scissor-stack-top arg0))
)
0.0
0.0
(set! (-> arg1 origin x) (+ 10.0 arg2))
(let ((v1-2 arg1))
(set! (-> v1-2 width) (+ -20.0 sv-48))
)
(let ((sv-64 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> this action) #f))
(let ((f30-0 (sv-64 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha))))
(set! (-> arg1 origin x) (+ 10.0 arg3))
(let ((v1-8 arg1))
(set! (-> v1-8 width) (+ -20.0 s0-0))
)
(let ((s0-1 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> this button) #f))
(let* ((f0-11 (s0-1 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha)))
(f30-1 (+ 8.0 (fmax f30-0 f0-11)))
)
(let ((s1-1 (new 'stack 'hud-box))
(f28-0 (+ arg3 (* 0.5 (- (-> s2-0 z) (-> s2-0 x)))))
)
(set! (-> s1-1 box min y) (+ -6.0 (-> arg1 origin y)))
(set! (-> s1-1 box max y) (+ (-> s1-1 box min y) f30-1))
(set-vector! (-> s1-1 color) 192 192 96 (the int (* 128.0 s3-0)))
(with-dma-buffer-add-bucket ((s2-1 (-> *display* frames (-> *display* on-screen) global-buf))
;; og:preserve-this changed from particles bucket
(bucket-id hud-draw-hud-alpha)
)
(set! (-> s1-1 box min x) arg2)
(set! (-> s1-1 box max x) arg3)
(draw-box-prim-only s1-1 s2-1)
(set! (-> s1-1 box min x) arg3)
(set! (-> s1-1 box max x) f28-0)
(draw-box-prim-only s1-1 s2-1)
)
)
(+! (-> arg1 origin y) f30-1)
)
)
)
)
)
0
(none)
)
;; ERROR: Stack slot load at 64 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 64 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 64 mismatch: defined as size 4, got size 16
(defmethod controls-page-info-method-11 ((this controls-page-info) (arg0 progress) (arg1 font-context) (arg2 float) (arg3 float))
(local-vars (v1-28 int) (v1-29 int))
(let ((sv-16 arg2)
(s2-0 arg3)
(s3-0 *progress-work*)
)
(let ((s1-0 (get-scissor-stack-top arg0)))
(- (-> s1-0 z) (-> s1-0 x))
(progress-method-33 arg0 (-> s3-0 sub-header))
(draw-bg-box-outline arg0 (-> s3-0 sub-header) (* 128.0 s2-0))
(let ((a0-4 arg1))
(set! (-> a0-4 flags) (font-flags kerning middle large))
)
(let ((v1-5 arg1)
(f0-7 (+ 10.0 sv-16 (-> s1-0 x)))
(f1-4 (-> s1-0 y))
)
(set! (-> v1-5 origin x) f0-7)
(set! (-> v1-5 origin y) f1-4)
)
(let ((a0-7 arg1))
(set! (-> a0-7 color) (font-color font-color-34))
)
(progress-method-45
arg0
arg1
(+ (- -20.0 (-> s1-0 x)) (-> s1-0 z))
(the-as float 28.0)
(lookup-text! *common-text* (-> this title) #f)
0.7
0.5
32
)
)
(progress-method-34 arg0)
(progress-method-33 arg0 (-> s3-0 sub-body-footer))
(progress-method-53 arg0 arg1)
(let ((a0-13 arg1))
(set! (-> a0-13 flags) (font-flags kerning large))
)
(set-scale! arg1 0.425)
(let ((a0-15 arg1))
(set! (-> a0-15 color) (font-color font-color-32))
)
(let* ((s0-1 (get-scissor-stack-top arg0))
(f28-0 (- (-> s0-1 z) (-> s0-1 x)))
(s1-2 (init-text! this))
)
(let* ((f30-0 (/ f28-0 2))
(f28-1 (/ f28-0 2))
(f26-0 (+ sv-16 (-> s0-1 x)))
(f24-0 (+ sv-16 (-> s0-1 x) f30-0))
)
(let ((v1-25 arg1))
(set! (-> v1-25 width) (+ -20.0 f30-0))
)
(let ((sv-80 0))
(let ((v1-27 sv-80)
(a0-20 (min (the int (-> this current-index)) s1-2))
)
(set-on-less-than v1-28 v1-27 a0-20)
(move-if-not-zero v1-29 a0-20 v1-28 v1-28)
)
(set! sv-80 v1-29)
(let ((sv-96 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (the-as text-id (-> this text sv-80 text)) #f))
(let ((f22-0 (sv-96 *temp-string* arg1 #t 40 (bucket-id hud-draw-hud-alpha)))
(sv-160 print-game-text)
)
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> this text sv-80 id) #f))
(let* ((f0-23 (sv-160 *temp-string* arg1 #t 40 (bucket-id hud-draw-hud-alpha)))
(f22-1 (+ 8.0 (fmax f22-0 f0-23)))
)
(let* ((v1-47 arg1)
(f0-26 (+ 10.0 (-> s0-1 x)))
(f1-12 4.0)
(f2-0 (-> this current-index))
(f1-14 (+ (- f1-12 (* f22-1 (- f2-0 (* (the float (the int (/ f2-0 1.0))) 1.0)))) (-> s0-1 y)))
)
(set! (-> v1-47 origin x) f0-26)
(set! (-> v1-47 origin y) f1-14)
)
(while (and (< (-> arg1 origin y) (-> s0-1 w)) (< sv-80 s1-2))
(when (= sv-80 3)
(nop!)
(nop!)
0
)
((method-of-type controls-string-info controls-string-info-method-9)
(the-as controls-string-info (-> this text sv-80))
arg0
arg1
f26-0
f24-0
f30-0
f28-1
s2-0
)
(+! sv-80 1)
)
(set! (-> this on-screen) (< (-> arg1 origin y) (-> s0-1 w)))
(seek! (-> this current-index) (-> this target-index) (* (/ 300.0 f22-1) (seconds-per-frame)))
)
)
)
)
)
(progress-method-34 arg0)
(progress-method-33 arg0 (-> s3-0 small-screen))
(progress-method-47
arg0
arg1
(!= (-> this current-index) 0.0)
(and (not (-> this on-screen)) (!= (-> this current-index) (the float s1-2)))
)
)
)
(progress-method-34 arg0)
0
(none)
)
(defmethod draw-option ((this menu-controls-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition)))))
(s2-0 *progress-work*)
)
(set! (-> arg1 alpha) f30-0)
(draw-header arg0 arg1 f30-0 (text-id progress-controls))
(let ((a0-2 arg1))
(set! (-> a0-2 flags) (font-flags kerning middle large))
)
(progress-method-53 arg0 arg1)
(let* ((f28-0 (the float (menu-controls-option-method-12 this)))
(f0-2 (-> this current-index))
(f26-0 (- f0-2 (* (the float (the int (/ f0-2 f28-0))) f28-0)))
(f0-4 (+ 1.0 f26-0))
(f0-5 (- f0-4 (* (the float (the int (/ f0-4 f28-0))) f28-0)))
(s0-0 (-> this pages (the int f26-0)))
(s3-0 (-> this pages (the int f0-5)))
(s1-0 (get-scissor-stack-top arg0))
(f24-0 (- (-> s1-0 z) (-> s1-0 x)))
)
(cond
((< 1.0 f28-0)
(draw-prev-next-footer arg0 arg1 f30-0)
)
(else
(draw-bg-box-alpha-2 arg0 (-> s2-0 footer) (* 64.0 f30-0))
(draw-bg-box-outline arg0 (-> s2-0 footer) (* 128.0 f30-0))
)
)
(progress-method-33 arg0 (-> s2-0 body-footer))
(when (!= f28-0 0.0)
(let ((f26-1 (* (- 1.0 (- f26-0 (* (the float (the int (/ f26-0 1.0))) 1.0))) f24-0)))
(set! (-> arg1 origin x) (+ (- f26-1 f24-0) (-> s1-0 x)))
(controls-page-info-method-11 s0-0 arg0 arg1 (- f26-1 f24-0) f30-0)
(when (and (< 1.0 f28-0) (!= (-> this current-index) (-> this target-index)))
(set! (-> arg1 origin x) (+ f26-1 (-> s1-0 x)))
(controls-page-info-method-11 s3-0 arg0 arg1 f26-1 f30-0)
)
)
)
)
)
(progress-method-34 arg0)
0
(none)
)
(defmethod draw-option ((this menu-language-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(set! (-> arg1 alpha) f30-0)
(set-scale! arg1 1.0)
(let ((a1-2 arg1))
(set! (-> a1-2 flags) (font-flags kerning middle large))
)
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(draw-highlight-bar arg0 arg1 (the int (-> arg1 origin y)) 44 f30-0)
(+! (-> arg1 origin y) 8.0)
(let ((a0-3 arg1))
(set! (-> a0-3 color) (font-color font-color-32))
)
(set-scale! arg1 1.0)
(+! (-> arg1 origin x) -170.0)
(let ((s4-0 print-game-text))
(format (clear *temp-string*) "~33L~C" 163)
(s4-0 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin x) 340.0)
(let ((s4-1 print-game-text))
(format (clear *temp-string*) "~33L~C" 161)
(s4-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin x) -170.0)
(let ((a0-11 arg1))
(set! (-> a0-11 color) (font-color font-color-33))
)
(print-game-text
(lookup-text! *common-text* (-> *language-name-remap* (get-language-by-idx arg0 1)) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(draw-header arg0 arg1 f30-0 (text-id progress-language))
)
0
(none)
)
(defmethod draw-option ((this menu-sub-menu-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(set! (-> arg1 alpha) f30-0)
(set-scale! arg1 0.85)
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(cond
((= (-> arg0 option-index) arg2)
(draw-highlight-bar arg0 arg1 (the int (+ -6.0 (-> arg1 origin y))) 35 f30-0)
(let ((a0-4 arg1))
(set! (-> a0-4 color) (font-color font-color-33))
)
)
(else
(let ((a0-5 arg1))
(set! (-> a0-5 color) (font-color font-color-32))
)
)
)
)
(print-game-text (lookup-text! *common-text* (-> this name) #f) arg1 #f 44 (bucket-id hud-draw-hud-alpha))
0
(none)
)
(defmethod draw-option ((this menu-on-off-game-vibrations-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg0 yes-no-choice) (-> arg0 vibrations))
(adjust-font-origin-y arg0 arg1 0.19)
(progress-method-50
arg0
arg1
(-> this name)
(text-id progress-on)
(text-id progress-off)
(= (-> arg0 option-index) arg2)
arg3
0.65
)
(let ((f0-1 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(draw-header arg0 arg1 f0-1 (text-id progress-game-options))
)
0
(none)
)
(defmethod draw-option ((this menu-on-off-game-subtitles-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg0 yes-no-choice) (-> arg0 subtitles))
(adjust-font-origin-y arg0 arg1 0.34)
(progress-method-50
arg0
arg1
(-> this name)
(text-id progress-on)
(text-id progress-off)
(= (-> arg0 option-index) arg2)
arg3
0.65
)
0
(none)
)
(defmethod draw-option ((this menu-language-game-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(set-scale! arg1 0.65)
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(set! (-> arg1 alpha) f30-0)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle large))
)
(let ((s4-0 0))
(let ((s5-0 *language-name-remap*))
(case (-> this menu-option-type)
((5)
(set! s4-0 (get-language-by-idx arg0 0))
)
((6)
(set! s4-0 (get-language-by-idx arg0 1))
)
((7)
(set! s4-0 (get-language-by-idx arg0 2))
)
)
(cond
(arg3
(let ((a0-12 arg1))
(set! (-> a0-12 color) (font-color font-color-34))
)
(draw-highlight-bar arg0 arg1 (the int (-> arg1 origin y)) 42 f30-0)
(let ((s2-1 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> this name) #f))
(s2-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 24.0)
(let ((a0-18 arg1))
(set! (-> a0-18 color) (font-color font-color-32))
)
(set-scale! arg1 0.5)
(let ((a0-20 arg1))
(set! (-> a0-20 color) (font-color font-color-32))
)
(+! (-> arg1 origin x) -70.0)
(let ((s3-1 print-game-text))
(format (clear *temp-string*) "~33L~C" 163)
(s3-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin x) 70.0)
(+! (-> arg1 origin x) 70.0)
(let ((s3-2 print-game-text))
(format (clear *temp-string*) "~33L~C" 161)
(s3-2 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin x) -70.0)
(let ((a0-27 arg1))
(set! (-> a0-27 color) (font-color font-color-33))
)
(print-game-text (lookup-text! *common-text* (-> s5-0 s4-0) #f) arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(else
(cond
((= (-> arg0 option-index) arg2)
(let ((a0-30 arg1))
(set! (-> a0-30 color) (font-color font-color-33))
)
(draw-highlight-bar arg0 arg1 (the int (-> arg1 origin y)) 24 f30-0)
)
(else
(let ((a0-32 arg1))
(set! (-> a0-32 color) (font-color font-color-32))
)
)
)
(set-scale! arg1 0.65)
(let ((s2-4 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> this name) #f))
(s2-4 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(set-scale! arg1 0.5)
(let ((a0-39 arg1))
(set! (-> a0-39 color) (font-color font-color-32))
)
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> s5-0 s4-0) #f))
*temp-string*
(+! (-> arg1 origin y) 24.0)
(let ((a0-43 arg1))
(set! (-> a0-43 flags) (font-flags kerning middle large))
)
(print-game-text (lookup-text! *common-text* (-> s5-0 s4-0) #f) arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
)
)
)
0
(none)
)
;; ERROR: Stack slot load at 16 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 48 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 16 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 48 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 48 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 16 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 48 mismatch: defined as size 4, got size 16
;; ERROR: Stack slot load at 48 mismatch: defined as size 4, got size 16
(defmethod draw-option ((this menu-center-screen-graphic-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition)))))
(s4-0 (get-scissor-stack-top arg0))
)
(set! (-> arg1 alpha) f30-0)
(let ((a0-2 arg1))
(set! (-> a0-2 flags) (font-flags kerning middle large))
)
(cond
(arg3
(let ((a0-3 arg1))
(set! (-> a0-3 color) (font-color font-color-34))
)
(adjust-font-origin-y arg0 arg1 0.45)
(set! (-> arg1 origin x) (+ 30.0 (-> s4-0 x)))
(let* ((f0-7
(progress-method-45
arg0
arg1
(+ (- -60.0 (-> s4-0 x)) (-> s4-0 z))
(the-as float 16.0)
(lookup-text! *common-text* (text-id progress-graphics-center-screen-dpad) #f)
0.5
0.95
32
)
)
(f1-6 (* 0.4 (-> arg1 max-x)))
(f2-4 (+ (-> s4-0 x) (* 0.5 (- (-> s4-0 z) (-> s4-0 x)))))
(f30-1 (+ f2-4 f1-6))
(f28-0 (- f2-4 f1-6))
(f26-0 (+ -8.0 (/ f0-7 2) (-> arg1 origin y)))
)
(let ((f1-10 (+ -15.0 (-> arg1 origin y)))
(f24-0 (+ 3.0 f0-7 (-> arg1 origin y)))
)
(let ((v1-17 arg1))
(set! (-> v1-17 origin x) (-> s4-0 x))
(set! (-> v1-17 origin y) f1-10)
)
(let ((v1-18 arg1))
(set! (-> v1-18 width) (- (-> s4-0 z) (-> s4-0 x)))
)
(let ((s3-2 print-game-text))
(format (clear *temp-string*) "~33L~C" 160)
(s3-2 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(set! (-> arg1 origin y) f24-0)
)
(let ((s3-3 print-game-text))
(format (clear *temp-string*) "~33L~C" 162)
(s3-3 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(let ((a0-13 arg1))
(set! (-> a0-13 flags) (font-flags kerning right large))
)
(let ((v1-20 arg1)
(f0-12 f26-0)
)
(set! (-> v1-20 origin x) f28-0)
(set! (-> v1-20 origin y) f0-12)
)
(let ((s3-4 print-game-text))
(format (clear *temp-string*) "~33L~C" 163)
(s3-4 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(let ((a0-17 arg1))
(set! (-> a0-17 flags) (font-flags kerning large))
)
(let ((v1-22 arg1))
(set! (-> v1-22 origin x) f30-1)
(set! (-> v1-22 origin y) f26-0)
)
)
(let ((s3-5 print-game-text))
(format (clear *temp-string*) "~33L~C" 161)
(s3-5 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(let ((a0-21 arg1))
(set! (-> a0-21 flags) (font-flags kerning middle large))
)
(set! (-> arg1 origin x) (-> s4-0 x))
(adjust-font-origin-y arg0 arg1 0.85)
(set-scale! arg1 0.5)
(let ((v1-27 arg1))
(set! (-> v1-27 width) (- (-> s4-0 z) (-> s4-0 x)))
)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-center-screen-reset) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
)
(else
(let ((f28-1 0.7))
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(cond
((= (-> arg0 option-index) arg2)
(let ((a0-27 arg1))
(set! (-> a0-27 color) (font-color font-color-33))
)
)
(else
(let ((a0-28 arg1))
(set! (-> a0-28 color) (font-color font-color-32))
)
)
)
(set! (-> arg1 origin x) (+ 10.0 (-> s4-0 x)))
(let ((f0-26 (progress-method-45
arg0
arg1
(+ (- -20.0 (-> s4-0 x)) (-> s4-0 z))
(* 32.0 f28-1)
(lookup-text! *common-text* (-> this name) #f)
f28-1
0.75
32
)
)
)
(if (= (-> arg0 option-index) arg2)
(draw-highlight-bar arg0 arg1 (the int (+ -1.0 (-> arg1 origin y))) (the int (+ 4.0 f0-26)) f30-0)
)
)
)
)
)
)
0
(none)
)
(defmethod draw-option ((this menu-aspect-ratio-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(when (not (and (zero? (-> arg0 option-index)) (-> arg0 selected-option)))
(set! (-> arg0 yes-no-choice) (= (if arg3
(-> arg0 aspect-ratio)
(get-aspect-ratio)
)
'aspect4x3
)
)
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(progress-method-50
arg0
arg1
(-> this name)
(text-id progress-aspect-4x3)
(text-id progress-aspect-16x9)
(= (-> arg0 option-index) arg2)
arg3
0.7
)
)
(let ((f0-2 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(draw-header arg0 arg1 f0-2 (text-id progress-graphic-options))
)
0
(none)
)
(defmethod draw-option ((this menu-on-off-progressive-scan-graphic-option)
(arg0 progress)
(arg1 font-context)
(arg2 int)
(arg3 symbol)
)
(when (not (and (zero? (-> arg0 option-index)) (-> arg0 selected-option)))
(set! (-> arg0 yes-no-choice) (if arg3
(-> arg0 progressive-scan)
(-> *setting-control* user-default set-video-mode)
)
)
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(progress-method-50
arg0
arg1
(-> this name)
(text-id progress-on)
(text-id progress-off)
(= (-> arg0 option-index) arg2)
arg3
0.7
)
)
0
(none)
)
(defmethod draw-option ((this menu-video-mode-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(when (not (and (zero? (-> arg0 option-index)) (-> arg0 selected-option)))
(set! (-> arg0 yes-no-choice) (= (if arg3
(-> arg0 video-mode)
(get-video-mode)
)
'pal
)
)
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(progress-method-50
arg0
arg1
(-> this name)
(text-id progress-refresh-50hz)
(text-id progress-refresh-60hz)
(= (-> arg0 option-index) arg2)
arg3
0.7
)
)
0
(none)
)
(defmethod draw-option ((this menu-sound-slider-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(set! (-> arg1 alpha) f30-0)
(cond
((not (loaded? *bigmap*))
(progress-method-51 arg0 arg1)
)
(else
(let ((f28-0 (-> (the-as (pointer float) (&+ (the-as pointer *setting-control*) (-> this setting-offset))))))
(draw-slider-option
arg0
arg1
(lookup-text! *common-text* (-> this name) #f)
f30-0
(-> this offset-y)
0.75
f28-0
(the-as float #t)
)
)
)
)
(if (zero? arg2)
(draw-header arg0 arg1 f30-0 (text-id progress-sound-options))
)
)
0
(none)
)
(defmethod draw-option ((this menu-stereo-mode-sound-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(local-vars (s5-0 int))
(let ((f28-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(set-scale! arg1 0.65)
(set! (-> arg1 alpha) f28-0)
(let ((a0-2 arg1))
(set! (-> a0-2 flags) (font-flags kerning middle large))
)
(cond
((not (loaded? *bigmap*))
(progress-method-51 arg0 arg1)
)
((begin
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(set! s5-0 (-> *setting-control* user-default stereo-mode))
arg3
)
(let ((f30-2
(fmax
(fmax
(-> (get-string-length (lookup-text! *common-text* (text-id progress-sound-mono) #f) arg1) length)
(-> (get-string-length (lookup-text! *common-text* (text-id progress-sound-stereo) #f) arg1) length)
)
(-> (get-string-length (lookup-text! *common-text* (text-id progress-sound-surround) #f) arg1) length)
)
)
)
(let ((a0-12 arg1))
(set! (-> a0-12 color) (font-color font-color-34))
)
(draw-highlight-bar arg0 arg1 (the int (+ -1.0 (-> arg1 origin y))) 42 f28-0)
(let ((s3-1 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> this name) #f))
(s3-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 22.0)
(set-scale! arg1 0.5)
(let ((a0-19 arg1))
(set! (-> a0-19 color) (font-color font-color-33))
)
(let ((a0-20 arg1))
(set! (-> a0-20 flags) (font-flags kerning middle large))
)
(print-game-text
(lookup-text! *common-text* (-> *stereo-mode-name-remap* s5-0) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(let ((a0-23 arg1))
(set! (-> a0-23 color) (font-color font-color-32))
)
(set! (-> arg1 origin x) (- (-> arg1 origin x) (the float (the int (/ f30-2 2)))))
(let ((s5-1 print-game-text))
(format (clear *temp-string*) "~33L~C" 163)
(s5-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin x) (the float (the int f30-2)))
)
(let ((s5-2 print-game-text))
(format (clear *temp-string*) "~33L~C" 161)
(s5-2 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
(else
(if (= (-> arg0 option-index) arg2)
(draw-highlight-bar arg0 arg1 (the int (-> arg1 origin y)) 21 f28-0)
)
(let ((s3-2 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> this name) #f))
(s3-2 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 22.0)
(set-scale! arg1 0.5)
(let ((a0-36 arg1))
(set! (-> a0-36 color) (font-color font-color-32))
)
(let ((a0-37 arg1))
(set! (-> a0-37 flags) (font-flags kerning middle large))
)
(print-game-text
(lookup-text! *common-text* (-> *stereo-mode-name-remap* s5-0) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
)
)
)
0
(none)
)
(defmethod draw-option ((this menu-picture-slider-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(set! (-> arg1 alpha) f30-0)
(progress-method-33 arg0 (-> *progress-work* body))
(cond
((not (loaded? *bigmap*))
(progress-method-51 arg0 arg1)
)
(else
(let ((f28-0 (-> (the-as (pointer float) (&+ (the-as pointer *setting-control*) (-> this setting-offset))))))
(draw-slider-option
arg0
arg1
(lookup-text! *common-text* (-> this name) #f)
f30-0
(-> this offset-y)
0.9
f28-0
(the-as float #f)
)
)
)
)
(when (zero? arg2)
(let ((s4-1 (get-scissor-stack-top arg0)))
(draw-header arg0 arg1 f30-0 (text-id progress-picture-options))
(draw-icon-array!
(-> *progress-icon-arrays* 75)
256
(the int (+ (-> s4-1 y) (* 0.75 (- (-> s4-1 w) (-> s4-1 y)))))
(-> *video-params* relative-x-scale-reciprical)
10.0
(new 'static 'rgba :r #x80 :g #x80 :b #x80 :a #x80)
f30-0
)
)
)
)
(progress-method-34 arg0)
0
(none)
)
(defmethod draw-option ((this menu-camera-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(let* ((v1-2 (-> this menu-option-type))
(v1-3 (cond
((= v1-2 12)
(-> arg0 flip-horizontal)
)
((= v1-2 13)
(-> arg0 flip-vertical)
)
)
)
)
(set! (-> arg0 yes-no-choice) (not v1-3))
)
(progress-method-50
arg0
arg1
(-> this name)
(text-id progress-camera-default)
(text-id progress-camera-flipped)
(= (-> arg0 option-index) arg2)
arg3
0.7
)
(when (zero? arg2)
(let ((f0-2 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(draw-header arg0 arg1 f0-2 (text-id progress-camera-options))
)
)
0
(none)
)
(defmethod draw-option ((this menu-unlocked-sub-menu-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((s2-0 (memcard-unlocked-secrets? arg0 #t))
(f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition)))))
(s1-0 "?????????")
)
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(set-scale! arg1 0.5)
(if (= arg2 (-> arg0 option-index))
33
32
)
(let ((f0-3
(if (logtest? s2-0 (-> this mask))
(print-game-text (lookup-text! *common-text* (-> this name) #f) arg1 #f 44 (bucket-id hud-draw-hud-alpha))
(print-game-text s1-0 arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
)
(if (= arg2 (-> arg0 option-index))
(draw-highlight-bar arg0 arg1 (the int (+ 2.0 (-> arg1 origin y))) (the int (+ -1.0 f0-3)) f30-0)
)
)
)
0
(none)
)
(defmethod draw-option ((this menu-main-menu-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(-> arg1 flags)
(when (and (nonzero? (-> this name)) (= arg2 (-> arg0 option-index)))
(set-scale! arg1 0.75)
(let ((a0-2 arg1))
(set! (-> a0-2 color) (font-color font-color-32))
)
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags shadow kerning middle large))
)
(set! (-> arg1 width) (the float (if (= (get-aspect-ratio) 'aspect4x3)
235
175
)
)
)
(set! (-> arg1 height) (the float (if (= (get-aspect-ratio) 'aspect4x3)
80
80
)
)
)
(set! (-> arg1 origin x) (the float (if (= (get-aspect-ratio) 'aspect4x3)
140
170
)
)
)
(set! (-> arg1 origin y) (the float (if (= (get-aspect-ratio) 'aspect4x3)
180
175
)
)
)
(cond
((= (-> this name) (text-id progress-bigmap))
(if (= (-> *setting-control* user-default language) (language-enum french))
(set-scale! arg1 0.7)
)
(print-game-text (lookup-text! *common-text* (-> this name) #f) arg1 #f 44 (bucket-id hud-draw-hud-alpha))
(set! (-> arg1 origin y) (the float (if (= (get-aspect-ratio) 'aspect4x3)
210
200
)
)
)
(set! (-> arg1 scale) 0.6)
)
(else
(print-game-text (lookup-text! *common-text* (-> this name) #f) arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
)
0
(none)
)
(defmethod draw-option ((this menu-memcard-slot-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition)))))
(f28-0 (if (= (-> arg0 current) 'select-save-title)
0.2
0.25
)
)
(s3-0 *progress-work*)
(f24-0 (-> *video-params* relative-x-scale))
)
(cond
((not (loaded? *bigmap*))
(progress-method-51 arg0 arg1)
)
(else
(set! (-> arg1 alpha) f30-0)
(set-scale! arg1 0.6)
(progress-method-33 arg0 (-> s3-0 body))
(let* ((s3-1 (get-scissor-stack-top arg0))
(s0-0 (new 'stack 'hud-box))
(f0-4 (* (- (-> s3-1 w) (-> s3-1 y)) f28-0))
(f26-0 (+ (-> s3-1 y) (* f0-4 (the float arg2))))
(f28-1 (+ f26-0 f0-4))
(s1-0 (the int (+ (-> s3-1 x) (* 0.7 (- (-> s3-1 z) (-> s3-1 x))) (* -48.0 f24-0))))
(sv-160 (the int (+ 32.0 (-> s3-1 y))))
(s2-0 *progress-save-info*)
)
(let ((v1-16 arg1)
(f1-12 (+ 10.0 (-> s3-1 x)))
(f2-13 (+ f26-0 (* 0.5 (- f0-4 (* 32.0 (-> arg1 scale))))))
)
(set! (-> v1-16 origin x) f1-12)
(set! (-> v1-16 origin y) f2-13)
)
(set! (-> arg1 height) f0-4)
(let ((a0-11 arg1))
(set! (-> a0-11 flags) (font-flags kerning large))
)
(when (and s2-0 (= (-> s2-0 formatted) 1) (= (-> s2-0 inited) 1))
(cond
((= (-> s2-0 file arg2 present) 1)
(let ((sv-48 print-game-text))
(string-format
"~S ~D"
(lookup-text! *common-text* (text-id progress-saved-game) #f)
(+ arg2 1)
)
(sv-48 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
((zero? (-> s2-0 file arg2 present))
(print-game-text
(lookup-text! *common-text* (text-id progress-empty) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
)
)
(when (= arg2 (-> arg0 option-index))
(set-scale! arg1 0.8)
(let* ((sv-128 (-> *display* frames (-> *display* on-screen) global-buf))
(sv-144 (-> sv-128 base))
)
(let ((f24-1 (+ (-> s3-1 x) (* 0.4 (- (-> s3-1 z) (-> s3-1 x))))))
(set-vector! (-> s0-0 color) 128 128 128 (the int (* 16.0 f30-0)))
(set! (-> (the-as vector (-> s0-0 box)) quad) (-> s3-1 quad))
(set! (-> s0-0 box min x) f24-1)
(draw-box-alpha-1 s0-0 sv-128)
(set! (-> s0-0 box min x) (-> s3-1 x))
(set! (-> s0-0 box max x) f24-1)
)
(set! (-> s0-0 box min y) f26-0)
(set! (-> s0-0 box max y) f28-1)
(draw-box-alpha-1 s0-0 sv-128)
(set-vector! (-> s0-0 color) 128 128 64 (the int (* 128.0 f30-0)))
(when (!= f26-0 (-> s3-1 y))
(set! (-> s0-0 box min y) (-> s3-1 y))
(set! (-> s0-0 box max y) f26-0)
(draw-box-prim-only s0-0 sv-128)
)
(when (!= f28-1 (-> s3-1 w))
(set! (-> s0-0 box min y) f28-1)
(set! (-> s0-0 box max y) (-> s3-1 w))
(draw-box-prim-only s0-0 sv-128)
)
(let ((a3-4 (-> sv-128 base)))
(when (!= sv-144 a3-4)
(let ((v1-63 (the-as object (-> sv-128 base))))
(set! (-> (the-as dma-packet v1-63) dma) (new 'static 'dma-tag :id (dma-tag-id next)))
(set! (-> (the-as dma-packet v1-63) vif0) (new 'static 'vif-tag))
(set! (-> (the-as dma-packet v1-63) vif1) (new 'static 'vif-tag))
(set! (-> sv-128 base) (&+ (the-as pointer v1-63) 16))
)
(dma-bucket-insert-tag
(-> *display* frames (-> *display* on-screen) bucket-group)
(bucket-id tex-hud-hud-alpha)
sv-144
(the-as (pointer dma-tag) a3-4)
)
)
)
)
)
(when (= (-> s2-0 file arg2 present) 1)
(when (= arg2 (-> arg0 option-index))
(draw-icon-array!
(-> *progress-icon-arrays* (-> s2-0 file arg2 level-index))
s1-0
sv-160
1.0
1.0
(new 'static 'rgba :r #x80 :g #x80 :b #x80 :a #x80)
f30-0
)
(set-scale! arg1 0.6)
(let ((a0-51 arg1))
(set! (-> a0-51 color) (font-color font-color-32))
)
(adjust-font-origin-y arg0 arg1 0.675)
(let ((a0-53 arg1))
(set! (-> a0-53 flags) (font-flags kerning right large))
)
(let* ((v1-91 (-> s2-0 file arg2 game-time0))
(v1-92 (logior (shl (-> s2-0 file arg2 game-time1) 32) v1-91))
(s1-1 (/ (the-as int v1-92) #x107ac0))
(s0-1 (/ (mod (the-as int v1-92) #x107ac0) #x4650))
)
(set! (-> arg1 origin x) (+ (-> s3-1 x) (* 0.675 (- (-> s3-1 z) (-> s3-1 x)))))
(let ((sv-176 print-game-text))
(format (clear *temp-string*) "~2,'0D:~2,'0D" s1-1 s0-1)
(sv-176 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
(draw-icon-array!
(-> *progress-icon-arrays* 66)
(the int (+ 10.0 (* 0.4 (- (-> s3-1 z) (-> s3-1 x))) (-> s3-1 x)))
(the int (-> arg1 origin y))
0.65
0.65
(new 'static 'rgba :r #x80 :g #x80 :b #x80 :a #x80)
f30-0
)
(set! (-> arg1 origin x) (+ (- (+ -10.0 (-> s3-1 z)) (-> s3-1 x)) (-> s3-1 x)))
(let ((s1-2 print-game-text))
(format (clear *temp-string*) "~D%" (the int (-> s2-0 file arg2 completion-percentage)))
(s1-2 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(draw-icon-array!
(-> *progress-icon-arrays* 67)
(the int (+ -8.0 (* 0.75 (- (-> s3-1 z) (-> s3-1 x))) (-> s3-1 x)))
(the int (-> arg1 origin y))
0.7
0.7
(new 'static 'rgba :r #x80 :g #x80 :b #x80 :a #x80)
f30-0
)
(adjust-font-origin-y arg0 arg1 0.83)
(set! (-> arg1 origin x) (+ (-> s3-1 x) (* 0.675 (- (-> s3-1 z) (-> s3-1 x)))))
(let ((s1-3 print-game-text))
(format (clear *temp-string*) "~D" (the int (-> s2-0 file arg2 skill-count)))
(s1-3 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(draw-icon-array!
(-> *progress-icon-arrays* 68)
(the int (+ 10.0 (* 0.4 (- (-> s3-1 z) (-> s3-1 x))) (-> s3-1 x)))
(the int (+ -2.0 (-> arg1 origin y)))
0.7
0.7
(new 'static 'rgba :r #x80 :g #x80 :b #x80 :a #x80)
f30-0
)
(set! (-> arg1 origin x) (+ (- (+ -10.0 (-> s3-1 z)) (-> s3-1 x)) (-> s3-1 x)))
(let ((s1-4 print-game-text))
(format (clear *temp-string*) "~D" (the int (-> s2-0 file arg2 gem-count)))
(s1-4 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(draw-icon-array!
(-> *progress-icon-arrays* 69)
(the int (+ -14.0 (* 0.75 (- (-> s3-1 z) (-> s3-1 x))) (-> s3-1 x)))
(the int (-> arg1 origin y))
0.5
0.5
(new 'static 'rgba :r #x80 :g #x80 :b #x80 :a #x80)
f30-0
)
(when (logtest? (-> s2-0 file arg2 secrets) 1)
(let ((a0-79 arg1))
(set! (-> a0-79 flags) (font-flags kerning middle large))
)
(set! (-> arg1 origin x) (+ (-> s3-1 x) (* 0.4 (- (-> s3-1 z) (-> s3-1 x)))))
(set! (-> arg1 origin y) (+ 8.0 (-> s3-1 y)))
(let ((v1-140 arg1))
(set! (-> v1-140 width) (* 0.6 (- (-> s3-1 z) (-> s3-1 x))))
)
(let ((s3-2 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (text-id progress-secrets-hero-mode) #f))
(s3-2 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
)
)
)
)
(progress-method-34 arg0)
(when (zero? arg2)
(case (-> arg0 current)
(('select-load)
(draw-header arg0 arg1 f30-0 (text-id progress-load-file-select))
)
(('select-save-hero)
(draw-header arg0 arg1 f30-0 (text-id save-hero-mode-file))
)
(else
(draw-header arg0 arg1 f30-0 (text-id progress-save-file-select))
)
)
)
)
)
)
0
(none)
)
(defmethod draw-option ((this menu-save-sub-menu-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition)))))
(f28-0 0.2)
)
(let ((v1-3 *progress-work*))
(progress-method-33 arg0 (-> v1-3 body))
)
(let ((s2-0 (get-scissor-stack-top arg0))
(s3-0 (new 'stack 'hud-box))
)
(let ((v1-7 arg1))
(set! (-> v1-7 width) (+ -10.0 (* 0.4 (- (-> s2-0 z) (-> s2-0 x)))))
)
(let ((a0-6 arg1))
(set! (-> a0-6 flags) (font-flags kerning large))
)
(set-scale! arg1 0.425)
(let* ((f24-0 (* (- (-> s2-0 w) (-> s2-0 y)) f28-0))
(f28-1 (+ (-> s2-0 y) (* f24-0 (the float arg2))))
(f26-0 (+ f28-1 f24-0))
)
(let* ((f0-7
(print-game-text (lookup-text! *common-text* (-> this name) #f) arg1 #t 44 (bucket-id hud-draw-hud-alpha))
)
(v1-11 arg1)
(f1-9 (+ 10.0 (-> s2-0 x)))
(f0-10 (+ f28-1 (* 0.5 (- f24-0 f0-7))))
)
(set! (-> v1-11 origin x) f1-9)
(set! (-> v1-11 origin y) f0-10)
)
(set! (-> arg1 height) f24-0)
(when (= arg2 (-> arg0 option-index))
(set-scale! arg1 0.45)
(with-dma-buffer-add-bucket ((s0-1 (-> *display* frames (-> *display* on-screen) global-buf))
(bucket-id tex-hud-hud-alpha)
)
(let ((f0-13 (+ (-> s2-0 x) (* 0.4 (- (-> s2-0 z) (-> s2-0 x))))))
(set-vector! (-> s3-0 color) 128 128 128 (the int (* 16.0 f30-0)))
(set! (-> s3-0 box min x) (-> s2-0 x))
(set! (-> s3-0 box max x) f0-13)
)
(set! (-> s3-0 box min y) f28-1)
(set! (-> s3-0 box max y) f26-0)
(draw-box-alpha-1 s3-0 s0-1)
(set-vector! (-> s3-0 color) 128 128 64 (the int (* 128.0 f30-0)))
(draw-box-prim-only s3-0 s0-1)
)
)
)
)
)
(print-game-text (lookup-text! *common-text* (-> this name) #f) arg1 #f 44 (bucket-id hud-draw-hud-alpha))
(progress-method-34 arg0)
0
(none)
)
(defmethod draw-option ((this menu-loading-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(set-scale! arg1 0.55)
(let ((a0-2 arg1))
(set! (-> a0-2 color) (font-color font-color-33))
)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 120.0)
(set! (-> arg1 origin y) 110.0)
(set-width! arg1 270)
(set-height! arg1 35)
(when (or (< (mod (current-time) 300) 150) (!= (-> arg0 menu-transition) 0.0))
(let ((v1-15 161))
(case (-> arg0 current)
(('saving)
(set! v1-15 160)
)
(('formatting)
(set! v1-15 162)
)
(('creating)
(set! v1-15 163)
)
)
(print-game-text
(lookup-text! *common-text* (the-as text-id v1-15) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
)
)
(+! (-> arg1 origin y) 45.0)
(set-height! arg1 160)
(let ((a0-16 arg1))
(set! (-> a0-16 color) (font-color font-color-32))
)
(let ((s5-1 print-game-text))
(format (clear *temp-string*) (lookup-text! *common-text* (text-id progress-memcard-remove-warn) #f) 1)
(s5-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
0
(none)
)
(defmethod draw-option ((this menu-insufficient-space-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(when (!= (-> arg0 current) 'none)
(set-scale! arg1 0.5)
(let ((a0-3 arg1))
(set! (-> a0-3 color) (font-color font-color-32))
)
(let ((a0-4 arg1))
(set! (-> a0-4 flags) (font-flags kerning middle middle-vert large))
)
(progress-method-53 arg0 arg1)
(+! (-> arg1 origin x) 10.0)
(set! (-> arg1 origin y) 80.0)
(let ((v1-10 arg1))
(set! (-> v1-10 width) (+ -20.0 (-> arg1 width)))
)
(set-height! arg1 80)
(let ((s4-0 155))
(case (-> arg0 current)
(('insufficient-space)
(set! s4-0 153)
)
(('no-memory-card)
(set! s4-0 154)
)
)
(let ((s3-0 print-game-text))
(format (clear *temp-string*) (lookup-text! *common-text* (the-as text-id s4-0) #f) 1)
(s3-0 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
(+! (-> arg1 origin y) 80.0)
(set-height! arg1 50)
(let ((s4-1 print-game-text))
(format
(clear *temp-string*)
(lookup-text! *common-text* (text-id progress-memcard-space-requirement) #f)
(if *progress-save-info*
(-> *progress-save-info* mem-required)
0
)
)
(s4-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 55.0)
(set-height! arg1 90)
(cond
((and (!= (-> arg0 starting-state) 'insufficient-space) (!= (-> arg0 starting-state) 'no-memory-card))
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-insert-with-free-space) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 60.0)
(let ((a0-26 arg1))
(set! (-> a0-26 color) (font-color font-color-33))
)
(draw-highlight-bar arg0 arg1 (the int (+ 30.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-continue) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
)
(else
(let ((a0-30 arg1))
(set! (-> a0-30 color) (font-color font-color-33))
)
(+! (-> arg1 origin y) 20.0)
(draw-highlight-bar arg0 arg1 (the int (+ 30.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(draw-yes-no-style-footer
arg0
arg1
(text-id progress-memcard-continue?)
(text-id progress-memcard-insufficient-space-retry?)
)
)
)
)
0
(none)
)
(defmethod draw-option ((this menu-hero-mode-message-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition)))))
(s4-0 *progress-work*)
)
(progress-method-33 arg0 (-> s4-0 body-footer))
(progress-method-53 arg0 arg1)
(set! (-> arg1 alpha) f30-0)
(set-scale! arg1 0.5)
(let ((a0-4 arg1))
(set! (-> a0-4 color) (font-color font-color-32))
)
(let ((a0-5 arg1))
(set! (-> a0-5 flags) (font-flags kerning middle middle-vert large))
)
(let ((s3-0 print-game-text))
(let* ((s2-0 format)
(s1-0 (clear *temp-string*))
(a0-7 *common-text*)
(t9-3 (method-of-object a0-7 lookup-text!))
(a1-3 2199)
(a2-1 #f)
)
(s2-0 s1-0 (t9-3 a0-7 (the-as text-id a1-3) a2-1) (the-as none a2-1))
)
(s3-0 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(progress-method-34 arg0)
(progress-method-33 arg0 (-> s4-0 footer))
)
(progress-method-53 arg0 arg1)
(let ((a0-13 arg1))
(set! (-> a0-13 color) (font-color font-color-33))
)
(adjust-font-origin-y arg0 arg1 0.1)
(draw-highlight-bar arg0 arg1 (the int (-> arg1 origin y)) 18 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-continue) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(progress-method-34 arg0)
0
(none)
)
(defmethod draw-option ((this menu-secrets-insufficient-space-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition)))))
(s4-0 *progress-work*)
)
(progress-method-33 arg0 (-> s4-0 body-footer))
(progress-method-53 arg0 arg1)
(set! (-> arg1 alpha) f30-0)
(set-scale! arg1 0.5)
(let ((a0-4 arg1))
(set! (-> a0-4 color) (font-color font-color-32))
)
(let ((a0-5 arg1))
(set! (-> a0-5 flags) (font-flags kerning middle middle-vert large))
)
(let ((s3-0 print-game-text))
(format (clear *temp-string*) (lookup-text! *common-text* (text-id progress-memcard-no-card-in-slot) #f) 1)
(s3-0 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(progress-method-34 arg0)
(progress-method-33 arg0 (-> s4-0 footer))
)
(progress-method-53 arg0 arg1)
(let ((a0-13 arg1))
(set! (-> a0-13 color) (font-color font-color-33))
)
(adjust-font-origin-y arg0 arg1 0.1)
(draw-highlight-bar arg0 arg1 (the int (-> arg1 origin y)) 18 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-continue) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(progress-method-34 arg0)
0
(none)
)
(defmethod draw-option ((this menu-insert-card-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(set-scale! arg1 0.5)
(let ((a0-2 arg1))
(set! (-> a0-2 color) (font-color font-color-32))
)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 90.0)
(set! (-> arg1 origin y) 130.0)
(set-width! arg1 330)
(set-height! arg1 95)
(let ((s4-0 print-game-text))
(format
(clear *temp-string*)
(lookup-text! *common-text* (text-id progress-memcard-insert-with-jak3-data) #f)
1
)
(s4-0 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 115.0)
(set-height! arg1 60)
(let ((a0-11 arg1))
(set! (-> a0-11 color) (font-color font-color-33))
)
(draw-highlight-bar arg0 arg1 (the int (+ 17.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-go-back?) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
0
(none)
)
(defmethod draw-option ((this menu-error-loading-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(set-scale! arg1 0.5)
(let ((a0-2 arg1))
(set! (-> a0-2 color) (font-color font-color-32))
)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 90.0)
(set! (-> arg1 origin y) 100.0)
(set-width! arg1 330)
(set-height! arg1 45)
(let ((s4-0 170))
(case (-> arg0 current)
(('error-saving)
(set! s4-0 171)
)
(('error-formatting)
(set! s4-0 172)
)
(('error-creating)
(set! s4-0 173)
)
)
(let ((s3-0 print-game-text))
(format (clear *temp-string*) (lookup-text! *common-text* (the-as text-id s4-0) #f) 1)
(s3-0 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
)
(+! (-> arg1 origin y) 50.0)
(set-height! arg1 105)
(let ((s4-1 print-game-text))
(format
(clear *temp-string*)
(lookup-text! *common-text* (text-id progress-memcard-check-and-try-again) #f)
1
)
(s4-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 115.0)
(set-height! arg1 45)
(let ((a0-21 arg1))
(set! (-> a0-21 color) (font-color font-color-33))
)
(draw-highlight-bar arg0 arg1 (the int (+ 9.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-continue) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
0
(none)
)
(defmethod draw-option ((this menu-error-auto-saving-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(set-scale! arg1 0.5)
(let ((a0-2 arg1))
(set! (-> a0-2 color) (font-color font-color-32))
)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 77.0)
(set! (-> arg1 origin y) 85.0)
(set-width! arg1 360)
(set-height! arg1 25)
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-save-error) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 25.0)
(set-height! arg1 60)
(let ((s4-1 print-game-text))
(format (clear *temp-string*) (lookup-text! *common-text* (text-id progress-memcard-check) #f) 1)
(s4-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 60.0)
(set-height! arg1 45)
(print-game-text
(lookup-text! *common-text* (text-id progress-autosave-disabled) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 45.0)
(set-height! arg1 95)
(print-game-text
(lookup-text! *common-text* (text-id progress-autosave-reenable-info) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 90.0)
(set-height! arg1 25)
(let ((a0-20 arg1))
(set! (-> a0-20 color) (font-color font-color-33))
)
(draw-highlight-bar arg0 arg1 (the int (-> arg1 origin y)) 22 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-continue) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
0
(none)
)
(defmethod draw-option ((this menu-card-removed-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(set-scale! arg1 0.5)
(let ((a0-2 arg1))
(set! (-> a0-2 color) (font-color font-color-32))
)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 80.0)
(set! (-> arg1 origin y) 80.0)
(set-width! arg1 360)
(set-height! arg1 70)
(let ((s4-0 print-game-text))
(format (clear *temp-string*) (lookup-text! *common-text* (text-id progress-memcard-removed) #f) 1)
(s4-0 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 65.0)
(print-game-text
(lookup-text! *common-text* (text-id progress-autosave-disabled) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 65.0)
(set-height! arg1 90)
(print-game-text
(lookup-text! *common-text* (text-id progress-autosave-reenable-info) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 85.0)
(set-height! arg1 35)
(let ((a0-16 arg1))
(set! (-> a0-16 color) (font-color font-color-33))
)
(draw-highlight-bar arg0 arg1 (the int (+ 5.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-continue) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
0
(none)
)
(defmethod draw-option ((this menu-error-disc-removed-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-1 arg1))
(set! (-> a0-1 color) (font-color font-color-32))
)
(set-scale! arg1 0.5)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 80.0)
(set! (-> arg1 origin y) 120.0)
(set-width! arg1 360)
(set-height! arg1 35)
(print-game-text
(lookup-text! *common-text* (text-id progress-disc-removed-notice) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 45.0)
(set-height! arg1 85)
(print-game-text
(lookup-text! *common-text* (text-id progress-disc-removed-prompt) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(when (is-cd-in?)
(+! (-> arg1 origin y) 95.0)
(set-height! arg1 50)
(let ((a0-12 arg1))
(set! (-> a0-12 color) (font-color font-color-33))
)
(draw-highlight-bar arg0 arg1 (the int (+ 12.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-continue) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
)
0
(none)
)
(defmethod draw-option ((this menu-error-reading-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-1 arg1))
(set! (-> a0-1 color) (font-color font-color-32))
)
(set-scale! arg1 0.5)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 90.0)
(set! (-> arg1 origin y) 120.0)
(set-width! arg1 330)
(set-height! arg1 35)
(print-game-text
(lookup-text! *common-text* (text-id progress-disc-read-error) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 55.0)
(set-height! arg1 85)
(print-game-text
(lookup-text! *common-text* (text-id progress-disc-read-error-prompt) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 105.0)
(set-height! arg1 50)
(let ((a0-12 arg1))
(set! (-> a0-12 color) (font-color font-color-33))
)
(draw-highlight-bar arg0 arg1 (the int (+ 12.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-continue) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
0
(none)
)
(defmethod draw-option ((this menu-icon-info-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-1 arg1))
(set! (-> a0-1 color) (font-color font-color-32))
)
(set-scale! arg1 0.5)
(set! (-> *bigmap* auto-save-icon-flag) #t)
(set! (-> this sprites 0 tid) (the-as texture-id (get-texture checkpoint level-default-minimap)))
(set! (-> this sprites 0 scale-x) 1.0)
(set! (-> this sprites 0 scale-y) 1.0)
(let ((v1-6 (-> this sprites 0 color-ptr)))
(set! (-> v1-6 0) 128)
(set! (-> v1-6 1) 128)
(set! (-> v1-6 2) 128)
(set! (-> v1-6 3) (the int (* 128.0 (- 1.0 (-> arg0 menu-transition)))))
)
(set! (-> this sprites 0 pos z) #xffffff)
(set! (-> this sprites 0 pos w) 0)
(set-hud-piece-position! (-> this sprites 0) 240 160)
(with-dma-buffer-add-bucket ((s2-0 (-> *display* frames (-> *display* on-screen) global-buf))
(bucket-id hud-draw-hud-alpha)
)
((method-of-type hud-sprite draw) (-> this sprites 0) s2-0 (-> *level* level-default) #t)
)
(let ((a0-16 arg1))
(set! (-> a0-16 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 90.0)
(set! (-> arg1 origin y) 80.0)
(set-width! arg1 330)
(set-height! arg1 85)
(print-game-text
(lookup-text! *common-text* (text-id progress-autosave-notice) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 115.0)
(set-height! arg1 95)
(let ((s4-2 print-game-text))
(format (clear *temp-string*) (lookup-text! *common-text* (text-id progress-autosave-remove-warn) #f) 1)
(s4-2 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 90.0)
(set-height! arg1 50)
(let ((a0-27 arg1))
(set! (-> a0-27 color) (font-color font-color-33))
)
(draw-highlight-bar arg0 arg1 (the int (+ 12.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-continue) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
0
(none)
)
(defmethod draw-option ((this menu-format-card-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-1 arg1))
(set! (-> a0-1 color) (font-color font-color-32))
)
(set-scale! arg1 0.5)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 80.0)
(set! (-> arg1 origin y) 80.0)
(set-width! arg1 360)
(set-height! arg1 85)
(let ((s4-0 print-game-text))
(format (clear *temp-string*) (lookup-text! *common-text* (text-id progress-memcard-unformatted) #f) 1)
(s4-0 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 95.0)
(set-height! arg1 85)
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-formatting-required-notice) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 95.0)
(set-height! arg1 25)
(draw-highlight-bar arg0 arg1 (the int (-> arg1 origin y)) 44 (-> arg1 alpha))
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-format?) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 25.0)
(draw-yes-no-style-footer arg0 arg1 (text-id progress-yes) (text-id progress-no))
0
(none)
)
(defmethod draw-option ((this menu-already-exists-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-1 arg1))
(set! (-> a0-1 color) (font-color font-color-32))
)
(set-scale! arg1 0.5)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 80.0)
(set! (-> arg1 origin y) 120.0)
(set-width! arg1 360)
(set-height! arg1 85)
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-overwrite-warning) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 105.0)
(set-height! arg1 45)
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-overwrite-confirm?) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 45.0)
(draw-highlight-bar arg0 arg1 (the int (+ 8.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(draw-yes-no-style-footer arg0 arg1 (text-id progress-yes) (text-id progress-no))
0
(none)
)
(defmethod draw-option ((this menu-create-game-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-1 arg1))
(set! (-> a0-1 color) (font-color font-color-32))
)
(set-scale! arg1 0.5)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 80.0)
(set! (-> arg1 origin y) 110.0)
(set-width! arg1 360)
(set-height! arg1 90)
(let ((s4-0 print-game-text))
(format (clear *temp-string*) (lookup-text! *common-text* (text-id progress-memcard-no-save-data) #f) 1)
(s4-0 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(+! (-> arg1 origin y) 95.0)
(set-height! arg1 60)
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-create-save-data?) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 70.0)
(draw-highlight-bar arg0 arg1 (the int (+ 18.0 (-> arg1 origin y))) 22 (-> arg1 alpha))
(draw-yes-no-style-footer arg0 arg1 (text-id progress-yes) (text-id progress-no))
0
(none)
)
(defmethod draw-option ((this menu-video-mode-warning-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-1 arg1))
(set! (-> a0-1 color) (font-color font-color-32))
)
(set-scale! arg1 0.5)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 80.0)
(set! (-> arg1 origin y) 85.0)
(set-width! arg1 360)
(set-height! arg1 45)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-prog-scan-change-notice) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 50.0)
(set-height! arg1 95)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-prog-scan-warn-2) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 85.0)
(set-height! arg1 55)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-60hz-change-notice) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 60.0)
(set-height! arg1 30)
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-continue?) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 20.0)
(draw-highlight-bar arg0 arg1 (the int (-> arg1 origin y)) 24 (-> arg1 alpha))
(draw-yes-no-style-footer arg0 arg1 (text-id progress-yes) (text-id progress-no))
0
(none)
)
(defmethod draw-option ((this menu-video-mode-ok-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-1 arg1))
(set! (-> a0-1 color) (font-color font-color-32))
)
(set-scale! arg1 0.5)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 80.0)
(set! (-> arg1 origin y) 130.0)
(set-width! arg1 360)
(set-height! arg1 50)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-60hz-change-complete) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 70.0)
(set-height! arg1 50)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-prog-scan-keep) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 50.0)
(draw-highlight-bar arg0 arg1 (the int (+ 12.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(draw-yes-no-style-footer arg0 arg1 (text-id progress-yes) (text-id progress-no))
0
(none)
)
(defmethod draw-option ((this menu-progressive-mode-warning-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-1 arg1))
(set! (-> a0-1 color) (font-color font-color-32))
)
(set-scale! arg1 0.5)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 80.0)
(set! (-> arg1 origin y) 75.0)
(set-width! arg1 360)
(set-height! arg1 50)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-prog-scan-warn-1) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 50.0)
(set-height! arg1 90)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-prog-scan-warn-2) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 85.0)
(set-height! arg1 75)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-60hz-change-notice) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 70.0)
(set-height! arg1 30)
(print-game-text
(lookup-text! *common-text* (text-id progress-memcard-continue?) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 25.0)
(draw-highlight-bar arg0 arg1 (the int (-> arg1 origin y)) 24 (-> arg1 alpha))
(draw-yes-no-style-footer arg0 arg1 (text-id progress-yes) (text-id progress-no))
0
(none)
)
(defmethod draw-option ((this menu-progressive-mode-ok-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> arg1 alpha) (- 1.0 (-> arg0 menu-transition)))
(let ((a0-1 arg1))
(set! (-> a0-1 color) (font-color font-color-32))
)
(set-scale! arg1 0.55)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning middle middle-vert large))
)
(set! (-> arg1 origin x) 80.0)
(set! (-> arg1 origin y) 90.0)
(set-width! arg1 360)
(set-height! arg1 80)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-prog-scan-change-complete) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 100.0)
(set-height! arg1 75)
(print-game-text
(lookup-text! *common-text* (text-id progress-graphics-prog-scan-keep) #f)
arg1
#f
44
(bucket-id hud-draw-hud-alpha)
)
(+! (-> arg1 origin y) 70.0)
(draw-highlight-bar arg0 arg1 (the int (+ 20.0 (-> arg1 origin y))) 24 (-> arg1 alpha))
(draw-yes-no-style-footer arg0 arg1 (text-id progress-yes) (text-id progress-no))
0
(none)
)
(defmethod draw-option ((this menu-select-start-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(set! (-> *progress-list-level* mode) (-> arg0 current))
(set! (-> *progress-list-level* act) (-> *progress-work* selected-num))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(let ((s3-0 (length *progress-list-level*)))
(set! (-> arg1 alpha) f30-0)
(let ((a0-4 arg1))
(set! (-> a0-4 flags) (font-flags kerning large))
)
(set-scale! arg1 0.42)
(progress-method-33 arg0 (-> *progress-work* body-footer))
(let ((s2-1 (max 0 (the int (-> this current-index))))
(s1-0 print-game-text)
)
(format
(clear *temp-string*)
"~S"
(lookup-text! *common-text* (-> (progress-list-method-9 *progress-list-level* s2-1) text-name) #f)
)
(let ((f28-0 (s1-0 *temp-string* arg1 #t 44 (bucket-id hud-draw-hud-alpha))))
(let ((s1-1 (get-scissor-stack-top arg0)))
(let ((f0-5 (- (-> s1-1 w) (-> s1-1 y))))
(let* ((v1-18 arg1)
(f1-4 (+ 10.0 (-> s1-1 x)))
(f2-3 8.0)
(f3-1 (-> this current-index))
(f2-5 (+ (- f2-3 (* f28-0 (- f3-1 (* (the float (the int (/ f3-1 1.0))) 1.0)))) (-> s1-1 y)))
)
(set! (-> v1-18 origin x) f1-4)
(set! (-> v1-18 origin y) f2-5)
)
(let ((v1-19 arg1))
(set! (-> v1-19 width) (+ (- -20.0 (-> s1-1 x)) (-> s1-1 z)))
)
(set! (-> arg1 height) f0-5)
)
(while (and (< (-> arg1 origin y) (-> s1-1 w)) (< s2-1 s3-0))
(cond
((= s2-1 (-> this selected-index))
(let ((a0-18 arg1))
(set! (-> a0-18 color) (font-color font-color-34))
)
)
(else
(let ((a0-19 arg1))
(set! (-> a0-19 color) (font-color font-color-32))
)
)
)
(let ((s0-1 print-game-text))
(format
(clear *temp-string*)
"~S"
(lookup-text! *common-text* (-> (progress-list-method-9 *progress-list-level* s2-1) text-name) #f)
)
(let ((f26-0 (s0-1 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha))))
(if (= s2-1 (-> this selected-index))
(draw-highlight-bar arg0 arg1 (the int (+ -2.0 (-> arg1 origin y))) (the int (+ 2.0 f26-0)) f30-0)
)
(+! (-> arg1 origin y) f26-0)
)
)
(+! s2-1 1)
)
)
(seek!
(-> this current-index)
(-> this target-index)
(* (/ (-> this scroll-speed) f28-0) (seconds-per-frame))
)
)
)
)
(progress-method-34 arg0)
(let ((s3-1 *progress-work*))
(let* ((a0-28 arg0)
(t9-16 (method-of-object a0-28 draw-header))
(a1-12 arg1)
(a2-9 f30-0)
(v1-46 (-> *progress-work* selected-num))
)
(t9-16 a0-28 a1-12 a2-9 (cond
((zero? v1-46)
(text-id progress-select-start)
)
((= v1-46 1)
(text-id progress-title-level-select-act-1)
)
((= v1-46 2)
(text-id progress-title-level-select-act-2)
)
(else
(text-id progress-title-level-select-act-3)
)
)
)
)
(draw-bg-box-alpha-2 arg0 (-> s3-1 footer) (* 64.0 f30-0))
(draw-bg-box-outline arg0 (-> s3-1 footer) (* 128.0 f30-0))
)
)
(progress-method-47
arg0
arg1
(!= (-> this current-index) 0.0)
(!= (-> this current-index) (the float (+ (-> arg0 total-num-tasks) -1)))
)
0
(none)
)
(defmethod draw-option ((this menu-select-scene-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(let* ((v1-3 (-> *progress-work* selected-num))
(s3-0 (cond
((zero? v1-3)
*hud-select-scene-act1*
)
((= v1-3 1)
*hud-select-scene-act2*
)
((= v1-3 2)
*hud-select-scene-act3*
)
(else
*hud-select-scene-commentary*
)
)
)
(s2-0 (-> s3-0 length))
)
(set! (-> arg1 alpha) f30-0)
(let ((a0-3 arg1))
(set! (-> a0-3 flags) (font-flags kerning large))
)
(set-scale! arg1 0.42)
(progress-method-33 arg0 (-> *progress-work* body-footer))
(let ((s1-1 (max 0 (the int (-> this current-index))))
(s0-0 print-game-text)
)
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> s3-0 s1-1 text) #f))
(let ((f28-0 (s0-0 *temp-string* arg1 #t 44 (bucket-id hud-draw-hud-alpha))))
(let ((s0-1 (get-scissor-stack-top arg0)))
(let ((f0-5 (- (-> s0-1 w) (-> s0-1 y))))
(let* ((v1-16 arg1)
(f1-4 (+ 10.0 (-> s0-1 x)))
(f2-3 8.0)
(f3-1 (-> this current-index))
(f2-5 (+ (- f2-3 (* f28-0 (- f3-1 (* (the float (the int (/ f3-1 1.0))) 1.0)))) (-> s0-1 y)))
)
(set! (-> v1-16 origin x) f1-4)
(set! (-> v1-16 origin y) f2-5)
)
(let ((v1-17 arg1))
(set! (-> v1-17 width) (+ (- -20.0 (-> s0-1 x)) (-> s0-1 z)))
)
(set! (-> arg1 height) f0-5)
)
(while (and (< (-> arg1 origin y) (-> s0-1 w)) (< s1-1 s2-0))
(cond
((= s1-1 (-> this selected-index))
(let ((a0-16 arg1))
(set! (-> a0-16 color) (font-color font-color-34))
)
)
(else
(let ((a0-17 arg1))
(set! (-> a0-17 color) (font-color font-color-32))
)
)
)
(let ((sv-64 print-game-text))
(format (clear *temp-string*) "~S" (lookup-text! *common-text* (-> s3-0 s1-1 text) #f))
(let ((f26-0 (sv-64 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha))))
(if (= s1-1 (-> this selected-index))
(draw-highlight-bar arg0 arg1 (the int (+ -2.0 (-> arg1 origin y))) (the int (+ 2.0 f26-0)) f30-0)
)
(+! (-> arg1 origin y) f26-0)
)
)
(+! s1-1 1)
)
)
(seek!
(-> this current-index)
(-> this target-index)
(* (/ (-> this scroll-speed) f28-0) (seconds-per-frame))
)
)
)
)
(progress-method-34 arg0)
(let ((s3-1 *progress-work*))
(let* ((a0-25 arg0)
(t9-13 (method-of-object a0-25 draw-header))
(a1-10 arg1)
(a2-9 f30-0)
(v1-44 (-> *progress-work* selected-num))
)
(t9-13 a0-25 a1-10 a2-9 (cond
((zero? v1-44)
(text-id progress-scene-player-act-1)
)
((= v1-44 1)
(text-id progress-scene-player-act-2)
)
((= v1-44 2)
(text-id progress-scene-player-act-3)
)
(else
(text-id progress-title-commentary)
)
)
)
)
(draw-bg-box-alpha-2 arg0 (-> s3-1 footer) (* 64.0 f30-0))
(draw-bg-box-outline arg0 (-> s3-1 footer) (* 128.0 f30-0))
)
)
(progress-method-47
arg0
arg1
(!= (-> this current-index) 0.0)
(!= (-> this current-index) (the float (+ (-> arg0 total-num-tasks) -1)))
)
0
(none)
)
(defmethod draw-option ((this menu-qr-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(let ((f30-0 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition))))))
(set! (-> arg1 alpha) f30-0)
(adjust-font-origin-y arg0 arg1 (-> this offset-y))
(cond
(arg3
(let ((a0-2 arg1))
(set! (-> a0-2 color) (font-color font-color-34))
)
)
((= (-> arg0 option-index) arg2)
(let ((v1-6 arg1))
(set! (-> v1-6 color) (font-color font-color-33))
)
)
(else
(let ((v1-7 arg1))
(set! (-> v1-7 color) (font-color font-color-32))
)
)
)
(set-scale! arg1 0.75)
(let ((f28-0
(print-game-text (lookup-text! *common-text* (-> this name) #f) arg1 #f 24 (bucket-id hud-draw-hud-alpha))
)
)
(when (= (-> arg0 option-index) arg2)
(draw-highlight-bar arg0 arg1 (the int (+ -2.0 (-> arg1 origin y))) (the int (+ 8.0 f28-0)) f30-0)
(set! (-> arg1 origin y) (+ 4.0 f28-0 (-> arg1 origin y)))
)
)
(when arg3
(set-scale! arg1 0.6)
(draw-yes-no-style-footer arg0 arg1 (text-id progress-yes) (text-id progress-no))
)
(if (zero? arg2)
(draw-header arg0 arg1 f30-0 (text-id progress-qr))
)
)
0
(none)
)
(defun unlocked-secret-menu? ((arg0 game-secrets))
(logtest? arg0 (game-secrets
scene-player-1
scene-player-2
scene-player-3
title-commentary
level-select-1
level-select-2
level-select-3
scrap-book-1
scrap-book-2
model-viewer-1
model-viewer-2
model-viewer-3
)
)
)
;; WARN: Return type mismatch object vs game-secrets.
(defun memcard-unlocked-secrets? ((arg0 object) (arg1 symbol))
(let ((v1-0 *progress-save-info*)
(s5-0 (the-as object 0))
)
(let ((a0-1 4)
(s4-0 *progress-work*)
)
(when (and v1-0 (= (-> v1-0 formatted) 1) (= (-> v1-0 inited) 1))
(dotimes (a1-6 a0-1)
(set! s5-0 (logior (the-as int s5-0) (-> v1-0 file a1-6 purchase-secrets)))
)
)
(if (or (nonzero? (-> *setting-control* user-current subtitle-language))
(nonzero? (-> *setting-control* user-current language))
(nonzero? (-> *setting-control* user-current audio-language))
)
(set! s5-0 (logand -17 (the-as int s5-0)))
)
(cond
((kiosk?)
(set! (-> s4-0 secrets-unlocked) #t)
(set! s5-0 (logior (the-as int s5-0) 32))
)
((unlocked-secret-menu? (the-as game-secrets s5-0))
(set! (-> s4-0 secrets-unlocked) #t)
)
(else
(set! (-> s4-0 secrets-unlocked) #f)
)
)
(when *cheat-mode*
(set! (-> s4-0 secrets-unlocked) #t)
(set! s5-0 (logior (the-as int s5-0) #x3bfe))
)
)
(the-as game-secrets (cond
(arg1
(empty)
s5-0
)
(else
(unlocked-secret-menu? (the-as game-secrets s5-0))
)
)
)
)
)
(defun num-unlocked-secret? ((arg0 game-secrets))
(let ((v0-0 0))
(if (logtest? arg0 (game-secrets scene-player-1))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets scene-player-2))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets scene-player-3))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets title-commentary))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets level-select-1))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets level-select-2))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets level-select-3))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets scrap-book-1))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets scrap-book-2))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets model-viewer-1))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets model-viewer-2))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets model-viewer-3))
(+! v0-0 1)
)
(if (logtest? arg0 (game-secrets hero-mode))
(+! v0-0 1)
)
v0-0
)
)
(defmethod secret-item-option-method-12 ((this secret-item-option))
(cond
((logtest? (-> this flags) (secret-item-option-flags sf0))
5
)
((logtest? (-> *game-info* purchase-secrets) (-> this secret))
(if (logtest? (-> *game-info* secrets) (-> this secret))
1
2
)
)
((and (not (task-node-closed? (-> this avail-after)))
(not (logtest? (-> *game-info* secrets) (game-secrets hero-mode)))
)
4
)
((!= (logand (-> *game-info* purchase-secrets) (-> this required-secrets)) (-> this required-secrets))
3
)
(else
0
)
)
)
(defmethod secret-item-option-method-13 ((this secret-item-option))
(local-vars (v0-1 game-vehicles))
(when (zero? (secret-item-option-method-12 this))
(case (-> this secret)
(((game-secrets hero-mode))
(logior! (-> *game-info* purchase-secrets) (-> this secret))
)
(else
(logior! (-> *game-info* purchase-secrets) (-> this secret))
(set! (-> *game-info* secrets)
(logclear (logior (-> *game-info* secrets) (-> this secret)) (-> this mask-secrets))
)
)
)
(case (-> this secret)
(((game-secrets vehicle-fox))
(set! v0-1 (logior (-> *game-info* vehicles) (game-vehicles v-fox)))
(set! (-> *game-info* vehicles) v0-1)
v0-1
)
(((game-secrets vehicle-mirage))
(set! v0-1 (logior (-> *game-info* vehicles) (game-vehicles v-mirage)))
(set! (-> *game-info* vehicles) v0-1)
v0-1
)
(((game-secrets vehicle-x-ride))
(set! v0-1 (logior (-> *game-info* vehicles) (game-vehicles v-x-ride)))
(set! (-> *game-info* vehicles) v0-1)
v0-1
)
)
)
)
(defmethod draw-option ((this menu-secret-option) (arg0 progress) (arg1 font-context) (arg2 int) (arg3 symbol))
(local-vars (a0-19 string) (sv-192 string) (sv-240 string))
(let ((sv-16 (fmax 0.0 (* 2.0 (- 0.5 (-> arg0 menu-transition)))))
(sv-24 (the int (-> *game-info* skill)))
)
(set! (-> arg1 alpha) sv-16)
(cond
((not (loaded? *bigmap*))
(progress-method-51 arg0 arg1)
)
(else
(new 'stack 'hud-sprite)
(let ((s2-0 (get-texture hud-orb progress-minimap)))
(when (and s2-0 (not (-> this available-title)))
(progress-method-33 arg0 (-> *progress-work* sub-header))
(let ((s3-0 (get-scissor-stack-top arg0)))
(let* ((f0-5 0.64)
(f30-0 (+ 10.0 (* (the float (-> s2-0 w)) f0-5 (-> *video-params* relative-x-scale))))
)
(let ((f1-5 (* (the float (-> s2-0 h)) f0-5)))
(+ (- (- -20.0 f30-0) (-> s3-0 x)) (-> s3-0 z))
(let ((t1-0 (logior #x808080 (shr (shl (the int (* 128.0 sv-16)) 56) 32))))
(draw-icon-array!
(-> *progress-icon-arrays* 68)
(the int (+ 10.0 (-> s3-0 x)))
(the int (+ (-> s3-0 y) (* 0.5 (- 28.0 f1-5))))
f0-5
f0-5
(the-as rgba t1-0)
sv-16
)
)
)
(let ((v1-26 arg1))
(set! (-> v1-26 height) 28.0)
)
(let ((a0-13 arg1))
(set! (-> a0-13 flags) (font-flags kerning large))
)
(let ((f28-0 0.45))
(let ((a0-14 arg1))
(set! (-> a0-14 color) (font-color font-color-34))
)
(cond
((-> this buy-menu)
(format
(clear *temp-string*)
"x~D ~S"
(-> *menu-secrets-array* (-> this selected-index) cost)
(lookup-text! *common-text* (text-id progress-secrets-price) #f)
)
(set! a0-19 *temp-string*)
)
(else
(format
(clear *temp-string*)
"x~D ~S"
sv-24
(lookup-text! *common-text* (text-id progress-secrets-orbs-available) #f)
)
(set! a0-19 *temp-string*)
)
)
(set-scale! arg1 f28-0)
(let ((v1-43 arg1)
(f0-10 (+ (-> s3-0 x) f30-0))
(f1-11 (+ (-> s3-0 y) (* 0.5 (- 28.0 (* 32.0 f28-0)))))
)
(set! (-> v1-43 origin x) f0-10)
(set! (-> v1-43 origin y) f1-11)
)
)
)
(print-game-text a0-19 arg1 #f 44 (bucket-id hud-draw-hud-alpha))
(let ((a0-23 arg1))
(set! (-> a0-23 flags) (font-flags kerning right large))
)
(set! (-> arg1 origin x) (+ -10.0 (-> s3-0 z)))
)
(let ((s3-1 print-game-text))
(format
(clear *temp-string*)
"~D/600 ~S"
(the int (-> *game-info* skill-total))
(lookup-text! *common-text* (text-id progress-secrets-orbs-collected) #f)
)
(s3-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(progress-method-34 arg0)
)
)
(set-scale! arg1 0.42)
(cond
((-> this available-title)
(progress-method-33 arg0 (-> *progress-work* body-footer))
(progress-method-53 arg0 arg1)
(let ((a0-32 arg1))
(set! (-> a0-32 color) (font-color font-color-32))
)
(let ((a0-33 arg1))
(set! (-> a0-33 flags) (font-flags kerning middle middle-vert large))
)
(let ((s4-1 print-game-text))
(format (clear *temp-string*) (lookup-text! *common-text* (text-id text-0080) #f))
(s4-1 *temp-string* arg1 #f 44 (bucket-id hud-draw-hud-alpha))
)
(progress-method-34 arg0)
(progress-method-33 arg0 (-> *progress-work* footer))
(let ((a0-40 arg1))
(set! (-> a0-40 flags) (font-flags kerning middle large))
)
(adjust-font-origin-y arg0 arg1 0.1)
(let ((a0-42 arg1))
(set! (-> a0-42 color) (font-color font-color-33))
)
(let ((f0-16 (print-game-text
(lookup-text! *common-text* (text-id progress-continue) #f)
arg1
#f
32
(bucket-id hud-draw-hud-alpha)
)
)
)
(draw-highlight-bar arg0 arg1 (the int (+ -2.0 (-> arg1 origin y))) (the int (+ 4.0 f0-16)) (-> arg1 alpha))
)
(progress-method-34 arg0)
)
((-> this buy-menu)
(progress-method-33 arg0 (-> *progress-work* body))
(adjust-font-origin-y arg0 arg1 0.45)
(progress-method-50
arg0
arg1
(-> *menu-secrets-array* (-> this selected-index) name)
(text-id progress-secrets-buy)
(text-id progress-secrets-cancel)
#t
#t
0.65
)
(let ((s4-3 *progress-work*))
(draw-header arg0 arg1 sv-16 (text-id progress-secrets))
(draw-bg-box-outline arg0 (-> s4-3 sub-header) (* 128.0 sv-16))
)
(progress-method-34 arg0)
)
(else
(progress-method-33 arg0 (-> *progress-work* sub-body-footer))
(let* ((s3-3 (get-scissor-stack-top arg0))
(f22-0 (- (-> s3-3 w) (-> s3-3 y)))
(f30-1 (+ 10.0 (* 24.0 (-> *video-params* relative-x-scale) (-> arg1 scale))))
(f28-1 (+ (- -10.0 (-> s3-3 x)) (-> s3-3 z)))
(s2-5 get-string-length)
)
(format
(clear *temp-string*)
"~32L~S~44L ~S"
(lookup-text! *common-text* (text-id progress-on) #f)
(lookup-text! *common-text* (text-id progress-off) #f)
)
(let* ((f0-27 (-> (s2-5 *temp-string* arg1) length))
(f26-0 (- (- (- f28-1 f30-1) f0-27) f30-1))
)
(- f28-1 f26-0)
(let ((a0-60 arg1))
(set! (-> a0-60 flags) (font-flags kerning large))
)
(let ((v1-100 arg1))
(set! (-> v1-100 width) f26-0)
)
(let ((s2-6 *menu-secrets-array*)
(s1-5 (max 0 (the int (-> this current-index))))
)
(let* ((a0-61 (-> s2-6 s1-5))
(s0-4 (-> a0-61 name))
(v1-105 (secret-item-option-method-12 a0-61))
)
(set! sv-192 (cond
((= v1-105 4)
(set! sv-192 "?????????")
sv-192
)
(else
(lookup-text! *common-text* s0-4 #f)
)
)
)
)
(let ((s0-5 print-game-text))
(format (clear *temp-string*) "~S" sv-192)
(let ((f24-0 (s0-5 *temp-string* arg1 #t 40 (bucket-id hud-draw-hud-alpha))))
(let ((f0-33 4.0)
(f1-25 (-> this current-index))
)
(set! (-> arg1 origin y)
(+ (- f0-33 (* f24-0 (- f1-25 (* (the float (the int (/ f1-25 1.0))) 1.0)))) (-> s3-3 y))
)
)
(set! (-> arg1 height) f22-0)
(while (and (< (-> arg1 origin y) (-> s3-3 w)) (< s1-5 (-> *menu-secrets-array* length)))
(let* ((s0-6 (-> s2-6 s1-5))
(sv-208 (-> s2-6 s1-5 name))
(sv-288 (secret-item-option-method-12 s0-6))
)
(let ((v1-120 sv-288))
(set! sv-240 (cond
((= v1-120 4)
(set! sv-240 "?????????")
sv-240
)
(else
(lookup-text! *common-text* sv-208 #f)
)
)
)
)
(cond
((logtest? (-> s2-6 s1-5 flags) (secret-item-option-flags sf0))
(set! (-> arg1 origin x) (+ 10.0 (-> s3-3 x)))
(let ((v1-130 arg1))
(set! (-> v1-130 width) f28-1)
)
(let ((a0-70 arg1))
(set! (-> a0-70 color) (font-color font-color-34))
)
(let ((a0-71 arg1))
(set! (-> a0-71 flags) (font-flags kerning large))
)
(let ((f22-1 (-> arg1 origin y))
(s0-7 print-game-text)
)
(format (clear *temp-string*) "~S" sv-240)
(set! (-> arg1 origin y) (+ f22-1 (s0-7 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha))))
)
)
((not (and (logtest? (-> s2-6 s1-5 flags) (secret-item-option-flags sf4))
(or (nonzero? (-> *setting-control* user-current subtitle-language))
(nonzero? (-> *setting-control* user-current language))
(nonzero? (-> *setting-control* user-current audio-language))
)
)
)
(set! (-> arg1 origin x) (+ (-> s3-3 x) f30-1))
(let ((v1-147 arg1))
(set! (-> v1-147 width) f26-0)
)
(let ((v1-148 sv-288))
(cond
((or (= v1-148 4) (= v1-148 3))
(let ((a0-79 arg1))
(set! (-> a0-79 flags) (font-flags kerning large ff7))
)
(let ((v1-150 arg1))
(set! (-> v1-150 color) (font-color font-color-44))
)
)
((zero? v1-148)
(let ((a0-81 arg1))
(set! (-> a0-81 flags) (font-flags kerning large))
)
(let ((v1-152 arg1))
(set! (-> v1-152 color) (font-color font-color-34))
)
)
(else
(let ((a0-83 arg1))
(set! (-> a0-83 flags) (font-flags kerning large))
)
(let ((v1-154 arg1))
(set! (-> v1-154 color) (font-color font-color-32))
)
)
)
)
(let ((f22-2 (-> arg1 origin y))
(sv-256 print-game-text)
)
(format (clear *temp-string*) "~S" sv-240)
(let ((f20-0 (sv-256 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha))))
(when (not (logtest? (-> s2-6 s1-5 flags) (secret-item-option-flags sf0)))
(set! (-> arg1 origin x) (+ (-> s3-3 x) f28-1))
(let ((a0-88 arg1))
(set! (-> a0-88 flags) (font-flags kerning right large))
)
(let ((sv-352 (lookup-text! *common-text* (text-id progress-on) #f))
(sv-368 (lookup-text! *common-text* (text-id progress-off) #f))
)
(cond
((or (zero? sv-288) (= sv-288 3))
(let ((sv-304 print-game-text))
(format (clear *temp-string*) "~d" (-> s0-6 cost))
(sv-304 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha))
)
)
((= sv-288 1)
(cond
((logtest? (-> s2-6 s1-5 flags) (secret-item-option-flags sf1))
(let ((s0-8 print-game-text))
(format (clear *temp-string*) "~32L~S~44L ~S" sv-352 sv-368)
(s0-8 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha))
)
)
(else
(let ((s0-9 print-game-text))
(format (clear *temp-string*) "~S" sv-352)
(s0-9 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha))
)
)
)
)
((= sv-288 2)
(cond
((logtest? (-> s2-6 s1-5 flags) (secret-item-option-flags sf1))
(let ((s0-10 print-game-text))
(format (clear *temp-string*) "~44L~S ~32L~S~1L" sv-352 sv-368)
(s0-10 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha))
)
)
(else
(let ((s0-11 print-game-text))
(format (clear *temp-string*) "~S" sv-368)
(s0-11 *temp-string* arg1 #f 40 (bucket-id hud-draw-hud-alpha))
)
)
)
)
)
)
)
(+! (-> arg1 origin y) f20-0)
(if (= s1-5 (-> this selected-index))
(draw-highlight-bar arg0 arg1 (the int (+ -2.0 f22-2)) (the int (+ 3.0 f20-0)) sv-16)
)
)
)
)
)
)
(+! s1-5 1)
)
(seek! (-> this current-index) (-> this target-index) (* (/ 600.0 f24-0) (seconds-per-frame)))
)
)
)
)
)
(progress-method-34 arg0)
(let ((s3-4 *progress-work*))
(draw-header arg0 arg1 sv-16 (text-id progress-secrets))
(draw-bg-box-outline arg0 (-> s3-4 sub-header) (* 128.0 sv-16))
(draw-bg-box-alpha-2 arg0 (-> s3-4 footer) (* 64.0 sv-16))
(draw-bg-box-outline arg0 (-> s3-4 footer) (* 128.0 sv-16))
)
(progress-method-47
arg0
arg1
(!= (-> this current-index) 0.0)
(!= (-> this current-index) (the float (+ (-> *menu-secrets-array* length) -1)))
)
)
)
)
)
)
0
(none)
)