diff --git a/src/engine/db/handlers/dbItemHandler.java b/src/engine/db/handlers/dbItemHandler.java index c041b88d..c630a8e2 100644 --- a/src/engine/db/handlers/dbItemHandler.java +++ b/src/engine/db/handlers/dbItemHandler.java @@ -548,6 +548,11 @@ public class dbItemHandler extends dbHandlerBase { public boolean UPDATE_VALUE(Item item, int value) { + // Write 0 if we will not modify the value from template + + if (item.value == item.template.item_value) + value = 0; + try (Connection connection = DbManager.getConnection(); PreparedStatement preparedStatement = connection.prepareStatement("UPDATE `obj_item` SET `item_value`=? WHERE `UID` = ?")) {