This commit is contained in:
Alezito2008 2026-05-05 06:00:49 +03:00 committed by GitHub
commit 7b66c8eb22
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 12 additions and 4 deletions

View file

@ -173,9 +173,13 @@ void MultiplayerLocalPlayer::sendPosition()
}
shared_ptr<ItemEntity> MultiplayerLocalPlayer::drop()
shared_ptr<ItemEntity> MultiplayerLocalPlayer::drop(bool dropAll)
{
connection->send(std::make_shared<PlayerActionPacket>(PlayerActionPacket::DROP_ITEM, 0, 0, 0, 0));
int action = dropAll ?
PlayerActionPacket::DROP_ALL_ITEMS :
PlayerActionPacket::DROP_ITEM;
connection->send(std::make_shared<PlayerActionPacket>(action, 0, 0, 0, 0));
return nullptr;
}