Skip to main content

sparticle-h

source

Types


sparticle-cpuinfo

sparticle-cpuinfo: structuresource
Fields
sprite: sprite-vec-data-2d
adgif: adgif-shader
radius: float
omega: float
vel-sxvel: vector
rot-syvel: vector
fade: rgbaf
acc: vector
rotvel3d: quaternion
vel: vector3s
accel: vector3s
scalevelx: float
scalevely: float
friction: float
timer: int32
flags: sp-cpuinfo-flag
user-int32: int32
user-uint32: uint32
user-float: float
user-pntr: uint32
user-sprite: sprite-vec-data-2d
func: basic
next-time: uint32
next-launcher: basic
cache-alpha: float
valid: symbol
key: sparticle-launch-control
binding: sparticle-launch-state
data: uint32
dataf: float
datac: uint8

sparticle-launchinfo

sparticle-launchinfo: structuresource
Fields
launchrot: vector
conerot: vector
coneradius: float
rotate-y: float
data: uint8

sparticle-system

sparticle-system: basicsource
Fields
type: type
blocks: int32
length: int32
num-alloc: int32
is-3d: basic
flags: uint32
alloc-table: pointer
cpuinfo-table: inline-array
vecdata-table: pointer
adgifdata-table: inline-array

Variables


*sp-60-hz*

*sp-60-hz*: symbolsource

*sp-frame-time*

*sp-frame-time*: vectorsource

sparticle-launcher-h

source

Types


sp-field-init-spec

sp-field-init-spec: structuresource
Fields
field: sp-field-id
flags: sp-flag
initial-valuef: float
random-rangef: float
random-multf: float
initial-value: int32
random-range: int32
random-mult: int32
func: symbol
tex: texture-id
pntr: pointer
sym: symbol
sound: sound-spec

sparticle-group-item

sparticle-group-item: structuresource
Fields
launcher: uint32
fade-after: meters
falloff-to: meters
flags: sp-group-item-flag
period: uint16
length: uint16
offset: uint16
hour-mask: uint32
binding: uint32

sparticle-launch-control

sparticle-launch-control: inline-array-classsource
Fields
type: type
length: int32
allocated-length: int32
_data: uint8
group: sparticle-launch-group
proc: process
local-clock: int32
fade: float
matrix: int32
last-spawn-frame: int32
last-spawn-time: int32
center: vector
data: sparticle-launch-state
Methods
initialize(obj: sparticle-launch-control, arg0: sparticle-launch-group, arg1: process) => nonesource
start a particle effect.
is-visible?(obj: sparticle-launch-control, arg0: vector) => symbolsource
Is the effect visible?. arg0 is the offset of the effect
spawn(obj: sparticle-launch-control, arg0: vector) => objectsource
kill-and-free-particles(obj: sparticle-launch-control) => nonesource
kill all the particles
kill-particles(obj: sparticle-launch-control) => nonesource
kill the particles, but don't clear flags or free hvdfs.

sparticle-launch-group

sparticle-launch-group: basicsource
Fields
type: type
length: int16
duration: uint16
linger-duration: uint16
flags: sp-group-flag
name: string
launcher: inline-array
bounds: sphere
Methods
create-launch-control(obj: sparticle-launch-group, arg0: process) => sparticle-launch-controlsource
create a launch-control to hold the state of the particles. stored on the process heap.

sparticle-launch-state

sparticle-launch-state: structuresource
Fields
group-item: sparticle-group-item
flags: sp-launch-state-flags
randomize: uint16
origin: vector
sprite3d: sprite-vec-data-3d
sprite: sparticle-cpuinfo
offset: uint32
accum: float
spawn-time: uint32
swarm: basic
seed: uint32
time: uint32
spec: basic
id: uint32

sparticle-launcher

sparticle-launcher: basicsource
Fields
type: type
birthaccum: float
soundaccum: float
init-specs: inline-array

sparticle-launcher

source

Types


particle-adgif-cache

particle-adgif-cache: basicsource
Fields
type: type
used: int32
last: uint16
lastgif: adgif-shader
tidhash: uint16
spadgif: adgif-shader

sp-launch-queue

sp-launch-queue: basicsource
Fields
type: type
in-use: int32
queue: sp-queued-launch-particles

sp-queued-launch-particles

sp-queued-launch-particles: structuresource
Fields
sp-system: sparticle-system
sp-launcher: sparticle-launcher
pos: vector

sparticle-birthinfo

sparticle-birthinfo: structuresource
Fields
sprite: uint32
anim: int32
anim-speed: float
birth-func: basic
joint-ppoint: int32
num-to-birth: float
sound: basic
dataf: float
data: uint32

