From 8a0a126267726ea74fdd3c6b61a8f61db4600c6a Mon Sep 17 00:00:00 2001 From: darkrose Date: Thu, 10 Oct 2013 19:03:49 +1000 Subject: [PATCH] fix nodes removal when digging doors --- src/server.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/server.cpp b/src/server.cpp index f4b1b0a..818d5bf 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -2669,25 +2669,27 @@ void Server::ProcessData(u8 *data, u32 datasize, u16 peer_id) && (n.getContent()&CONTENT_HATCH_MASK) != CONTENT_HATCH_MASK ) { if ((n.getContent()&CONTENT_DOOR_SECT_MASK) == CONTENT_DOOR_SECT_MASK) { - sendRemoveNode(p_under+v3s16(0,-1,0), peer_id, &far_players, 30); + sendRemoveNode(p_under+v3s16(0,-1,0), 0, &far_players, 30); { MapEditEventIgnorer ign(&m_ignore_map_edit_events); m_env.getMap().removeNodeAndUpdate(p_under+v3s16(0,-1,0), modified_blocks); } }else{ - sendRemoveNode(p_under+v3s16(0,1,0), peer_id, &far_players, 30); + sendRemoveNode(p_under+v3s16(0,1,0), 0, &far_players, 30); { MapEditEventIgnorer ign(&m_ignore_map_edit_events); m_env.getMap().removeNodeAndUpdate(p_under+v3s16(0,1,0), modified_blocks); } } - } + sendRemoveNode(p_under, 0, &far_players, 30); + }else{ /* Send the removal to all close-by players. - If other player is close, send REMOVENODE - Otherwise set blocks not sent */ - sendRemoveNode(p_under, peer_id, &far_players, 30); + sendRemoveNode(p_under, peer_id, &far_players, 30); + } /* Update and send inventory