Handler created for UnCommitToTradeMsg
This commit is contained in:
@@ -444,36 +444,6 @@ public class CharacterItemManager {
|
||||
return true;
|
||||
}
|
||||
|
||||
public synchronized boolean uncommitToTrade(UncommitToTradeMsg msg) {
|
||||
|
||||
PlayerCharacter source = (PlayerCharacter) this.getOwner();
|
||||
|
||||
if (source == null || !source.isAlive())
|
||||
return false;
|
||||
|
||||
CharacterItemManager sourceItemMan = source.charItemManager;
|
||||
|
||||
if (sourceItemMan == null)
|
||||
return false;
|
||||
|
||||
sourceItemMan.setTradeCommitted((byte) 0);
|
||||
|
||||
ClientConnection ccOther = sourceItemMan.getTradingWith();
|
||||
|
||||
if (ccOther == null)
|
||||
return false;
|
||||
|
||||
PlayerCharacter other = ccOther.getPlayerCharacter();
|
||||
|
||||
if (other == null)
|
||||
return false;
|
||||
|
||||
if (!canTrade(source, other))
|
||||
return false;
|
||||
|
||||
return modifyCommitToTrade();
|
||||
}
|
||||
|
||||
public synchronized boolean modifyCommitToTrade() {
|
||||
CharacterItemManager man1 = this;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user