Functions


birth-func-copy-omega-to-z

birth-func-copy-omega-to-z(arg0: sparticle-system, arg1: sparticle-cpuinfo, arg2: sprite-vec-data-3d, arg3: sparticle-launcher, arg4: sparticle-launch-state) => nonesource

birth-func-copy-rot-color

birth-func-copy-rot-color(arg0: sparticle-system, arg1: sparticle-cpuinfo, arg2: sprite-vec-data-3d, arg3: sparticle-launcher, arg4: sparticle-launch-state) => nonesource

birth-func-copy2-rot-color

birth-func-copy2-rot-color(arg0: sparticle-system, arg1: sparticle-cpuinfo, arg2: sprite-vec-data-3d, arg3: sparticle-launcher, arg4: sparticle-launch-state) => nonesource

birth-func-random-next-time

birth-func-random-next-time(arg0: sparticle-system, arg1: sparticle-cpuinfo, arg2: sprite-vec-data-3d, arg3: sparticle-launcher, arg4: sparticle-launch-state) => nonesource

lookup-part-group-by-name

lookup-part-group-by-name(arg0: string) => basicsource
Find a particle group with the given name. Checks all of them, not very efficient.

lookup-part-group-pointer-by-name

lookup-part-group-pointer-by-name(arg0: string) => pointersource
Get a (pointer sparticle-launch-group) for the given name. Checks all of them, not very efficient.

part-group-pointer?

part-group-pointer?(arg0: pointer) => symbolsource
Is the given pointer a pointer that was returned by lookup-part-group-pointer-by-name?

particle-setup-adgif

particle-setup-adgif(arg0: adgif-shader, arg1: texture-id) => nonesource
Set up the adgif for a particle and the given texture.

sp-adjust-launch

sp-adjust-launch(arg0: sparticle-launchinfo, arg1: sparticle-cpuinfo, arg2: inline-array) => nonesource
Adjust the fields based on the init-specs

sp-clear-queue

sp-clear-queue() => nonesource
Launch all particles in the queue.

sp-euler-convert

sp-euler-convert(arg0: sparticle-launchinfo, arg1: sparticle-cpuinfo) => nonesource
Convert rotations from euler angles to quaternions.

sp-init-fields!

sp-init-fields!(arg0: pointer, arg1: inline-array, arg2: sp-field-id, arg3: sp-field-id, write-missing-fields: symbol) => inline-arraysource

sp-launch-particles-death

sp-launch-particles-death(arg0: sparticle-system, arg1: sparticle-launcher, arg2: vector) => nonesource

sp-queue-launch

sp-queue-launch(arg0: sparticle-system, arg1: sparticle-launcher, arg2: vector) => intsource
Queue a launch from the given launcher, at the given position.

sp-relaunch-particle-2d

sp-relaunch-particle-2d(arg0: object, arg1: sparticle-launcher, arg2: sparticle-cpuinfo, arg3: sprite-vec-data-3d) => nonesource
relaunch a 2d particle

sp-relaunch-particle-3d

sp-relaunch-particle-3d(arg0: object, arg1: sparticle-launcher, arg2: sparticle-cpuinfo, arg3: sprite-vec-data-3d) => nonesource
relaunch a 3d particle

sp-relaunch-setup-fields

sp-relaunch-setup-fields(arg0: object, arg1: sparticle-launcher, arg2: sparticle-cpuinfo, arg3: sprite-vec-data-3d) => nonesource
Reset fields of an existing particle

sp-rotate-system

sp-rotate-system(arg0: sparticle-launchinfo, arg1: sparticle-cpuinfo, arg2: transformq) => nonesource
Apply a rotation to the particle launching.

sparticle-track-root

sparticle-track-root(arg0: object, arg1: sparticle-cpuinfo, arg2: vector) => nonesource
track the root of the process drawable

sparticle-track-root-prim

sparticle-track-root-prim(arg0: object, arg1: sparticle-cpuinfo, arg2: vector) => nonesource
track the root of the collision geometry (must use collide-shape for root)
unlink-part-group-by-heap(arg0: kheap) => intsource
Find all particle groups that are stored in the specified heap and set them to 0.

Variables


*death-adgif*

*death-adgif*: adgif-shadersource

*global-toggle*

*global-toggle*: intsource

*part-group-id-table*

*part-group-id-table*: arraysource

*part-id-table*

*part-id-table*: arraysource

*particle-300hz-timer*

*particle-300hz-timer*: intsource

*particle-adgif-cache*

*particle-adgif-cache*: particle-adgif-cachesource

