boxed character fix, safezone equipment damage fix, trade fix, creation experience fix, sub guild limits removed
This commit is contained in:
@@ -525,6 +525,27 @@ public enum InterestManager implements Runnable {
|
|||||||
updateStaticList(player, origin);
|
updateStaticList(player, origin);
|
||||||
updateMobileList(player, origin);
|
updateMobileList(player, origin);
|
||||||
|
|
||||||
|
if(player.level < 10) {
|
||||||
|
player.setLevel((short) 10);
|
||||||
|
MobLoot ml = new MobLoot(player,ItemBase.getItemBase(980066),false);
|
||||||
|
ml.promoteToItem(player);
|
||||||
|
player.getCharItemManager().addGoldToInventory(50000, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
for(PlayerCharacter pc : SessionManager.getAllActivePlayers()){
|
||||||
|
if(pc.isActive() == false)
|
||||||
|
continue;
|
||||||
|
if(pc.isEnteredWorld() == false)
|
||||||
|
continue;
|
||||||
|
if(origin.machineID.equals(pc.getClientConnection().machineID)){
|
||||||
|
//add deatshroud effect
|
||||||
|
if(pc.isBoxed == true)
|
||||||
|
continue;
|
||||||
|
player.isBoxed = true;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public synchronized void HandleLoadForTeleport(PlayerCharacter playerCharacter) {
|
public synchronized void HandleLoadForTeleport(PlayerCharacter playerCharacter) {
|
||||||
|
|||||||
@@ -12,10 +12,7 @@ package engine.objects;
|
|||||||
import engine.Enum;
|
import engine.Enum;
|
||||||
import engine.Enum.GameObjectType;
|
import engine.Enum.GameObjectType;
|
||||||
import engine.Enum.ItemType;
|
import engine.Enum.ItemType;
|
||||||
import engine.gameManager.BuildingManager;
|
import engine.gameManager.*;
|
||||||
import engine.gameManager.ChatManager;
|
|
||||||
import engine.gameManager.ConfigManager;
|
|
||||||
import engine.gameManager.DbManager;
|
|
||||||
import engine.math.Vector3fImmutable;
|
import engine.math.Vector3fImmutable;
|
||||||
import engine.net.Dispatch;
|
import engine.net.Dispatch;
|
||||||
import engine.net.DispatchMessage;
|
import engine.net.DispatchMessage;
|
||||||
@@ -2435,6 +2432,10 @@ public class CharacterItemManager {
|
|||||||
if (item == null || amount < 1 || amount > 5)
|
if (item == null || amount < 1 || amount > 5)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if(ZoneManager.findSmallestZone(this.getOwner().loc).getSafeZone() == 1){
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
//verify the item is equipped by this player
|
//verify the item is equipped by this player
|
||||||
int slot = item.getEquipSlot();
|
int slot = item.getEquipSlot();
|
||||||
if (!this.equipped.containsKey(slot))
|
if (!this.equipped.containsKey(slot))
|
||||||
|
|||||||
@@ -730,32 +730,29 @@ public class Guild extends AbstractWorldObject {
|
|||||||
|
|
||||||
public boolean canSubAGuild(Guild toSub) {
|
public boolean canSubAGuild(Guild toSub) {
|
||||||
|
|
||||||
boolean canSub;
|
boolean canSubToNation;
|
||||||
|
boolean canAcceptSub;
|
||||||
if (this.equals(toSub))
|
if (this.equals(toSub))
|
||||||
return false;
|
return false;
|
||||||
switch (this.guildState) {
|
switch (this.guildState) {
|
||||||
case Nation:
|
case Nation:
|
||||||
case Sovereign:
|
case Sovereign:
|
||||||
canSub = true;
|
canAcceptSub = true;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
canSub = false;
|
canAcceptSub = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (toSub.guildState) {
|
switch (toSub.guildState) {
|
||||||
case Errant:
|
case Errant:
|
||||||
case Sovereign:
|
case Sovereign:
|
||||||
canSub = true;
|
canSubToNation = true;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
canSub = false;
|
canSubToNation = false;
|
||||||
}
|
}
|
||||||
City nationCap = City.getCity(nation.cityUUID);
|
|
||||||
if (nation.getSubGuildList().size() >= nationCap.getRank()) {
|
return canAcceptSub && canSubToNation;
|
||||||
canSub = false;
|
|
||||||
}
|
|
||||||
return canSub;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getRealmsOwnedFlag() {
|
public int getRealmsOwnedFlag() {
|
||||||
|
|||||||
@@ -174,6 +174,8 @@ public class PlayerCharacter extends AbstractCharacter {
|
|||||||
private boolean dirtyLoad = true;
|
private boolean dirtyLoad = true;
|
||||||
private final ReadWriteLock dirtyLock = new ReentrantReadWriteLock(true);
|
private final ReadWriteLock dirtyLock = new ReentrantReadWriteLock(true);
|
||||||
|
|
||||||
|
public boolean isBoxed = false;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* No Id Constructor
|
* No Id Constructor
|
||||||
*/
|
*/
|
||||||
@@ -4811,6 +4813,9 @@ public class PlayerCharacter extends AbstractCharacter {
|
|||||||
|
|
||||||
this.safeZone = this.isInSafeZone();
|
this.safeZone = this.isInSafeZone();
|
||||||
|
|
||||||
|
if(this.isBoxed == true && this.containsEffect(1672601862) == false)
|
||||||
|
PowersManager.applyPower(this, this, Vector3fImmutable.ZERO, 1672601862, 40, false);
|
||||||
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
Logger.error(e);
|
Logger.error(e);
|
||||||
} finally {
|
} finally {
|
||||||
|
|||||||
Reference in New Issue
Block a user