Do not save arrows based on GameTimeController calculation.
This commit is contained in:
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -964,15 +963,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -6146,12 +6146,6 @@ public class PlayerInstance extends Playable
|
|||||||
{
|
{
|
||||||
arrows.changeCountWithoutTrace(-1, this, null);
|
arrows.changeCountWithoutTrace(-1, this, null);
|
||||||
arrows.setLastChange(ItemInstance.MODIFIED);
|
arrows.setLastChange(ItemInstance.MODIFIED);
|
||||||
|
|
||||||
// could do also without saving, but let's save approx 1 of 10
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
arrows.updateDatabase();
|
|
||||||
}
|
|
||||||
_inventory.refreshWeight();
|
_inventory.refreshWeight();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -6043,12 +6043,6 @@ public class PlayerInstance extends Playable
|
|||||||
{
|
{
|
||||||
arrows.changeCountWithoutTrace(-1, this, null);
|
arrows.changeCountWithoutTrace(-1, this, null);
|
||||||
arrows.setLastChange(ItemInstance.MODIFIED);
|
arrows.setLastChange(ItemInstance.MODIFIED);
|
||||||
|
|
||||||
// could do also without saving, but let's save approx 1 of 10
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
arrows.updateDatabase();
|
|
||||||
}
|
|
||||||
_inventory.refreshWeight();
|
_inventory.refreshWeight();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
@@ -30,7 +30,6 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
import org.l2jmobius.Config;
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.commons.database.DatabaseFactory;
|
import org.l2jmobius.commons.database.DatabaseFactory;
|
||||||
import org.l2jmobius.gameserver.GameTimeController;
|
|
||||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||||
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
import org.l2jmobius.gameserver.enums.InventoryBlockType;
|
||||||
import org.l2jmobius.gameserver.enums.ItemLocation;
|
import org.l2jmobius.gameserver.enums.ItemLocation;
|
||||||
@@ -968,15 +967,8 @@ public class PlayerInventory extends Inventory
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((GameTimeController.getInstance().getGameTicks() % 10) == 0)
|
|
||||||
{
|
|
||||||
updateItemCount(null, arrows, -1, _owner, null);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
updateItemCountNoDbUpdate(null, arrows, -1, _owner, null);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reduces item count in the stack, destroys item when count reaches 0.
|
* Reduces item count in the stack, destroys item when count reaches 0.
|
||||||
|
Reference in New Issue
Block a user