Fix determinism being broken due to bone matrix shenanigans (#87)
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:
@@ -1,6 +1,7 @@
|
||||
use std::collections::HashMap;
|
||||
|
||||
use bevy::prelude::*;
|
||||
use bevy_ggrs::Rollback;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
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 {
|
||||
bone_names: Vec<String>,
|
||||
parents: Vec<Option<usize>>,
|
||||
|
||||
@@ -250,6 +250,8 @@ impl Plugin for FighterPlugin {
|
||||
.checksum_component_with_hash::<FighterInvulnerabilityState>()
|
||||
.rollback_component_with_copy::<FighterKnockbackVelocity>()
|
||||
.checksum_component_with_hash::<FighterKnockbackVelocity>()
|
||||
.rollback_component_with_clone::<baked_animation::FighterBoneMatrices>()
|
||||
.checksum_component_with_hash::<baked_animation::FighterBoneMatrices>()
|
||||
// Debug views.
|
||||
.add_systems(
|
||||
FixedPostUpdate,
|
||||
|
||||
Reference in New Issue
Block a user