Fix empty inventories

This commit is contained in:
brenoepics 2022-04-14 19:01:22 +00:00
parent 37abd2aadb
commit 471dae3068

View File

@ -25,6 +25,12 @@ public class RequestInventoryItemsEvent extends MessageHandler {
synchronized (this.client.getHabbo().getInventory().getItemsComponent().getItems()) {
TIntObjectMap<HabboItem> items = new TIntObjectHashMap<>();
if (totalItems == 0) {
this.client.sendResponse(new InventoryItemsComposer(0, 1, new TIntObjectHashMap<>()));
return;
}
TIntObjectIterator<HabboItem> iterator = this.client.getHabbo().getInventory().getItemsComponent().getItems().iterator();
int count = 0;