Files
jak-project/test/decompiler/reference/jakx/engine/common-obs/particle-curves_REF.gc
T
2026-06-15 09:56:10 -04:00

198 lines
7.5 KiB
Common Lisp
Vendored
Generated

;;-*-Lisp-*-
(in-package goal)
;; definition of type particle-curve-settings
(deftype particle-curve-settings (structure)
((color-start basic)
(alpha-start basic)
(scale-x-start basic)
(scale-y-start basic)
(r-scalar basic)
(g-scalar basic)
(b-scalar basic)
(a-scalar basic)
(scale-x-scalar basic)
(scale-y-scalar basic)
(lifetime-base time-frame)
(lifetime-offset time-frame)
(flags particle-curve-flags)
)
)
;; definition for method 3 of type particle-curve-settings
(defmethod inspect ((this particle-curve-settings))
(when (not this)
(set! this this)
(goto cfg-4)
)
(format #t "[~8x] ~A~%" this 'particle-curve-settings)
(format #t "~1Tcolor-start: ~A~%" (-> this color-start))
(format #t "~1Talpha-start: ~A~%" (-> this alpha-start))
(format #t "~1Tscale-x-start: ~A~%" (-> this scale-x-start))
(format #t "~1Tscale-y-start: ~A~%" (-> this scale-y-start))
(format #t "~1Tr-scalar: ~A~%" (-> this r-scalar))
(format #t "~1Tg-scalar: ~A~%" (-> this g-scalar))
(format #t "~1Tb-scalar: ~A~%" (-> this b-scalar))
(format #t "~1Ta-scalar: ~A~%" (-> this a-scalar))
(format #t "~1Tscale-x-scalar: ~A~%" (-> this scale-x-scalar))
(format #t "~1Tscale-y-scalar: ~A~%" (-> this scale-y-scalar))
(format #t "~1Tlifetime-base: ~D~%" (-> this lifetime-base))
(format #t "~1Tlifetime-offset: ~D~%" (-> this lifetime-offset))
(format #t "~1Tflags: ~D~%" (-> this flags))
(label cfg-4)
this
)
;; definition for function birth-func-curve
;; INFO: function output is handled by mips2c
(def-mips2c birth-func-curve (function int sparticle-cpuinfo sparticle-launchinfo none))
;; definition for function live-func-curve
;; INFO: function output is handled by mips2c
(def-mips2c live-func-curve (function sparticle-system sparticle-cpuinfo vector none))
;; failed to figure out what this is:
(defpart 45
:init-specs ((:texture (common-white common))
(:birth-func 'birth-func-curve)
(:num 1.0)
(:scale-x (meters 1))
(:scale-y :copy scale-x)
(:r 128.0)
(:g 128.0)
(:b 128.0)
(:a 128.0)
(:vel-y (meters 0.01))
(:timer (seconds 16.667))
(:flags ())
(:userdata 0.0)
(:func 'live-func-curve)
(:conerot-x (degrees -30) (degrees 60))
(:conerot-z (degrees -30) (degrees 60))
(:rotate-y (degrees 0) (degrees 3600))
)
)
;; failed to figure out what this is:
(if #t
(set! *alpha-fast* (new 'static 'curve2d-fast
:xs (new 'static 'vector :data (new 'static 'array float 4 0.0 -0.25 -0.5 -1.0))
:ys (new 'static 'vector :data (new 'static 'array float 4 1.0 0.75 0.5 0.0))
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 -1.0 -1.0 -1.0 1.0))
)
)
)
;; failed to figure out what this is:
(if #t
(set! *unity-fast* (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.0 2.0 3.0))
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 0.0 1.0 1.0 1.0))
)
)
)
;; failed to figure out what this is:
(if #t
(set! *ccro* (new 'static 'curve-color-fast
:xs (new 'static 'vector :data (new 'static 'array float 4 0.0 -0.4 -0.7 -1.0))
:ys (new 'static 'inline-array vector 4
(new 'static 'vector :data (new 'static 'array float 4 128.0 0.0 0.0 128.0))
(new 'static 'vector :data (new 'static 'array float 4 128.0 128.0 0.0 128.0))
(new 'static 'vector :data (new 'static 'array float 4 128.0 128.0 128.0 128.0))
(new 'static 'vector :data (new 'static 'array float 4 0.0 128.0 0.0 128.0))
)
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 2.5 3.3333335 3.3333333 1.0))
)
)
)
;; failed to figure out what this is:
(if #t
(set! *scale-curve* (new 'static 'curve2d-fast
:xs (new 'static 'vector :data (new 'static 'array float 4 0.0 -0.3 -0.7 -1.0))
:ys (new 'static 'vector :data (new 'static 'array float 4 1.0 0.1 0.1 6.0))
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 -2.9999998 0.0 19.666666 1.0))
)
)
)
;; failed to figure out what this is:
(if #t
(set! *scale-range* (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 0.3 0.4 1.4 2.4))
:one-over-x-deltas (new 'static 'vector :data (new 'static 'array float 4 0.099999994 1.0 1.0000001 1.0))
)
)
)
;; definition for symbol *part-function-curve-test-curve-settings*, type particle-curve-settings
(define *part-function-curve-test-curve-settings* (new 'static 'particle-curve-settings
:lifetime-base (seconds 1.5)
:lifetime-offset (seconds 1)
:flags (particle-curve-flags pcf0)
)
)
;; failed to figure out what this is:
(set! (-> *part-id-table* 45 init-specs 12 initial-valuef)
(the-as float *part-function-curve-test-curve-settings*)
)
;; failed to figure out what this is:
(set! (-> *part-function-curve-test-curve-settings* color-start) *ccro*)
;; failed to figure out what this is:
(set! (-> *part-function-curve-test-curve-settings* alpha-start) *unity-fast*)
;; failed to figure out what this is:
(set! (-> *part-function-curve-test-curve-settings* scale-x-start) *scale-range*)
;; failed to figure out what this is:
(set! (-> *part-function-curve-test-curve-settings* scale-y-start) #f)
;; failed to figure out what this is:
(set! (-> *part-function-curve-test-curve-settings* r-scalar) #f)
;; failed to figure out what this is:
(set! (-> *part-function-curve-test-curve-settings* g-scalar) #f)
;; failed to figure out what this is:
(set! (-> *part-function-curve-test-curve-settings* b-scalar) #f)
;; failed to figure out what this is:
(set! (-> *part-function-curve-test-curve-settings* a-scalar) *alpha-fast*)
;; failed to figure out what this is:
(set! (-> *part-function-curve-test-curve-settings* scale-x-scalar) *scale-curve*)
;; failed to figure out what this is:
(set! (-> *part-function-curve-test-curve-settings* scale-y-scalar) #f)
;; definition for function ptest
;; INFO: Used lq/sq
;; WARN: Return type mismatch symbol vs none.
(defun ptest ()
(dotimes (gp-0 1000)
(let ((t9-0 sp-launch-particles-var)
(a0-0 *sp-particle-system-2d*)
(a1-0 (-> *part-id-table* 45))
(a2-0 *launch-matrix*)
)
(let ((v1-1 (-> a2-0 trans))
(a3-0 (new 'stack-no-clear 'vector))
)
(set! (-> a3-0 x) 0.0)
(set! (-> a3-0 y) 40960.0)
(set! (-> a3-0 z) 0.0)
(set! (-> a3-0 w) 1.0)
(set! (-> v1-1 quad) (-> a3-0 quad))
)
(t9-0 a0-0 a1-0 a2-0 (the-as sparticle-launch-state #f) (the-as sparticle-launch-control #f) 1.0)
)
)
(none)
)