Skip to main content

fx.spawn

Overview

  • Spawns an FX table entry at an explicit world transform or attached to an entity. Spawner-backed montage FX are played through a transient B1FXSpawnActor at the requested transform.

Metadata

FieldValue
DisplaySpawn FX
Categoryfx
AccessUserCheat
ScopeB2Authority
Tags
Aliases

Parameters

NameTypeRequiredDefaultDescription
fx_idnameyesFX table row ID
entity_identityIdnoOptional target entity ID. If omitted, transform is world-space.
socketnamenoOptional socket name for entity attachment
xfloatnoX location. Required for world-space spawn, relative otherwise.
yfloatnoY location. Required for world-space spawn, relative otherwise.
zfloatnoZ location. Required for world-space spawn, relative otherwise.
pitchfloatno0Pitch in degrees
yawfloatno0Yaw in degrees
rollfloatno0Roll in degrees
scalefloatno1Uniform scale
scale_xfloatnoX scale override
scale_yfloatnoY scale override
scale_zfloatnoZ scale override
with_handleboolnofalseRegister the FX with B1 FX handles

Returns

  • Return shape is not declared for this command.

Usage

await inzoi.cli.execute('fx.spawn', {
fx_id: '',
entity_id: 0, // optional
socket: '', // optional
x: 0.0, // optional
y: 0.0, // optional
z: 0.0, // optional
pitch: 0, // optional
yaw: 0, // optional
roll: 0, // optional
scale: 1, // optional
scale_x: 0.0, // optional
scale_y: 0.0, // optional
scale_z: 0.0, // optional
with_handle: false, // optional
});