Files
jak-project/goal_src/engine/ui/progress/progress-part.gc
T
ManDude a7eee4fdc9 [game] pc port progress menu (#1281)
* fix typo

* more typo

* shorten discord rpc text

* allow expanding enums after the fact (untested)

* make `game_text` work similar to subtitles

* update progress decomp

* update some types + `do-not-decompile` in bitfield

* fixes and fall back to original progress code

* update `progress` decomp with new enums

* update config files

* fix enums and debug menu

* always allocate (but not use) a lot of particles

* small rework to display mode options

* revert resolution/aspect-ratio symbol mess

* begin the override stuff

* make `progress-draw` more readable

* more fixes

* codacy good boy points

* first step overriding code

* finish progress overrides, game options menu fully functional!

* minor fixes

* Update game.gp

* Update sparticle-launcher.gc

* clang

* change camera controls text

* oops

* some cleanup

* derp

* nice job

* implement menu scrolling lol

* make scrollable menus less cramped, fix arrows

* make some carousell things i guess

* add msaa carousell to test

* oops

* Update progress-pc.gc

* make `pc-get-screen-size` (untested)

* resolution menu

* input fixes

* return when selecting resolution

* scroll fixes

* Update progress-pc.gc

* add "fit to screen" button

* bug

* complete resolutions menu

* aspect ratio menu

* subtitles language

* subtitle speaker

* final adjustments

* ref test

* fix tests

* fix ref!

* reduce redundancy a bit

* fix mem leaks?

* save settings on progress exit

* fix init reorder

* remove unused code

* rename goal project-like files to the project extension

* sha display toggle

* aspect ratio settings fixes

* dont store text db's in compiler

* properly save+load native aspect stuff
2022-04-11 18:38:54 -04:00

1036 lines
30 KiB
Common Lisp

;;-*-Lisp-*-
(in-package goal)
;; name: progress-part.gc
;; name in dgo: progress-part
;; dgos: GAME, ENGINE
;; DECOMP BEGINS
(defun part-progress-hud-left-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(let ((v1-0 *progress-process*))
(set! (-> arg2 vector 0 w) (-> v1-0 0 left-side-x-scale))
(set! (-> arg2 vector 1 w) (-> v1-0 0 left-side-y-scale))
)
(none)
)
(defun part-progress-hud-right-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(let ((v1-0 *progress-process*))
(set! (-> arg2 vector 0 w) (-> v1-0 0 right-side-x-scale))
(set! (-> arg2 vector 1 w) (-> v1-0 0 right-side-y-scale))
)
(none)
)
(defun part-progress-hud-orb-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(#cond
(PC_PORT
(unless (and *pc-settings* (not (-> *pc-settings* use-vis?)))
(set! (-> arg2 vector 0 w) (/ 5324.8 (-> *progress-process* 0 sides-x-scale)))
(set! (-> arg2 vector 1 w) (/ 5324.8 (-> *progress-process* 0 sides-x-scale)))
)
)
(#t
(set! (-> arg2 vector 0 w) (/ 5324.8 (-> *progress-process* 0 sides-x-scale)))
(set! (-> arg2 vector 1 w) (/ 5324.8 (-> *progress-process* 0 sides-x-scale)))
)
)
(none)
)
(defun part-progress-hud-buzzer-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(#cond
(PC_PORT
(unless (and *pc-settings* (not (-> *pc-settings* use-vis?)))
(set! (-> arg2 vector 0 w) (/ 6144.0 (-> *progress-process* 0 sides-x-scale)))
(set! (-> arg2 vector 1 w) (/ 6144.0 (-> *progress-process* 0 sides-x-scale)))
)
)
(#t
(set! (-> arg2 vector 0 w) (/ 6144.0 (-> *progress-process* 0 sides-x-scale)))
(set! (-> arg2 vector 1 w) (/ 6144.0 (-> *progress-process* 0 sides-x-scale)))
)
)
(none)
)
(defun part-progress-hud-button-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(#cond
(PC_PORT
(unless (and *pc-settings* (not (-> *pc-settings* use-vis?)))
(set! (-> arg2 vector 0 w) (/ 6553.6 (-> *progress-process* 0 sides-x-scale)))
(set! (-> arg2 vector 1 w) (/ 6553.6 (-> *progress-process* 0 sides-x-scale)))
)
)
(#t
(set! (-> arg2 vector 0 w) (/ 6553.6 (-> *progress-process* 0 sides-x-scale)))
(set! (-> arg2 vector 1 w) (/ 6553.6 (-> *progress-process* 0 sides-x-scale)))
)
)
(none)
)
(defun part-progress-hud-tint-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(set! (-> arg2 vector 2 w) (the float (- 64 (sar (* 63 (-> *progress-process* 0 in-out-position)) 12))))
(#when PC_PORT
(if (and *pc-settings* (not (-> *pc-settings* use-vis?)))
(set! (-> arg2 vector 0 w) (* (meters 15) (-> *pc-settings* aspect-ratio-scale)))
)
)
(none)
)
(defun part-progress-card-slot-01-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(set! (-> arg2 vector 2 w) (if (zero? (-> *progress-process* 0 option-index))
64.0
32.0
)
)
(set! (-> arg2 vector 1 w) (-> *progress-process* 0 slot-scale))
0
(none)
)
(defun part-progress-card-slot-02-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(set! (-> arg2 vector 2 w) (if (= (-> *progress-process* 0 option-index) 1)
64.0
32.0
)
)
(set! (-> arg2 vector 1 w) (-> *progress-process* 0 slot-scale))
0
(none)
)
(defun part-progress-card-slot-03-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(set! (-> arg2 vector 2 w) (if (= (-> *progress-process* 0 option-index) 2)
64.0
32.0
)
)
(set! (-> arg2 vector 1 w) (-> *progress-process* 0 slot-scale))
0
(none)
)
(defun part-progress-card-slot-04-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(set! (-> arg2 vector 2 w) (if (= (-> *progress-process* 0 option-index) 3)
64.0
32.0
)
)
(set! (-> arg2 vector 1 w) (-> *progress-process* 0 slot-scale))
0
(none)
)
(defun part-progress-card-cell-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(let ((f0-1 (* 2.0 (+ -0.5 (-> *progress-process* 0 transition-percentage-invert)))))
(if (< f0-1 0.0)
(set! f0-1 0.0)
)
(set! (-> arg2 vector 2 w) (* 128.0 f0-1))
)
0
(none)
)
(defun part-progress-save-icon-func ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(let ((f0-1 (* 6144.0 (-> *progress-process* 0 transition-percentage-invert))))
(set! (-> arg2 vector 0 w) f0-1)
(set! (-> arg2 vector 1 w) f0-1)
)
0
(none)
)
(defun fuel-cell-progress-hud-orbit-callback ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 matrix))
(let* ((a0-1 (-> arg1 key))
(s5-0 (the-as progress (-> a0-1 proc)))
(v1-0 (the int (the-as float (-> arg1 user-float))))
(s4-0 -1)
)
(let ((a1-1 0))
(dotimes (a2-1 (-> *progress-process* 0 nb-of-particles))
(if (= (-> a0-1 matrix) (-> s5-0 particles a1-1 part matrix))
(set! s4-0 a1-1)
)
(+! a1-1 1)
)
)
(cond
((= v1-0 3)
(if (= (-> s5-0 particle-state s4-0) 1)
(set! (-> arg2 vector 2 w) 42.0)
(set! (-> arg2 vector 2 w) 128.0)
)
0
)
(else
(let ((s3-0 (new 'stack-no-clear 'vector))
(s2-0 (new 'stack-no-clear 'vector))
)
(cond
((or (= s4-0 -1) (= (-> s5-0 particle-state s4-0) 2) (= (-> s5-0 particle-state s4-0) 1))
(set! (-> arg2 vector 0 x) 245760.0)
)
((= v1-0 -1)
(set! (-> arg2 vector 0 x) 0.0)
(set! (-> arg2 vector 0 y) 0.0)
)
(else
(vector<-cspace! s3-0 (-> s5-0 icons (logand s4-0 3) icon 0 node-list data v1-0))
(vector<-cspace! s2-0 (-> s5-0 icons (logand s4-0 3) icon 0 node-list data 3))
(vector-! s3-0 s3-0 s2-0)
(#when PC_PORT
(when (not (-> *pc-settings* use-vis?))
(*! (-> s3-0 x) (-> *video-parms* relative-x-scale))
)
)
(set! (-> arg2 vector 0 x) (* 48.0 (-> s3-0 x)))
(set! (-> arg2 vector 0 y) (* 60.0 (-> s3-0 y)))
(set! (-> arg2 vector 0 z) (* 32.0 (-> s3-0 z)))
)
)
)
0
)
)
)
0
(none)
)
(defpartgroup group-part-progress-hud-previous
:id 85
:flags (use-local-clock screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 332 :flags (launch-asap)))
)
(defpartgroup group-part-progress-hud-next
:id 86
:flags (use-local-clock screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 333 :flags (launch-asap)))
)
(defpartgroup group-part-progress-hud-selector
:id 87
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 334 :flags (launch-asap)))
)
(defpartgroup group-part-progress-hud-left
:id 88
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 335 :flags (launch-asap)))
)
(defpartgroup group-part-progress-hud-right
:id 89
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 336 :flags (launch-asap)))
)
(defpartgroup group-part-progress-hud-tint
:id 90
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 337 :flags (launch-asap)))
)
(defpartgroup group-part-progress-card-cell
:id 91
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 2190 :flags (launch-asap)) (sp-item 2191 :flags (launch-asap)) (sp-item 2192 :flags (launch-asap)))
)
(defpartgroup group-part-progress-button-x
:id 570
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 2336 :flags (launch-asap)))
)
(defpartgroup group-part-progress-button-square
:id 571
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 2337 :flags (launch-asap)))
)
(defpartgroup group-part-progress-button-triangle
:id 572
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 2338 :flags (launch-asap)))
)
(defpartgroup group-part-progress-button-circle
:id 573
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 2339 :flags (launch-asap)))
)
(defpartgroup group-part-progress-card-slot-01
:id 92
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 2142 :flags (launch-asap)))
)
(defpartgroup group-part-progress-card-slot-02
:id 93
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 2143 :flags (launch-asap)))
)
(defpartgroup group-part-progress-card-slot-03
:id 94
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 2144 :flags (launch-asap)))
)
(defpartgroup group-part-progress-card-slot-04
:id 95
:flags (screen-space)
:bounds (static-bspherem 0 0 0 1)
:parts
((sp-item 2145 :flags (launch-asap)))
)
(defpartgroup group-part-progress-hud-power-cell-center
:id 96
:flags (screen-space)
:bounds (static-bspherem 0 0 0 100)
:parts
((sp-item 338 :flags (launch-asap)))
)
(defpart 337
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x36 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 15))
(sp-flt spt-scale-y (meters 11.5))
(sp-flt spt-r 128.0)
(sp-flt spt-g 32.0)
(sp-flt spt-b 0.0)
(sp-flt spt-a 64.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
(sp-func spt-func 'part-progress-hud-tint-func)
)
)
(defpart 2190
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x6e :page #x1cf))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 0.8))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-func spt-func 'part-progress-card-cell-func)
)
)
(defpart 2191
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x6d :page #x1cf))
(sp-flt spt-num 1.0)
(sp-flt spt-x (meters 1.05))
(sp-flt spt-scale-x (meters 0.8))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-func spt-func 'part-progress-card-cell-func)
)
)
(defpart 2192
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x6c :page #x1cf))
(sp-flt spt-num 1.0)
(sp-flt spt-x (meters 2.3))
(sp-flt spt-scale-x (meters 0.8))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-func spt-func 'part-progress-card-cell-func)
)
)
(defpart 2336
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x5 :page #x408))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1.6))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
(sp-func spt-func 'part-progress-hud-button-func)
)
)
(defpart 2337
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x6 :page #x408))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1.6))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
(sp-func spt-func 'part-progress-hud-button-func)
)
)
(defpart 2338
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x7 :page #x408))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1.6))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
(sp-func spt-func 'part-progress-hud-button-func)
)
)
(defpart 2339
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x8 :page #x408))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1.6))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
(sp-func spt-func 'part-progress-hud-button-func)
)
)
(defpart 2142
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x36 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 9.2))
(sp-flt spt-scale-y (meters 2))
(sp-flt spt-r 0.0)
(sp-flt spt-g 0.0)
(sp-flt spt-b 0.0)
(sp-flt spt-a 64.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-func spt-func 'part-progress-card-slot-01-func)
)
)
(defpart 2143
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x36 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 9.2))
(sp-flt spt-scale-y (meters 2))
(sp-flt spt-r 0.0)
(sp-flt spt-g 0.0)
(sp-flt spt-b 0.0)
(sp-flt spt-a 64.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-func spt-func 'part-progress-card-slot-02-func)
)
)
(defpart 2144
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x36 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 9.2))
(sp-flt spt-scale-y (meters 2))
(sp-flt spt-r 0.0)
(sp-flt spt-g 0.0)
(sp-flt spt-b 0.0)
(sp-flt spt-a 64.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-func spt-func 'part-progress-card-slot-03-func)
)
)
(defpart 2145
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x36 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 9.2))
(sp-flt spt-scale-y (meters 2))
(sp-flt spt-r 0.0)
(sp-flt spt-g 0.0)
(sp-flt spt-b 0.0)
(sp-flt spt-a 64.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-func spt-func 'part-progress-card-slot-04-func)
)
)
(defpart 332
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x2 :page #x408))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1.2))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
)
)
(defpart 333
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x1 :page #x408))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1.2))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
)
)
(defpart 334
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x4 :page #x408))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1.8))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
)
)
(defpart 335
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :page #x408))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 3.5))
(sp-flt spt-scale-y (meters 13))
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
(sp-func spt-func 'part-progress-hud-left-func)
)
)
(defpart 336
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x3 :page #x408))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 6))
(sp-flt spt-scale-y (meters 13))
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
(sp-func spt-func 'part-progress-hud-right-func)
)
)
(defpart 339
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x31 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 0.3))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-flt spt-userdata 4.0)
(sp-func spt-func 'fuel-cell-progress-hud-orbit-callback)
)
)
(defpart 340
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x31 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 0.3))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-flt spt-userdata 5.0)
(sp-func spt-func 'fuel-cell-progress-hud-orbit-callback)
)
)
(defpart 341
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x31 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 0.3))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-flt spt-userdata 6.0)
(sp-func spt-func 'fuel-cell-progress-hud-orbit-callback)
)
)
(defpart 342
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x31 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 0.3))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-flt spt-userdata 7.0)
(sp-func spt-func 'fuel-cell-progress-hud-orbit-callback)
)
)
(defpart 343
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x31 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 0.2))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
(sp-flt spt-userdata 9.0)
(sp-func spt-func 'fuel-cell-progress-hud-orbit-callback)
)
)
(defpart 338
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x30 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1.2))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
(sp-flt spt-userdata 3.0)
(sp-func spt-func 'fuel-cell-progress-hud-orbit-callback)
)
)
(defpart 344
:init-specs
((sp-flt spt-fade-a -0.53333336))
)
(defpart 345
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x2 :page #x2))
(sp-flt spt-num 0.5)
(sp-flt spt-z (meters 0.52734375))
(sp-flt spt-scale-x (meters 0.25))
(sp-int spt-rot-x 4)
(sp-rnd-flt spt-rot-z (degrees 0.0) (degrees 360.0) 1.0)
(sp-rnd-flt spt-scale-y (meters 0.07) (meters 0.46) 1.0)
(sp-rnd-int spt-r 0 1 255.0)
(sp-rnd-int spt-g 0 1 255.0)
(sp-rnd-int spt-b 0 1 255.0)
(sp-flt spt-a 0.0)
(sp-flt spt-scalevel-x (meters 0.009765625))
(sp-rnd-flt spt-rotvel-z (degrees -0.15) (degrees 0.3) 1.0)
(sp-flt spt-scalevel-y (meters 0.009765625))
(sp-flt spt-fade-a 0.35555556)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit3 bit9 bit13)
(sp-flt spt-userdata -1.0)
(sp-func spt-func 'fuel-cell-progress-hud-orbit-callback)
(sp-int spt-next-time 90)
(sp-launcher-by-id spt-next-launcher 232)
)
)
(defpart 346
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x2 :page #x2))
(sp-flt spt-num 0.06)
(sp-flt spt-z (meters 0.52734375))
(sp-rnd-flt spt-scale-x (meters 1) (meters 0.25) 1.0)
(sp-int spt-rot-x 4)
(sp-rnd-flt spt-rot-z (degrees 0.0) (degrees 360.0) 1.0)
(sp-flt spt-scale-y (meters 0.1))
(sp-rnd-int spt-r 0 1 255.0)
(sp-rnd-int spt-g 0 1 255.0)
(sp-rnd-int spt-b 0 1 255.0)
(sp-flt spt-a 0.0)
(sp-flt spt-scalevel-x (meters 0.009765625))
(sp-rnd-flt spt-rotvel-z (degrees -0.15) (degrees 0.3) 1.0)
(sp-flt spt-fade-a 0.32)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit3 bit9 bit13)
(sp-flt spt-userdata -1.0)
(sp-func spt-func 'fuel-cell-progress-hud-orbit-callback)
(sp-int spt-next-time 75)
(sp-launcher-by-id spt-next-launcher 232)
)
)
(defpart 347
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x12 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-z (meters 0.52734375))
(sp-flt spt-scale-x (meters 2))
(sp-rnd-flt spt-rot-z (degrees 0.0) (degrees 360.0) 1.0)
(sp-flt spt-scale-y (meters 1.8))
(sp-flt spt-r 192.0)
(sp-flt spt-g 192.0)
(sp-rnd-flt spt-b 0.0 128.0 1.0)
(sp-flt spt-a 64.0)
(sp-flt spt-rotvel-z (degrees -0.4))
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit3 bit9 bit13)
(sp-flt spt-userdata -1.0)
(sp-func spt-func 'fuel-cell-progress-hud-orbit-callback)
)
)
(defpart 348
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x12 :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-z (meters 0.52734375))
(sp-flt spt-scale-x (meters 2.4))
(sp-rnd-flt spt-rot-z (degrees 0.0) (degrees 360.0) 1.0)
(sp-flt spt-scale-y (meters 2))
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 64.0)
(sp-flt spt-rotvel-z (degrees 0.3))
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit3 bit9 bit13)
(sp-flt spt-userdata -1.0)
(sp-func spt-func 'fuel-cell-progress-hud-orbit-callback)
)
)
(defpartgroup group-part-progress-hud-power-cell-whole
:id 97
:flags (use-local-clock screen-space)
:bounds (static-bspherem 0 0 0 100)
:parts
((sp-item 338 :flags (launch-asap))
(sp-item 347 :flags (launch-asap) :period 3600 :length 5)
(sp-item 348 :flags (launch-asap) :period 3600 :length 5)
(sp-item 343 :flags (launch-asap))
(sp-item 339 :flags (launch-asap))
(sp-item 340 :flags (launch-asap))
(sp-item 341 :flags (launch-asap))
(sp-item 342 :flags (launch-asap))
)
)
(defpartgroup group-part-progress-buzzer
:id 98
:flags (screen-space)
:bounds (static-bspherem 0 0 0 100)
:parts
((sp-item 1982 :flags (launch-asap) :binding 1981) (sp-item 1981 :flags (start-dead launch-asap)))
)
(defpart 1982
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x2a :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 2.2))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 0.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
)
)
(defpart 1981
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x2a :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-x (meters 0))
(sp-flt spt-y (meters 1.3333334))
(sp-flt spt-z (meters 0.1))
(sp-flt spt-scale-x (meters 2))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-flt spt-omega 0.0)
(sp-flt spt-vel-x (meters 0.053333335))
(sp-flt spt-vel-z (meters 0))
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit7 bit9 bit13)
)
)
(defpartgroup group-part-progress-orb
:id 99
:flags (screen-space)
:bounds (static-bspherem 0 0 0 100)
:parts
((sp-item 1983 :flags (launch-asap)))
)
(defpart 1983
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x2c :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 2.2))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
)
)
(defpartgroup group-part-progress-buzzer-small
:id 100
:flags (screen-space)
:bounds (static-bspherem 0 0 0 100)
:parts
((sp-item 1985 :flags (launch-asap) :binding 1984) (sp-item 1984 :flags (start-dead launch-asap)))
)
(defpart 1985
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x2a :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 0.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit9 bit13)
)
)
(defpart 1984
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x2a :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-x (meters 0))
(sp-flt spt-y (meters 1.3333334))
(sp-flt spt-z (meters 0.05))
(sp-flt spt-scale-x (meters 1.5))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-flt spt-omega 0.0)
(sp-flt spt-vel-x (meters 0.05037037))
(sp-flt spt-vel-z (meters 0))
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit7 bit9 bit13)
(sp-func spt-func 'part-progress-hud-buzzer-func)
)
)
(defpartgroup group-part-progress-orb-small
:id 101
:flags (screen-space)
:bounds (static-bspherem 0 0 0 100)
:parts
((sp-item 1986 :flags (launch-asap)))
)
(defpart 1986
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x2c :page #x2))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1.3))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
(sp-func spt-func 'part-progress-hud-orb-func)
)
)
(defpartgroup group-part-progress-save-icon
:id 615
:flags (screen-space)
:bounds (static-bspherem 0 0 0 100)
:parts
((sp-item 2478 :flags (launch-asap)))
)
(defpart 2478
:init-specs
((sp-tex spt-texture (new 'static 'texture-id :index #x6b :page #x1cf))
(sp-flt spt-num 1.0)
(sp-flt spt-scale-x (meters 1.8))
(sp-copy-from-other spt-scale-y -4)
(sp-flt spt-r 128.0)
(sp-flt spt-g 128.0)
(sp-flt spt-b 128.0)
(sp-flt spt-a 128.0)
(sp-int spt-timer -1)
(sp-cpuinfo-flags bit2 bit9 bit13)
(sp-func spt-func 'part-progress-save-icon-func)
)
)
(defmacro progress-new-particle (&key part &key x &key y &key z)
`(when (< (-> obj nb-of-particles) (-> obj max-nb-of-particles))
(let ((part-nb (-> obj nb-of-particles)))
(set! (-> obj particles part-nb) (new 'static 'hud-particle))
(set! (-> obj particles part-nb part) (create-launch-control (-> *part-group-id-table* ,part) obj))
(set! (-> obj particles part-nb init-pos x) ,x)
(set! (-> obj particles part-nb init-pos y) ,y)
(set! (-> obj particles part-nb init-pos z) ,z)
(set! (-> obj particles part-nb part matrix) -1)
)
(+! (-> obj nb-of-particles) 1)
)
)
(defmethod initialize-particles progress ((obj progress))
(progress-new-particle :part 90 :x 256.0 :y 224.0 :z 16.0) ;; tint
(progress-new-particle :part 88 :x -42.0 :y (#if PC_PORT 256.0 254.0) :z 5.0) ;; left
(progress-new-particle :part 89 :x 610.0 :y (#if PC_PORT 256.0 254.0) :z 5.0) ;; right
(progress-new-particle :part 85 :x -320.0 :y 40.0 :z 14.0) ;; prev
(progress-new-particle :part 86 :x -320.0 :y 400.0 :z 14.0) ;; next
(progress-new-particle :part 87 :x -320.0 :y 194.0 :z 15.0)
(progress-new-particle :part 97 :x -320.0 :y 194.0 :z 14.0)
(progress-new-particle :part 97 :x -320.0 :y 194.0 :z 14.0)
(progress-new-particle :part 97 :x -320.0 :y 194.0 :z 14.0)
(progress-new-particle :part 97 :x -320.0 :y 194.0 :z 14.0)
(progress-new-particle :part 97 :x -320.0 :y 194.0 :z 14.0)
(progress-new-particle :part 97 :x -320.0 :y 194.0 :z 14.0)
(progress-new-particle :part 97 :x -320.0 :y 194.0 :z 14.0)
(progress-new-particle :part 97 :x -320.0 :y 194.0 :z 14.0)
(progress-new-particle :part 98 :x -320.0 :y 224.0 :z 14.0)
(progress-new-particle :part 99 :x -320.0 :y 224.0 :z 14.0)
(progress-new-particle :part 97 :x -320.0 :y 112.0 :z 4.0)
(progress-new-particle :part 100 :x -320.0 :y 193.0 :z 4.0)
(progress-new-particle :part 101 :x -320.0 :y 40.0 :z 4.0)
(progress-new-particle :part 92 :x -320.0 :y 90.0 :z 16.0)
(progress-new-particle :part 93 :x -320.0 :y 172.0 :z 16.0)
(progress-new-particle :part 94 :x -320.0 :y 254.0 :z 16.0)
(progress-new-particle :part 95 :x -320.0 :y 336.0 :z 16.0)
(progress-new-particle :part 91 :x -320.0 :y 102.0 :z 13.0)
(progress-new-particle :part 91 :x -320.0 :y 184.0 :z 13.0)
(progress-new-particle :part 91 :x -320.0 :y 266.0 :z 13.0)
(progress-new-particle :part 91 :x -320.0 :y 348.0 :z 13.0)
(progress-new-particle :part 570 :x -320.0 :y 338.0 :z 4.0)
(progress-new-particle :part 571 :x -320.0 :y 338.0 :z 4.0)
(progress-new-particle :part 572 :x -320.0 :y 338.0 :z 4.0)
(progress-new-particle :part 573 :x -320.0 :y 338.0 :z 4.0)
(progress-new-particle :part 615 :x -320.0 :y 180.0 :z 4.0)
(#when PC_PORT
(progress-new-particle :part 85 :x -320.0 :y 32.0 :z 14.0) ;; prev
(progress-new-particle :part 86 :x -320.0 :y 412.0 :z 14.0) ;; next
)
0
(none)
)