Fix determinism being broken due to bone matrix shenanigans (#87)
CI / build-and-test (push) Successful in 5m27s
CI / production-build (push) Successful in 22m11s

Reviewed-on: #87
Co-authored-by: Álex Román Núñez <eirexe@eirteam.moe>
This commit was merged in pull request #87.
This commit is contained in:
2026-10-07 19:31:01 +00:00
committed by EIREXE
parent 3dfe2fa000
commit a1595d841a
2 changed files with 5 additions and 1 deletions
+3 -1
View File
@@ -1,6 +1,7 @@
use std::collections::HashMap; use std::collections::HashMap;
use bevy::prelude::*; use bevy::prelude::*;
use bevy_ggrs::Rollback;
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
use super::BAKED_ANIMATION_FPS; use super::BAKED_ANIMATION_FPS;
@@ -111,7 +112,8 @@ impl BakedFighterAnimations {
} }
} }
#[derive(Component, Clone, Debug, Default)] #[derive(Component, Clone, Debug, Default, Hash)]
#[require(Rollback)]
pub struct FighterBoneMatrices { pub struct FighterBoneMatrices {
bone_names: Vec<String>, bone_names: Vec<String>,
parents: Vec<Option<usize>>, parents: Vec<Option<usize>>,
+2
View File
@@ -250,6 +250,8 @@ impl Plugin for FighterPlugin {
.checksum_component_with_hash::<FighterInvulnerabilityState>() .checksum_component_with_hash::<FighterInvulnerabilityState>()
.rollback_component_with_copy::<FighterKnockbackVelocity>() .rollback_component_with_copy::<FighterKnockbackVelocity>()
.checksum_component_with_hash::<FighterKnockbackVelocity>() .checksum_component_with_hash::<FighterKnockbackVelocity>()
.rollback_component_with_clone::<baked_animation::FighterBoneMatrices>()
.checksum_component_with_hash::<baked_animation::FighterBoneMatrices>()
// Debug views. // Debug views.
.add_systems( .add_systems(
FixedPostUpdate, FixedPostUpdate,