diff options
Diffstat (limited to 'server/src/game.rs')
-rw-r--r-- | server/src/game.rs | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/server/src/game.rs b/server/src/game.rs index 908c0b4e..5cdf8cd4 100644 --- a/server/src/game.rs +++ b/server/src/game.rs @@ -326,8 +326,6 @@ impl Game { .push_back(PacketC::Collide { player, force }); } PacketS::Interact { pos } => { - info!("interact {pos:?}"); - let pid = player; let player = self .players @@ -571,15 +569,22 @@ pub fn interact_effect( if let Some(effect) = interact(&data, edge, this_tile_kind, this, other, points, automated) { match effect { - InteractEffect::Put => packet_out.push_back(PacketC::MoveItem { - from: other_loc, - to: this_loc, - }), - InteractEffect::Take => packet_out.push_back(PacketC::MoveItem { - from: this_loc, - to: other_loc, - }), + InteractEffect::Put => { + info!("put {this_loc} <- {other_loc}"); + packet_out.push_back(PacketC::MoveItem { + from: other_loc, + to: this_loc, + }) + } + InteractEffect::Take => { + info!("take {this_loc} -> {other_loc}"); + packet_out.push_back(PacketC::MoveItem { + from: this_loc, + to: other_loc, + }) + } InteractEffect::Produce => { + info!("produce {this_loc} <~ {other_loc}"); if this_had_item { packet_out.push_back(PacketC::SetProgress { item: this_loc, |