aboutsummaryrefslogtreecommitdiff
path: root/server/src/game.rs
diff options
context:
space:
mode:
Diffstat (limited to 'server/src/game.rs')
-rw-r--r--server/src/game.rs12
1 files changed, 10 insertions, 2 deletions
diff --git a/server/src/game.rs b/server/src/game.rs
index c9881e7c..9c1bdd29 100644
--- a/server/src/game.rs
+++ b/server/src/game.rs
@@ -59,6 +59,10 @@ impl Game {
g
}
+ pub fn tiles(&self) -> &HashMap<IVec2, Tile> {
+ &self.tiles
+ }
+
pub fn packet_out(&mut self) -> Option<PacketC> {
self.packet_out.pop_front()
}
@@ -101,7 +105,11 @@ impl Game {
Player {
item: None,
character,
- position: self.data.spawn,
+ position: if player < 0 {
+ self.data.customer_spawn
+ } else {
+ self.data.chef_spawn
+ },
interacting: None,
name: name.clone(),
},
@@ -109,7 +117,7 @@ impl Game {
self.packet_out.push_back(PacketC::AddPlayer {
id: player,
name,
- position: self.data.spawn,
+ position: self.data.chef_spawn,
character,
item: None,
});