From 7bacd8ab7035d9e4d444ab17c9f5d1bcbdf5dab8 Mon Sep 17 00:00:00 2001 From: Kengxxiao <11478651+Kengxxiao@users.noreply.github.com> Date: Thu, 28 Apr 2022 20:54:47 +0800 Subject: [PATCH] do not save virtual item --- src/main/java/emu/grasscutter/game/inventory/Inventory.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/emu/grasscutter/game/inventory/Inventory.java b/src/main/java/emu/grasscutter/game/inventory/Inventory.java index e3855cf8f..240296003 100644 --- a/src/main/java/emu/grasscutter/game/inventory/Inventory.java +++ b/src/main/java/emu/grasscutter/game/inventory/Inventory.java @@ -218,7 +218,8 @@ public class Inventory implements Iterable { } // Set ownership and save to db - item.save(); + if (item.getItemData().getItemType() != ItemType.ITEM_VIRTUAL) + item.save(); return item; }