diff options
-rw-r--r-- | data/recipes/default.ts | 2 | ||||
-rw-r--r-- | server/src/game.rs | 13 |
2 files changed, 8 insertions, 7 deletions
diff --git a/data/recipes/default.ts b/data/recipes/default.ts index f0a9ef6b..dd662081 100644 --- a/data/recipes/default.ts +++ b/data/recipes/default.ts @@ -68,7 +68,7 @@ export function process(from: string, to?: string) { const i = from + "-foodprocessor" const o = (to ?? (from + "-juice")) + "-foodprocessor" out({ action: "instant", inputs: ["foodprocessor", from], outputs: [i] }) - out({ action: "active", duration: 3, inputs: [i], outputs: [o] }) + out({ action: "passive", duration: 5, inputs: [i], outputs: [o] }) } export function bake(from: string, to?: string) { const o = (to ?? ("cooked-" + from)) diff --git a/server/src/game.rs b/server/src/game.rs index ad777584..4cb5c450 100644 --- a/server/src/game.rs +++ b/server/src/game.rs @@ -202,17 +202,18 @@ impl Game { pub fn packet_in(&mut self, player: PlayerID, packet: PacketS) -> Result<()> { match packet { PacketS::Join { name, character } => { + let position = if player.0 < 0 { + self.data.customer_spawn + } else { + self.data.chef_spawn + }; self.players.insert( player, Player { item: None, last_position_ts: Instant::now(), character, - position: if player.0 < 0 { - self.data.customer_spawn - } else { - self.data.chef_spawn - }, + position, communicate: None, interacting: None, name: name.clone(), @@ -221,7 +222,7 @@ impl Game { self.packet_out.push_back(PacketC::AddPlayer { id: player, name, - position: self.data.chef_spawn, + position, character, }); } |