MCPcopy Create free account
hub / github.com/carbonengine/trinity / SpawnParticles

Method SpawnParticles

trinity/Particle/Tr2GpuSharedEmitter.cpp:149–163  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

147}
148
149void Tr2GpuSharedEmitter::SpawnParticles( const UpdateArguments& arguments, const Vector3* position, const Vector3* velocity, float rateModifier )
150{
151 if( !arguments.system || !m_enabled )
152 {
153 return;
154 }
155 Vector3 pos( XMVector3TransformCoord( position ? *position : m_position, arguments.parentTransform ) );
156 Vector3 vel = Vector3( 0.f, 0.f, 0.f );
157 if( velocity )
158 {
159 vel = XMVector3TransformNormal( *velocity, arguments.parentTransform );
160 }
161 auto emitter = m_emitter;
162 SpawnParticles( emitter, arguments, pos, pos, vel, vel, 0.f, rateModifier );
163}
164
165void Tr2GpuSharedEmitter::SpawnParticles(
166 const UpdateArguments& arguments,

Callers

nothing calls this directly

Calls 2

EmitMethod · 0.80
Vector3Class · 0.50

Tested by

no test coverage detected