ThreadTracker + Attempt on NPC Disappearing fix
Engineered the ThreadTracker: server-embedded deadlock auditing tool, which will print error messages in case of found deadlocks (also showing all in-use locks on the time of the issue). Changed the player's id on DB now starting from 20mil, thus preventing players from overwriting NPC/mobs with same oid in-game. Requires proper testing to see if the issue has been cleared.
This commit is contained in:
@@ -24,8 +24,10 @@ import client.MapleCharacter;
|
||||
import client.MapleClient;
|
||||
import client.inventory.Item;
|
||||
import java.awt.Point;
|
||||
import java.util.concurrent.locks.ReentrantLock;
|
||||
import java.util.concurrent.locks.Lock;
|
||||
import tools.locks.MonitoredReentrantLock;
|
||||
import tools.MaplePacketCreator;
|
||||
import tools.locks.MonitoredEnums;
|
||||
|
||||
public class MapleMapItem extends AbstractMapleMapObject {
|
||||
|
||||
@@ -35,7 +37,7 @@ public class MapleMapItem extends AbstractMapleMapObject {
|
||||
protected byte type;
|
||||
protected boolean pickedUp = false, playerDrop;
|
||||
protected long dropTime;
|
||||
private ReentrantLock itemLock = new ReentrantLock();
|
||||
private Lock itemLock = new MonitoredReentrantLock(MonitoredEnums.MAP_ITEM);
|
||||
|
||||
public MapleMapItem(Item item, Point position, MapleMapObject dropper, MapleCharacter owner, byte type, boolean playerDrop) {
|
||||
setPosition(position);
|
||||
|
||||
Reference in New Issue
Block a user