summaryrefslogtreecommitdiff
path: root/server/src
diff options
context:
space:
mode:
authormetamuffin <metamuffin@disroot.org>2024-09-17 14:58:35 +0200
committermetamuffin <metamuffin@disroot.org>2024-09-17 16:57:34 +0200
commitbf1a5cef4b7fa87cdd382c565044731c1ccef9e3 (patch)
tree412c704845fd0e9cf643572608de6e8170d9cbc8 /server/src
parentf1ffe3f2e0e22dac40c88c8f13f1ffa8b2955743 (diff)
downloadhurrycurry-bf1a5cef4b7fa87cdd382c565044731c1ccef9e3.tar
hurrycurry-bf1a5cef4b7fa87cdd382c565044731c1ccef9e3.tar.bz2
hurrycurry-bf1a5cef4b7fa87cdd382c565044731c1ccef9e3.tar.zst
add hint packet for tutorial
Diffstat (limited to 'server/src')
-rw-r--r--server/src/entity/mod.rs1
-rw-r--r--server/src/entity/tutorial.rs22
2 files changed, 23 insertions, 0 deletions
diff --git a/server/src/entity/mod.rs b/server/src/entity/mod.rs
index 30a5da55..70c5c785 100644
--- a/server/src/entity/mod.rs
+++ b/server/src/entity/mod.rs
@@ -23,6 +23,7 @@ pub mod customers;
pub mod environment_effect;
pub mod item_portal;
pub mod player_portal;
+pub mod tutorial;
use crate::{data::ItemTileRegistry, scoreboard::ScoreboardStore};
use anyhow::{anyhow, Result};
diff --git a/server/src/entity/tutorial.rs b/server/src/entity/tutorial.rs
new file mode 100644
index 00000000..20b1d03e
--- /dev/null
+++ b/server/src/entity/tutorial.rs
@@ -0,0 +1,22 @@
+use super::{Entity, EntityContext};
+use anyhow::Result;
+use hurrycurry_protocol::{glam::IVec2, PlayerID};
+
+pub struct Tutorial {
+ player: PlayerID,
+}
+
+impl Entity for Tutorial {
+ fn tick(&mut self, _c: EntityContext<'_>) -> Result<()> {
+ Ok(())
+ }
+ fn destructor(&mut self, _c: EntityContext<'_>) {}
+ fn interact(
+ &mut self,
+ _c: EntityContext<'_>,
+ _pos: Option<IVec2>,
+ _player: PlayerID,
+ ) -> Result<bool> {
+ Ok(false)
+ }
+}