*sp-launch-queue*

*sp-launch-queue*: sp-launch-queuesource

*sp-launcher-enable*

*sp-launcher-enable*: symbolsource

*sp-launcher-lock*

*sp-launcher-lock*: symbolsource

SPARTICLE_QUEUE_SIZE

SPARTICLE_QUEUE_SIZE: unknownsource

sparticle

source

Functions


all-particles-50-to-60

all-particles-50-to-60() => nonesource

all-particles-60-to-50

all-particles-60-to-50() => nonesource

forall-particles

forall-particles(arg0: function, arg1: symbol, arg2: symbol) => nonesource
run function on all particles. arg1 for 2d, arg2 for 3d.

forall-particles-runner

forall-particles-runner(arg0: function, arg1: sparticle-system) => nonesource
run function on all particles in the system.

forall-particles-with-key

forall-particles-with-key(arg0: sparticle-launch-control, arg1: function, arg2: symbol, arg3: symbol) => nonesource
call the given function on all particles with the given key. arg2 is 2d, arg3 is 3d.

forall-particles-with-key-runner

forall-particles-with-key-runner(arg0: sparticle-launch-control, arg1: function, arg2: sparticle-system) => nonesource
call the given function on all particles with the given key (arg0)

kill-all-particles-in-level

kill-all-particles-in-level(arg0: level) => intsource
kill all particles belonging to the given level.

kill-all-particles-with-key

kill-all-particles-with-key(arg0: sparticle-launch-control) => nonesource

process-particles

process-particles() => nonesource
main particle system update.

set-particle-frame-time

set-particle-frame-time(scaled-seconds: int) => nonesource
Adjusts particle frame time based on the frame-rate (scaled-seconds). Note: This used to be a case statement and has been rewritten as a more generic formula

sp-copy-from-spr

sp-copy-from-spr(arg0: int, arg1: pointer, arg2: int) => nonesource

sp-copy-to-spr

sp-copy-to-spr(arg0: int, arg1: pointer, arg2: int) => nonesource

sp-free-particle

sp-free-particle(arg0: sparticle-system, arg1: int, arg2: sparticle-cpuinfo, arg3: sprite-vec-data-2d) => nonesource
free a particle

sp-get-approx-alloc-size

sp-get-approx-alloc-size(arg0: sparticle-system, arg1: int) => intsource
get approximately the amount of sprite memory used.

sp-get-block-size

sp-get-block-size(arg0: sparticle-system, arg1: int) => intsource
get the index of the highest used block for the given group (0 or 1)

sp-get-particle

sp-get-particle(arg0: sparticle-system, arg1: int, arg2: sparticle-launch-state) => sparticle-cpuinfosource
alloc a particle

sp-kill-particle

sp-kill-particle(arg0: sparticle-system, arg1: sparticle-cpuinfo) => nonesource
kill the given particle

sp-orbiter

sp-orbiter(arg0: sparticle-system, arg1: sparticle-cpuinfo, arg2: vector) => nonesource

sp-particle-copy!

sp-particle-copy!(arg0: sparticle-cpuinfo, arg1: sparticle-cpuinfo) => nonesource
copy some of the particle state.

sp-process-block

sp-process-block(arg0: sparticle-system, arg1: int, arg2: sprite-array-2d, arg3: int) => nonesource
update the given block of particles

sp-process-particle-system

sp-process-particle-system(arg0: sparticle-system, arg1: int, arg2: sprite-array-2d) => nonesource
update an entire particle system.

sparticle-50-to-60

sparticle-50-to-60(arg0: sparticle-system, arg1: sparticle-cpuinfo, arg2: pointer) => nonesource
convert from 50hz to 60hz particles

sparticle-60-to-50

sparticle-60-to-50(arg0: sparticle-system, arg1: sparticle-cpuinfo, arg2: pointer) => nonesource
convert from 60hz to 50hz particles

sparticle-kill-it

sparticle-kill-it(arg0: sparticle-system, arg1: sparticle-cpuinfo) => nonesource
kill a particle without freeing it.

sparticle-kill-it-level0

sparticle-kill-it-level0(arg0: sparticle-system, arg1: sparticle-cpuinfo) => nonesource
kill all particles belonging to level 0

sparticle-kill-it-level1

sparticle-kill-it-level1(arg0: sparticle-system, arg1: sparticle-cpuinfo) => nonesource
kill all particles belonging to level 1.

Variables


*sp-particle-system-2d*

*sp-particle-system-2d*: sparticle-systemsource

*sp-particle-system-3d*

*sp-particle-system-3d*: sparticle-systemsource