Skip to content

Commit

Permalink
Add no automatic batching to particle system
Browse files Browse the repository at this point in the history
  • Loading branch information
phisn committed Mar 30, 2024
1 parent cbc2621 commit beebe14
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
use std::{f32::consts, sync::Arc, time::Duration};

use bevy::{
ecs::schedule::SystemConfigs, prelude::*, render::view::NoFrustumCulling, sprite::Mesh2dHandle,
ecs::schedule::SystemConfigs,
prelude::*,
render::{batching::NoAutomaticBatching, view::NoFrustumCulling},
sprite::Mesh2dHandle,
};

use bevy_rapier2d::dynamics::Velocity;
Expand Down Expand Up @@ -86,7 +89,7 @@ fn rocket_particle_setup(
spatial_bundle: SpatialBundle::from_transform(Transform::from_xyz(0.0, 0.0, 0.0)),
instancing_host: InstancingHost::default(),
})
.insert((RocketParticleSystem, NoFrustumCulling));
.insert((RocketParticleSystem, NoFrustumCulling, NoAutomaticBatching));
}

fn thrust_particle_template() -> ParticleTemplate {
Expand Down

0 comments on commit beebe14

Please sign in to comment.