Files
jak-project/goal_src/jakx/levels/common/menu2-part.gc
T
2026-06-15 09:56:10 -04:00

343 lines
11 KiB
Common Lisp

;;-*-Lisp-*-
(in-package goal)
;; name: menu2-part.gc
;; name in dgo: menu2-part
;; dgos: COMMON, GAME
(define-extern *range-jakxexplo-color* curve-color-fast)
(define-extern *range-jakxexplo-alpha* curve2d-fast)
(define-extern *range-jakxexplo-scale-x* curve2d-fast)
(define-extern *range-jakxexplo-scale-y* curve2d-fast)
(define-extern *curve-jakxexplo-alpha* curve2d-fast)
(define-extern *curve-jakxexplo-scale-x* curve2d-fast)
(define-extern *curve-jakxexplo-scale-y* curve2d-fast)
(define-extern *part-jakx-explosion-texture-curve-settings* particle-curve-settings)
;; DECOMP BEGINS
(defpartgroup group-jakx-fire
:id 53
:flags (sp0 sp4 sp13)
:bounds (static-bspherem 0 0 0 2)
:parts ((sp-item 333 :flags (sp6)))
)
(defpart 333
:init-specs ((:texture (new 'static 'texture-id :index #x78 :page #x4))
(:num 1.0)
(:scale-x (meters 1))
(:rot-z (degrees 0) (degrees 360))
(:scale-y :copy scale-x)
(:r 80.0)
(:g 80.0)
(:b 80.0)
(:a 64.0)
(:fade-a -2.56)
(:timer (seconds 0.085))
(:flags ())
(:rotate-y (degrees 0))
)
)
(defpartgroup group-jakx-fire-thin
:id 54
:flags (sp0 sp4 sp13)
:bounds (static-bspherem 0 0 0 2)
:parts ((sp-item 334 :flags (sp6)))
)
(defpart 334
:init-specs ((:texture (new 'static 'texture-id :index #x17 :page #x4))
(:num 1.0)
(:scale-x (meters 0.2))
(:rot-z (degrees 0) (degrees 360))
(:scale-y :copy scale-x)
(:r 80.0)
(:g 80.0)
(:b 80.0)
(:a 64.0)
(:fade-a -4.266667)
(:timer (seconds 0.05))
(:flags (sp-cpuinfo-flag-3))
(:rotate-y (degrees 0))
)
)
(defpartgroup group-jakx-huge-explosion
:id 55
:duration (seconds 5)
:flags (sp0 sp5)
:bounds (static-bspherem 0 0 0 15)
:parts ((sp-item 335 :period (seconds 30) :length (seconds 0.5))
(sp-item 336 :flags (sp3) :period (seconds 30) :length (seconds 0.017))
(sp-item 337 :period (seconds 30) :length (seconds 0.035))
(sp-item 338 :period (seconds 30) :length (seconds 0.035))
(sp-item 339 :flags (sp3) :period (seconds 30) :length (seconds 0.017))
(sp-item 340 :period (seconds 30) :length (seconds 0.667))
)
)
(defpart 336
:init-specs ((:texture (new 'static 'texture-id :index #x17 :page #x4))
(:num 1.0)
(:scale-x (meters 10))
(:rot-x (degrees 22.5))
(:scale-y :copy scale-x)
(:r 255.0)
(:g 128.0)
(:b 40.0)
(:a 64.0)
(:fade-a -0.21333334)
(:timer (seconds 1))
(:flags (sp-cpuinfo-flag-2 sp-cpuinfo-flag-3 use-global-acc))
(:userdata 4096.0)
)
)
(defpart 339
:init-specs ((:texture (new 'static 'texture-id :index #x8c :page #x4))
(:num 1.0)
(:scale-x (meters 6))
(:rot-x (degrees 2.25))
(:rot-z (degrees 0) (degrees 360))
(:scale-y :copy scale-x)
(:r 128.0)
(:g 128.0)
(:b 128.0)
(:a 128.0)
(:omega (degrees 6767.9995))
(:scalevel-x (meters -0.083333336))
(:scalevel-y :copy scalevel-x)
(:timer (seconds 0.267))
(:flags (sp-cpuinfo-flag-0 sp-cpuinfo-flag-3 use-global-acc))
(:userdata 4096.0)
)
)
(defpart 335
:init-specs ((:texture (new 'static 'texture-id :index #x10 :page #x4))
(:num 3.0)
(:x (meters 0.2))
(:scale-x (meters 0.7) (meters 0.3))
(:rot-z (degrees 0) (degrees 360))
(:scale-y :copy scale-x)
(:r 128.0)
(:g 60.0 20.0)
(:b 10.0 10.0)
(:a 128.0)
(:vel-y (meters 0.01) (meters 0.01))
(:scalevel-x (meters 0.00066666666))
(:scalevel-y :copy scalevel-x)
(:fade-a -0.42666668)
(:friction 0.9)
(:timer (seconds 1))
(:flags (sp-cpuinfo-flag-0 sp-cpuinfo-flag-3))
(:conerot-x (degrees 0) (degrees 360))
(:rotate-y (degrees 0))
)
)
(defpart 337
:init-specs ((:texture (new 'static 'texture-id :index #x16 :page #x4))
(:num 100.0)
(:scale-x (meters 0.2))
(:scale-y :copy scale-x)
(:r 128.0)
(:g 128.0)
(:b 128.0)
(:a 128.0)
(:omega (degrees 0.1575))
(:vel-y (meters 0.006666667) (meters 0.026666667))
(:scalevel-x (meters -0.001))
(:scalevel-y :copy scalevel-x)
(:fade-g -0.28444445 -0.28444445)
(:fade-b -0.42666668)
(:fade-a -0.14222223 -0.14222223)
(:friction 0.92 0.02)
(:timer (seconds 3))
(:flags (sp-cpuinfo-flag-0 sp-cpuinfo-flag-3))
(:func 'sparticle-motion-blur)
(:conerot-x (degrees 0) (degrees 360))
(:rotate-y (degrees 0) (degrees 3600))
)
)
(defpart 338
:init-specs ((:texture (new 'static 'texture-id :index #xaa :page #x4))
(:num 40.0)
(:scale-x (meters 0.1) (meters 0.1))
(:rot-z (degrees 0) (degrees 360))
(:scale-y :copy scale-x)
(:r 128.0)
(:g 128.0)
(:b 128.0)
(:a 128.0)
(:vel-y (meters 0.006666667) (meters 0.026666667))
(:scalevel-x (meters -0.00033333333))
(:scalevel-y :copy scalevel-x)
(:fade-g -0.13333334)
(:fade-b -0.05)
(:fade-a -0.21333334 -0.21333334)
(:friction 0.96)
(:timer (seconds 2))
(:flags (sp-cpuinfo-flag-0 sp-cpuinfo-flag-3))
(:conerot-x (degrees 0) (degrees 360))
(:rotate-y (degrees 0) (degrees 3600))
)
)
(defpart 341
:init-specs ((:texture (new 'static 'texture-id :index #x10 :page #x4))
(:num 10.0)
(:scale-x (meters 6) (meters 4))
(:rot-z (degrees 0) (degrees 360))
(:scale-y :copy scale-x)
(:r 255.0)
(:g 160.0)
(:b 40.0)
(:a 128.0)
(:vel-y (meters 0.033333335) (meters 0.16666667))
(:scalevel-x (meters 0.033333335))
(:scalevel-y :copy scalevel-x)
(:fade-g -0.114285715)
(:fade-b -0.042857144)
(:fade-a -0.18285714 -0.18285714)
(:friction 0.93)
(:timer (seconds 2.335))
(:flags (sp-cpuinfo-flag-3))
(:conerot-x (degrees 0) (degrees 360))
(:rotate-y (degrees 0) (degrees 3600))
)
)
(defpart 340
:init-specs ((:texture (new 'static 'texture-id :index #xe :page #x4))
(:birth-func 'birth-func-curve)
(:num 4.0)
(:x (meters 0.2))
(:y (meters 0) (meters 0.01))
(:scale-x (meters 1))
(:rot-z (degrees 0) (degrees 360))
(:scale-y :copy scale-x)
(:r 128.0)
(:g 128.0)
(:b 128.0)
(:a 128.0)
(:vel-y (meters 0.00066666666) (meters 0.006666667))
(:friction 0.95)
(:timer (seconds 1))
(:flags ())
(:userdata 0.0)
(:func 'live-func-curve)
(:conerot-x (degrees 0) (degrees 360))
(:rotate-y (degrees 0))
)
)
(if #t
(set! *range-jakxexplo-color*
(new 'static 'curve-color-fast
:xs (new 'static 'vector :data (new 'static 'array float 4 0.0 -1.0 -2.0 -3.0))
:ys (new 'static 'inline-array vector 4
(new 'static 'vector :data (new 'static 'array float 4 255.0 255.0 255.0 128.0))
(new 'static 'vector :data (new 'static 'array float 4 255.0 255.0 255.0 128.0))
(new 'static 'vector :data (new 'static 'array float 4 255.0 255.0 255.0 128.0))
(new 'static 'vector :data (new 'static 'array float 4 255.0 255.0 255.0 128.0))
)
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 1.0 1.0 1.0 1.0))
)
)
)
(if #t
(set! *range-jakxexplo-alpha*
(new 'static 'curve2d-fast
:xs (new 'static 'vector :data (new 'static 'array float 4 0.0 -1.0 -2.0 -3.0))
:ys (new 'static 'vector :data (new 'static 'array float 4 128.0 128.0 129.0 130.0))
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 0.0 1.0 1.0 1.0))
)
)
)
(if #t
(set! *range-jakxexplo-scale-x*
(new 'static 'curve2d-fast
:xs (new 'static 'vector :data (new 'static 'array float 4 0.0 -1.0 -2.0 -3.0))
:ys (new 'static 'vector :data (new 'static 'array float 4 1.0 1.2 2.2 3.2))
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 0.20000005 1.0 1.0 1.0))
)
)
)
(if #t
(set! *range-jakxexplo-scale-y*
(new 'static 'curve2d-fast
:xs (new 'static 'vector :data (new 'static 'array float 4 0.0 -1.0 -2.0 -3.0))
:ys (new 'static 'vector :data (new 'static 'array float 4 1.0 1.2 2.2 3.2))
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 0.20000005 1.0 1.0 1.0))
)
)
)
(if #t
(set! *curve-jakxexplo-alpha*
(new 'static 'curve2d-fast
:xs (new 'static 'vector :data (new 'static 'array float 4 0.0 -0.05 -0.7 -1.0))
:ys (new 'static 'vector :data (new 'static 'array float 4 0.0 1.0 0.6 0.0))
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 20.0 -0.6153846 -2.0 1.0))
)
)
)
(if #t
(set! *curve-jakxexplo-scale-x*
(new 'static 'curve2d-fast
:xs (new 'static 'vector :data (new 'static 'array float 4 0.0 -0.8 -1.0 -2.0))
:ys (new 'static 'vector :data (new 'static 'array float 4 0.5 1.0 1.1 2.1))
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 0.625 0.5000002 0.9999999 1.0))
)
)
)
(if #t
(set! *curve-jakxexplo-scale-y*
(new 'static 'curve2d-fast
:xs (new 'static 'vector :data (new 'static 'array float 4 0.0 -0.8 -1.0 -2.0))
:ys (new 'static 'vector :data (new 'static 'array float 4 0.5 1.0 1.1 2.1))
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 0.625 0.5000002 0.9999999 1.0))
)
)
)
(define *part-jakx-explosion-texture-curve-settings* (new 'static 'particle-curve-settings
:lifetime-base (seconds 0.7)
:lifetime-offset (seconds 0.2)
:flags (particle-curve-flags pcf0)
)
)
(set! (-> *part-id-table* 340 init-specs 16 initial-valuef)
(the-as float *part-jakx-explosion-texture-curve-settings*)
)
(set! (-> *part-jakx-explosion-texture-curve-settings* color-start) *range-jakxexplo-color*)
(set! (-> *part-jakx-explosion-texture-curve-settings* alpha-start) *range-jakxexplo-alpha*)
(set! (-> *part-jakx-explosion-texture-curve-settings* scale-x-start) *range-jakxexplo-scale-x*)
(set! (-> *part-jakx-explosion-texture-curve-settings* scale-y-start) *range-jakxexplo-scale-y*)
(set! (-> *part-jakx-explosion-texture-curve-settings* r-scalar) #f)
(set! (-> *part-jakx-explosion-texture-curve-settings* g-scalar) #f)
(set! (-> *part-jakx-explosion-texture-curve-settings* b-scalar) #f)
(set! (-> *part-jakx-explosion-texture-curve-settings* a-scalar) *curve-jakxexplo-alpha*)
(set! (-> *part-jakx-explosion-texture-curve-settings* scale-x-scalar) *curve-jakxexplo-scale-x*)
(set! (-> *part-jakx-explosion-texture-curve-settings* scale-y-scalar) *curve-jakxexplo-scale-y*)