9
0
mirror of https://github.com/HibiscusMC/HMCCosmetics.git synced 2025-12-29 11:59:21 +00:00

clean: move private bulkUpdate method to updateCosmetic since it was just using that method anyways

This commit is contained in:
LoJoSho
2023-12-19 19:28:06 -06:00
parent 88691956ba
commit 55d4f9ae09

View File

@@ -188,11 +188,7 @@ public class CosmeticUser {
}
public void updateCosmetic() {
bulkUpdateCosmetic();
}
private void bulkUpdateCosmetic() {
MessagesUtil.sendDebugMessages("bulkUpdateCosmetic - start");
MessagesUtil.sendDebugMessages("updateCosmetic (All) - start");
HashMap<EquipmentSlot, ItemStack> items = new HashMap<>();
for (Cosmetic cosmetic : getCosmetics()) {
@@ -208,7 +204,7 @@ public class CosmeticUser {
}
if (items.isEmpty()) return;
NMSHandlers.getHandler().equipmentSlotUpdate(getEntity().getEntityId(), items, PlayerUtils.getNearbyPlayers(getEntity().getLocation()));
MessagesUtil.sendDebugMessages("bulkUpdateCosmetic - end - " + items.size());
MessagesUtil.sendDebugMessages("updateCosmetic (All) - end - " + items.size());
}
public ItemStack getUserCosmeticItem(CosmeticSlot slot) {