aboutsummaryrefslogtreecommitdiffstats
path: root/src/shared
diff options
context:
space:
mode:
authorLibravatar Alexander Foremny <aforemny@posteo.de>2024-03-23 13:59:20 +0100
committerLibravatar Alexander Foremny <aforemny@posteo.de>2024-03-23 13:59:20 +0100
commita061b97e5c541b2dc6c46184f78d5a18b35d9254 (patch)
tree321b870eb62eed7943a89334c05306e92858177b /src/shared
parent12a6419eaa087f34bdde49b3f9227b3cb5575341 (diff)
fix: only players regen health
Diffstat (limited to 'src/shared')
-rw-r--r--src/shared/player.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/shared/player.rs b/src/shared/player.rs
index 6b21bac..d166a7d 100644
--- a/src/shared/player.rs
+++ b/src/shared/player.rs
@@ -1,6 +1,6 @@
-use crate::shared::faction::*;
use crate::shared::activation::*;
use crate::shared::buffs::*;
+use crate::shared::faction::*;
use crate::shared::shape::*;
use crate::shared::stats::*;
use crate::shared::*;
@@ -19,6 +19,7 @@ pub struct PlayerBundle {
activation: Activation,
shape: Shape,
faction: Faction,
+ player: Player,
replicate: Replicate,
}
@@ -51,6 +52,7 @@ impl PlayerBundle {
activation: Activation::default(),
shape: Shape::player(),
faction: Faction::default(),
+ player: Player::default(),
replicate,
}
}
@@ -64,3 +66,6 @@ pub struct PlayerPosition(pub Vec2);
#[derive(Component, Message, Serialize, Deserialize, Clone, Debug, PartialEq)]
pub struct PlayerColor(pub Color);
+
+#[derive(Component, Message, Serialize, Deserialize, Clone, Debug, PartialEq, Default)]
+pub struct Player;