You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When creating a particle spawner during Update, the particles will spawn at the origin position.
This is especially noticeable when using one_shot spawners.
It seems the GlobalTransform is not at the correct location yet when the particle spawn system is running.
To see this in action, modify one of the examples collision:
add the following to the adjust_time_scale system:
if input.just_pressed(KeyCode::Enter){
commands.spawn((ParticleSpawner{rate:100.0,one_shot:true,emission_shape:EmissionShape::Circle{normal:Vec3::Y,radius:0.3,},//same spawn code as in the Startup system
...Transform{translation:Vec3::new(5.,3.5,0.),rotation:Quat::from_rotation_z(PI / 4.),
..default()},));}
This will create particles at the origin point instead of the provided translation
The text was updated successfully, but these errors were encountered:
Occuros
changed the title
Particles spawn at origin of created during update
Particles spawn at origin if created during update
Jan 21, 2025
When creating a particle spawner during
Update
, the particles will spawn at the origin position.This is especially noticeable when using
one_shot
spawners.It seems the
GlobalTransform
is not at the correct location yet when the particle spawn system is running.To see this in action, modify one of the examples
collision
:add the following to the
adjust_time_scale
system:This will create particles at the origin point instead of the provided
translation
The text was updated successfully, but these errors were encountered: