Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: remove rotation from explosion effects. #710

Merged
merged 1 commit into from Mar 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions core/src/elements/grenade.rs
Expand Up @@ -241,6 +241,7 @@ fn update_lit_grenades(
hydrated.remove(**spawner);
let mut explosion_transform = *transforms.get(entity).unwrap();
explosion_transform.translation.z += 1.0;
explosion_transform.rotation = Quat::IDENTITY;

// Clone types for move into closure
let damage_region_size = *damage_region_size;
Expand Down
1 change: 1 addition & 0 deletions core/src/elements/kick_bomb.rs
Expand Up @@ -256,6 +256,7 @@ fn update_lit_kick_bombs(
hydrated.remove(**spawner);
let mut explosion_transform = *transforms.get(entity).unwrap();
explosion_transform.translation.z += 1.0;
explosion_transform.rotation = Quat::IDENTITY;

// Clone types for move into closure
let damage_region_size = *damage_region_size;
Expand Down
3 changes: 2 additions & 1 deletion core/src/elements/mine.rs
Expand Up @@ -213,7 +213,8 @@ fn update_thrown_mines(
mut lifetimes: CompMut<Lifetime>,
mut sprites: CompMut<AtlasSprite>,
mut animated_sprites: CompMut<AnimatedSprite>| {
let explosion_transform = mine_transform;
let mut explosion_transform = mine_transform;
explosion_transform.rotation = Quat::IDENTITY;

// Despawn the grenade
entities.kill(entity);
Expand Down