From ec17616f8d6041ac5d93a786edec0f5d0f969a46 Mon Sep 17 00:00:00 2001 From: Alexander Foremny Date: Mon, 18 Mar 2024 04:58:00 +0100 Subject: feat: speed ability --- src/shared/player.rs | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'src/shared/player.rs') diff --git a/src/shared/player.rs b/src/shared/player.rs index a886499..4f571d8 100644 --- a/src/shared/player.rs +++ b/src/shared/player.rs @@ -1,3 +1,6 @@ +use crate::shared::activation::*; +use crate::shared::buffs::*; +use crate::shared::stats::*; use crate::shared::*; #[derive(Bundle)] @@ -9,6 +12,9 @@ pub struct PlayerBundle { cooldown: Cooldown, health: Health, champion: Champion, + effective_stats: EffectiveStats, + buffs: Buffs, + activation: Activation, replicate: Replicate, } @@ -20,8 +26,10 @@ impl PlayerBundle { }; replicate.enable_replicate_once::(); replicate.enable_replicate_once::(); - replicate.target::(NetworkTarget::Single(id)); replicate.target::(NetworkTarget::Single(id)); + replicate.target::(NetworkTarget::Single(id)); + replicate.target::(NetworkTarget::Single(id)); + let champion = Champion::default(); PlayerBundle { id: PlayerId(id), position: PlayerPosition(position), @@ -29,7 +37,10 @@ impl PlayerBundle { imperative: Imperative::Idle, cooldown: Cooldown::default(), health: Health::default(), - champion: Champion::default(), + champion, + effective_stats: EffectiveStats(BaseStats::from_champion(champion).0), + buffs: Buffs::default(), + activation: Activation::default(), replicate, } } -- cgit v1.2.3