mirror of
https://github.com/moparisthebest/minetest
synced 2024-12-23 08:08:47 -05:00
Handle items with m_count==0 sanely when placing
This commit is contained in:
parent
cd030639a4
commit
2a610b011a
@ -3361,7 +3361,7 @@ void Server::ProcessData(u8 *data, u32 datasize, u16 peer_id)
|
||||
if(g_settings->getBool("creative_mode") == false && ilist)
|
||||
{
|
||||
// Remove from inventory and send inventory
|
||||
if(mitem->getCount() == 1)
|
||||
if(mitem->getCount() <= 1)
|
||||
ilist->deleteItem(item_i);
|
||||
else
|
||||
mitem->remove(1);
|
||||
|
Loading…
Reference in New Issue
Block a user