-Dropped Javolution.
-Removal of Q00344_1000YearsTheEndOfLamentation. -Fixed starting conditions for Q00144_PailakaInjuredDragon. -Fixed starting conditions for last Seven Sign quests. -Added missing MonasteryOfSilence.xml instance spawns and doors. -Removed many catacomb spawns.
This commit is contained in:
@@ -25,12 +25,11 @@ import java.sql.Connection;
|
||||
import java.sql.PreparedStatement;
|
||||
import java.sql.ResultSet;
|
||||
import java.util.Calendar;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import com.l2jserver.L2DatabaseFactory;
|
||||
import com.l2jserver.gameserver.ThreadPoolManager;
|
||||
import com.l2jserver.gameserver.data.sql.impl.ClanTable;
|
||||
@@ -62,7 +61,7 @@ public class Auction
|
||||
private long _currentBid = 0;
|
||||
private long _startingBid = 0;
|
||||
|
||||
private final Map<Integer, Bidder> _bidders = new FastMap<>();
|
||||
private final Map<Integer, Bidder> _bidders = new HashMap<>();
|
||||
|
||||
private static final String[] ItemTypeName =
|
||||
{
|
||||
|
||||
@@ -18,14 +18,13 @@
|
||||
*/
|
||||
package com.l2jserver.gameserver.model.entity;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map.Entry;
|
||||
import java.util.concurrent.ScheduledFuture;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastList;
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import com.l2jserver.Config;
|
||||
import com.l2jserver.gameserver.ThreadPoolManager;
|
||||
import com.l2jserver.gameserver.data.xml.impl.NpcData;
|
||||
@@ -64,15 +63,15 @@ public final class BlockCheckerEngine
|
||||
// The object which holds all basic members info
|
||||
protected ArenaParticipantsHolder _holder;
|
||||
// Maps to hold player of each team and his points
|
||||
protected FastMap<L2PcInstance, Integer> _redTeamPoints = new FastMap<>();
|
||||
protected FastMap<L2PcInstance, Integer> _blueTeamPoints = new FastMap<>();
|
||||
protected HashMap<L2PcInstance, Integer> _redTeamPoints = new HashMap<>();
|
||||
protected HashMap<L2PcInstance, Integer> _blueTeamPoints = new HashMap<>();
|
||||
// The initial points of the event
|
||||
protected int _redPoints = 15;
|
||||
protected int _bluePoints = 15;
|
||||
// Current used arena
|
||||
protected int _arena = -1;
|
||||
// All blocks
|
||||
protected FastList<L2Spawn> _spawns = new FastList<>();
|
||||
protected ArrayList<L2Spawn> _spawns = new ArrayList<>();
|
||||
// Sets if the red team won the event at the end of this (used for packets)
|
||||
protected boolean _isRedWinner;
|
||||
// Time when the event starts. Used on packet sending
|
||||
@@ -121,7 +120,7 @@ public final class BlockCheckerEngine
|
||||
// Common z coordinate
|
||||
private static final int _zCoord = -2405;
|
||||
// List of dropped items in event (for later deletion)
|
||||
protected FastList<L2ItemInstance> _drops = new FastList<>();
|
||||
protected ArrayList<L2ItemInstance> _drops = new ArrayList<>();
|
||||
// Default arena
|
||||
private static final byte DEFAULT_ARENA = -1;
|
||||
// Event is started
|
||||
@@ -662,7 +661,7 @@ public final class BlockCheckerEngine
|
||||
*/
|
||||
private void rewardAsWinner(boolean isRed)
|
||||
{
|
||||
FastMap<L2PcInstance, Integer> tempPoints = isRed ? _redTeamPoints : _blueTeamPoints;
|
||||
HashMap<L2PcInstance, Integer> tempPoints = isRed ? _redTeamPoints : _blueTeamPoints;
|
||||
|
||||
// Main give
|
||||
for (Entry<L2PcInstance, Integer> points : tempPoints.entrySet())
|
||||
@@ -719,7 +718,7 @@ public final class BlockCheckerEngine
|
||||
*/
|
||||
private void rewardAsLooser(boolean isRed)
|
||||
{
|
||||
FastMap<L2PcInstance, Integer> tempPoints = isRed ? _redTeamPoints : _blueTeamPoints;
|
||||
HashMap<L2PcInstance, Integer> tempPoints = isRed ? _redTeamPoints : _blueTeamPoints;
|
||||
|
||||
for (Entry<L2PcInstance, Integer> entry : tempPoints.entrySet())
|
||||
{
|
||||
|
||||
@@ -23,14 +23,13 @@ import java.sql.PreparedStatement;
|
||||
import java.sql.ResultSet;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Calendar;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import com.l2jserver.Config;
|
||||
import com.l2jserver.L2DatabaseFactory;
|
||||
import com.l2jserver.gameserver.ThreadPoolManager;
|
||||
@@ -244,7 +243,7 @@ public final class Castle extends AbstractResidence
|
||||
{
|
||||
super(castleId);
|
||||
load();
|
||||
_function = new FastMap<>();
|
||||
_function = new HashMap<>();
|
||||
initResidenceZone();
|
||||
spawnSideNpcs();
|
||||
if (getOwnerId() != 0)
|
||||
|
||||
@@ -22,12 +22,11 @@ import java.sql.Connection;
|
||||
import java.sql.PreparedStatement;
|
||||
import java.sql.ResultSet;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import com.l2jserver.L2DatabaseFactory;
|
||||
import com.l2jserver.gameserver.ThreadPoolManager;
|
||||
import com.l2jserver.gameserver.data.sql.impl.ClanTable;
|
||||
@@ -213,7 +212,7 @@ public abstract class ClanHall
|
||||
_ownerId = set.getInt("ownerId");
|
||||
_desc = set.getString("desc");
|
||||
_location = set.getString("location");
|
||||
_functions = new FastMap<>();
|
||||
_functions = new HashMap<>();
|
||||
|
||||
if (_ownerId > 0)
|
||||
{
|
||||
|
||||
@@ -18,13 +18,12 @@
|
||||
*/
|
||||
package com.l2jserver.gameserver.model.entity;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Calendar;
|
||||
import java.util.List;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastList;
|
||||
|
||||
import com.l2jserver.gameserver.ThreadPoolManager;
|
||||
import com.l2jserver.gameserver.ai.CtrlIntention;
|
||||
import com.l2jserver.gameserver.enums.DuelResult;
|
||||
@@ -83,7 +82,7 @@ public class Duel
|
||||
_duelEndTime.add(Calendar.SECOND, 120);
|
||||
}
|
||||
|
||||
_playerConditions = new FastList<>();
|
||||
_playerConditions = new ArrayList<>();
|
||||
|
||||
setFinished(false);
|
||||
|
||||
@@ -108,7 +107,7 @@ public class Duel
|
||||
private double _cp;
|
||||
private boolean _paDuel;
|
||||
private int _x, _y, _z;
|
||||
private FastList<Skill> _debuffs;
|
||||
private ArrayList<Skill> _debuffs;
|
||||
|
||||
public PlayerCondition(L2PcInstance player, boolean partyDuel)
|
||||
{
|
||||
@@ -160,7 +159,7 @@ public class Duel
|
||||
{
|
||||
if (_debuffs == null)
|
||||
{
|
||||
_debuffs = new FastList<>();
|
||||
_debuffs = new ArrayList<>();
|
||||
}
|
||||
|
||||
_debuffs.add(debuff);
|
||||
|
||||
@@ -33,9 +33,6 @@ import java.util.concurrent.TimeUnit;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastList;
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import com.l2jserver.Config;
|
||||
import com.l2jserver.L2DatabaseFactory;
|
||||
import com.l2jserver.gameserver.FortUpdater;
|
||||
@@ -81,14 +78,14 @@ public final class Fort extends AbstractResidence
|
||||
private int _state = 0;
|
||||
private int _castleId = 0;
|
||||
private int _supplyLvL = 0;
|
||||
private final FastMap<Integer, FortFunction> _function;
|
||||
private final HashMap<Integer, FortFunction> _function;
|
||||
private final ScheduledFuture<?>[] _FortUpdater = new ScheduledFuture<?>[2];
|
||||
|
||||
// Spawn Data
|
||||
private boolean _isSuspiciousMerchantSpawned = false;
|
||||
private final FastList<L2Spawn> _siegeNpcs = new FastList<>();
|
||||
private final FastList<L2Spawn> _npcCommanders = new FastList<>();
|
||||
private final FastList<L2Spawn> _specialEnvoys = new FastList<>();
|
||||
private final ArrayList<L2Spawn> _siegeNpcs = new ArrayList<>();
|
||||
private final ArrayList<L2Spawn> _npcCommanders = new ArrayList<>();
|
||||
private final ArrayList<L2Spawn> _specialEnvoys = new ArrayList<>();
|
||||
|
||||
private final Map<Integer, Integer> _envoyCastles = new HashMap<>(2);
|
||||
private final Set<Integer> _availableCastles = new HashSet<>(1);
|
||||
@@ -247,7 +244,7 @@ public final class Fort extends AbstractResidence
|
||||
super(fortId);
|
||||
load();
|
||||
loadFlagPoles();
|
||||
_function = new FastMap<>();
|
||||
_function = new HashMap<>();
|
||||
if (getOwnerClan() != null)
|
||||
{
|
||||
setVisibleFlag(true);
|
||||
|
||||
@@ -21,14 +21,13 @@ package com.l2jserver.gameserver.model.entity;
|
||||
import java.sql.Connection;
|
||||
import java.sql.PreparedStatement;
|
||||
import java.sql.ResultSet;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Calendar;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.ScheduledFuture;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastList;
|
||||
|
||||
import com.l2jserver.Config;
|
||||
import com.l2jserver.L2DatabaseFactory;
|
||||
import com.l2jserver.gameserver.ThreadPoolManager;
|
||||
@@ -227,10 +226,10 @@ public class FortSiege implements Siegable
|
||||
}
|
||||
}
|
||||
|
||||
private final List<L2SiegeClan> _attackerClans = new FastList<>();
|
||||
private final List<L2SiegeClan> _attackerClans = new ArrayList<>();
|
||||
|
||||
// Fort setting
|
||||
protected FastList<L2Spawn> _commanders = new FastList<>();
|
||||
protected ArrayList<L2Spawn> _commanders = new ArrayList<>();
|
||||
protected final Fort _fort;
|
||||
private boolean _isInProgress = false;
|
||||
private FortSiegeGuardManager _siegeGuardManager;
|
||||
@@ -553,7 +552,7 @@ public class FortSiege implements Siegable
|
||||
@Override
|
||||
public List<L2PcInstance> getAttackersInZone()
|
||||
{
|
||||
List<L2PcInstance> players = new FastList<>();
|
||||
List<L2PcInstance> players = new ArrayList<>();
|
||||
L2Clan clan;
|
||||
for (L2SiegeClan siegeclan : getAttackerClans())
|
||||
{
|
||||
@@ -587,7 +586,7 @@ public class FortSiege implements Siegable
|
||||
*/
|
||||
public List<L2PcInstance> getOwnersInZone()
|
||||
{
|
||||
List<L2PcInstance> players = new FastList<>();
|
||||
List<L2PcInstance> players = new ArrayList<>();
|
||||
L2Clan clan;
|
||||
if (getFort().getOwnerClan() != null)
|
||||
{
|
||||
@@ -625,7 +624,7 @@ public class FortSiege implements Siegable
|
||||
L2Spawn spawn = instance.getSpawn();
|
||||
if (spawn != null)
|
||||
{
|
||||
FastList<FortSiegeSpawn> commanders = FortSiegeManager.getInstance().getCommanderSpawnList(getFort().getResidenceId());
|
||||
ArrayList<FortSiegeSpawn> commanders = FortSiegeManager.getInstance().getCommanderSpawnList(getFort().getResidenceId());
|
||||
for (FortSiegeSpawn spawn2 : commanders)
|
||||
{
|
||||
if (spawn2.getId() == spawn.getId())
|
||||
|
||||
@@ -24,18 +24,17 @@ import java.sql.ResultSet;
|
||||
import java.sql.SQLException;
|
||||
import java.sql.Statement;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Calendar;
|
||||
import java.util.Collections;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Map.Entry;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastList;
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import com.l2jserver.Config;
|
||||
import com.l2jserver.L2DatabaseFactory;
|
||||
import com.l2jserver.gameserver.cache.HtmCache;
|
||||
@@ -77,14 +76,14 @@ public class Hero
|
||||
// delete hero items
|
||||
private static final String DELETE_ITEMS = "DELETE FROM items WHERE item_id IN (6842, 6611, 6612, 6613, 6614, 6615, 6616, 6617, 6618, 6619, 6620, 6621, 9388, 9389, 9390) AND owner_id NOT IN (SELECT charId FROM characters WHERE accesslevel > 0)";
|
||||
|
||||
private static final Map<Integer, StatsSet> _heroes = new FastMap<>();
|
||||
private static final Map<Integer, StatsSet> _completeHeroes = new FastMap<>();
|
||||
private static final Map<Integer, StatsSet> _heroes = new HashMap<>();
|
||||
private static final Map<Integer, StatsSet> _completeHeroes = new HashMap<>();
|
||||
|
||||
private static final Map<Integer, StatsSet> _herocounts = new FastMap<>();
|
||||
private static final Map<Integer, List<StatsSet>> _herofights = new FastMap<>();
|
||||
private static final Map<Integer, StatsSet> _herocounts = new HashMap<>();
|
||||
private static final Map<Integer, List<StatsSet>> _herofights = new HashMap<>();
|
||||
|
||||
private static final Map<Integer, List<StatsSet>> _herodiary = new FastMap<>();
|
||||
private static final Map<Integer, String> _heroMessage = new FastMap<>();
|
||||
private static final Map<Integer, List<StatsSet>> _herodiary = new HashMap<>();
|
||||
private static final Map<Integer, String> _heroMessage = new HashMap<>();
|
||||
|
||||
public static final String COUNT = "count";
|
||||
public static final String PLAYED = "played";
|
||||
@@ -235,7 +234,7 @@ public class Hero
|
||||
|
||||
public void loadDiary(int charId)
|
||||
{
|
||||
final List<StatsSet> _diary = new FastList<>();
|
||||
final List<StatsSet> _diary = new ArrayList<>();
|
||||
int diaryentries = 0;
|
||||
try (Connection con = L2DatabaseFactory.getInstance().getConnection();
|
||||
PreparedStatement statement = con.prepareStatement("SELECT * FROM heroes_diary WHERE charId=? ORDER BY time ASC"))
|
||||
@@ -290,7 +289,7 @@ public class Hero
|
||||
|
||||
public void loadFights(int charId)
|
||||
{
|
||||
final List<StatsSet> _fights = new FastList<>();
|
||||
final List<StatsSet> _fights = new ArrayList<>();
|
||||
StatsSet _herocountdata = new StatsSet();
|
||||
Calendar _data = Calendar.getInstance();
|
||||
_data.set(Calendar.DAY_OF_MONTH, 1);
|
||||
@@ -464,7 +463,7 @@ public class Hero
|
||||
|
||||
if (!_mainlist.isEmpty())
|
||||
{
|
||||
FastList<StatsSet> _list = FastList.newInstance();
|
||||
final ArrayList<StatsSet> _list = new ArrayList<>();
|
||||
_list.addAll(_mainlist);
|
||||
Collections.reverse(_list);
|
||||
|
||||
@@ -516,8 +515,6 @@ public class Hero
|
||||
}
|
||||
|
||||
DiaryReply.replace("%list%", fList.toString());
|
||||
|
||||
FastList.recycle(_list);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -671,7 +668,7 @@ public class Hero
|
||||
return;
|
||||
}
|
||||
|
||||
Map<Integer, StatsSet> heroes = new FastMap<>();
|
||||
Map<Integer, StatsSet> heroes = new HashMap<>();
|
||||
|
||||
for (StatsSet hero : newHeroes)
|
||||
{
|
||||
|
||||
@@ -28,15 +28,13 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
import java.util.concurrent.CopyOnWriteArrayList;
|
||||
import java.util.concurrent.ScheduledFuture;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javax.xml.parsers.DocumentBuilderFactory;
|
||||
|
||||
import javolution.util.FastList;
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import org.w3c.dom.Document;
|
||||
import org.w3c.dom.NamedNodeMap;
|
||||
import org.w3c.dom.Node;
|
||||
@@ -82,8 +80,8 @@ public final class Instance
|
||||
private int _ejectTime = Config.EJECT_DEAD_PLAYER_TIME;
|
||||
/** Allow random walk for NPCs, global parameter. */
|
||||
private boolean _allowRandomWalk = true;
|
||||
private final List<Integer> _players = new FastList<Integer>().shared();
|
||||
private final List<L2Npc> _npcs = new FastList<L2Npc>().shared();
|
||||
private final List<Integer> _players = new CopyOnWriteArrayList<>();
|
||||
private final List<L2Npc> _npcs = new CopyOnWriteArrayList<>();
|
||||
private final Map<Integer, L2DoorInstance> _doors = new ConcurrentHashMap<>();
|
||||
private final Map<String, List<L2Spawn>> _manualSpawn = new HashMap<>();
|
||||
private Location _spawnLoc = null;
|
||||
@@ -104,7 +102,7 @@ public final class Instance
|
||||
private final List<Integer> _exceptionList = new ArrayList<>();
|
||||
|
||||
protected ScheduledFuture<?> _checkTimeUpTask = null;
|
||||
protected final Map<Integer, ScheduledFuture<?>> _ejectDeadTasks = new FastMap<>();
|
||||
protected final Map<Integer, ScheduledFuture<?>> _ejectDeadTasks = new HashMap<>();
|
||||
|
||||
public Instance(int id)
|
||||
{
|
||||
|
||||
@@ -31,9 +31,6 @@ import java.util.Map.Entry;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastList;
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import com.l2jserver.Config;
|
||||
import com.l2jserver.gameserver.cache.HtmCache;
|
||||
import com.l2jserver.gameserver.data.xml.impl.NpcData;
|
||||
@@ -61,12 +58,12 @@ public class L2Event
|
||||
public static String _eventCreator = "";
|
||||
public static String _eventInfo = "";
|
||||
public static int _teamsNumber = 0;
|
||||
public static final Map<Integer, String> _teamNames = new FastMap<>();
|
||||
public static final List<L2PcInstance> _registeredPlayers = new FastList<>();
|
||||
public static final Map<Integer, List<L2PcInstance>> _teams = new FastMap<>();
|
||||
public static final Map<Integer, String> _teamNames = new HashMap<>();
|
||||
public static final List<L2PcInstance> _registeredPlayers = new ArrayList<>();
|
||||
public static final Map<Integer, List<L2PcInstance>> _teams = new HashMap<>();
|
||||
public static int _npcId = 0;
|
||||
// public static final List<L2Npc> _npcs = new FastList<L2Npc>();
|
||||
private static final Map<L2PcInstance, PlayerEventHolder> _connectionLossData = new FastMap<>();
|
||||
// public static final List<L2Npc> _npcs = new ArrayList<L2Npc>();
|
||||
private static final Map<L2PcInstance, PlayerEventHolder> _connectionLossData = new HashMap<>();
|
||||
|
||||
public enum EventState
|
||||
{
|
||||
@@ -385,7 +382,7 @@ public class L2Event
|
||||
_eventInfo = br.readLine();
|
||||
}
|
||||
|
||||
List<L2PcInstance> temp = new FastList<>();
|
||||
List<L2PcInstance> temp = new ArrayList<>();
|
||||
for (L2PcInstance player : L2World.getInstance().getPlayers())
|
||||
{
|
||||
if (!player.isOnline())
|
||||
@@ -443,7 +440,7 @@ public class L2Event
|
||||
// Insert empty lists at _teams.
|
||||
for (int i = 0; i < _teamsNumber; i++)
|
||||
{
|
||||
_teams.put(i + 1, new FastList<L2PcInstance>());
|
||||
_teams.put(i + 1, new ArrayList<L2PcInstance>());
|
||||
}
|
||||
|
||||
int i = 0;
|
||||
|
||||
@@ -31,8 +31,6 @@ import java.util.concurrent.ScheduledFuture;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastList;
|
||||
|
||||
import com.l2jserver.Config;
|
||||
import com.l2jserver.L2DatabaseFactory;
|
||||
import com.l2jserver.gameserver.ThreadPoolManager;
|
||||
@@ -223,9 +221,9 @@ public class Siege implements Siegable
|
||||
}
|
||||
|
||||
// must support Concurrent Modifications
|
||||
private final List<L2SiegeClan> _attackerClans = new FastList<>();
|
||||
private final List<L2SiegeClan> _defenderClans = new FastList<>();
|
||||
private final List<L2SiegeClan> _defenderWaitingClans = new FastList<>();
|
||||
private final List<L2SiegeClan> _attackerClans = new ArrayList<>();
|
||||
private final List<L2SiegeClan> _defenderClans = new ArrayList<>();
|
||||
private final List<L2SiegeClan> _defenderWaitingClans = new ArrayList<>();
|
||||
|
||||
// Castle setting
|
||||
private final List<L2ControlTowerInstance> _controlTowers = new ArrayList<>();
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
*/
|
||||
package com.l2jserver.gameserver.model.entity;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@@ -25,8 +26,6 @@ import java.util.Map.Entry;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import com.l2jserver.Config;
|
||||
import com.l2jserver.gameserver.cache.HtmCache;
|
||||
import com.l2jserver.gameserver.data.xml.impl.DoorData;
|
||||
@@ -188,7 +187,7 @@ public class TvTEvent
|
||||
setState(EventState.STARTING);
|
||||
|
||||
// Randomize and balance team distribution
|
||||
Map<Integer, L2PcInstance> allParticipants = new FastMap<>();
|
||||
Map<Integer, L2PcInstance> allParticipants = new HashMap<>();
|
||||
allParticipants.putAll(_teams[0].getParticipatedPlayers());
|
||||
allParticipants.putAll(_teams[1].getParticipatedPlayers());
|
||||
_teams[0].cleanMe();
|
||||
|
||||
@@ -18,10 +18,9 @@
|
||||
*/
|
||||
package com.l2jserver.gameserver.model.entity;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
|
||||
|
||||
/**
|
||||
@@ -35,8 +34,8 @@ public class TvTEventTeam
|
||||
private int[] _coordinates = new int[3];
|
||||
/** The points of the team<br> */
|
||||
private short _points;
|
||||
/** Name and instance of all participated players in FastMap<br> */
|
||||
private Map<Integer, L2PcInstance> _participatedPlayers = new FastMap<>();
|
||||
/** Name and instance of all participated players in HashMap<br> */
|
||||
private Map<Integer, L2PcInstance> _participatedPlayers = new HashMap<>();
|
||||
|
||||
/**
|
||||
* C'tor initialize the team<br>
|
||||
@@ -98,7 +97,7 @@ public class TvTEventTeam
|
||||
public void cleanMe()
|
||||
{
|
||||
_participatedPlayers.clear();
|
||||
_participatedPlayers = new FastMap<>();
|
||||
_participatedPlayers = new HashMap<>();
|
||||
_points = 0;
|
||||
}
|
||||
|
||||
@@ -150,7 +149,7 @@ public class TvTEventTeam
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns name and instance of all participated players in FastMap<br>
|
||||
* Returns name and instance of all participated players in HashMap<br>
|
||||
* <br>
|
||||
* @return Map<String, L2PcInstance>: map of players in this team<br>
|
||||
*/
|
||||
|
||||
@@ -21,15 +21,14 @@ package com.l2jserver.gameserver.model.entity.clanhall;
|
||||
import java.sql.Connection;
|
||||
import java.sql.PreparedStatement;
|
||||
import java.sql.ResultSet;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Calendar;
|
||||
import java.util.Collection;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.ScheduledFuture;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import javolution.util.FastList;
|
||||
import javolution.util.FastMap;
|
||||
|
||||
import com.l2jserver.Config;
|
||||
import com.l2jserver.L2DatabaseFactory;
|
||||
import com.l2jserver.gameserver.ThreadPoolManager;
|
||||
@@ -74,8 +73,8 @@ public abstract class ClanHallSiegeEngine extends Quest implements Siegable
|
||||
|
||||
protected final Logger _log;
|
||||
|
||||
private final FastMap<Integer, L2SiegeClan> _attackers = new FastMap<>();
|
||||
private FastList<L2Spawn> _guards;
|
||||
private final HashMap<Integer, L2SiegeClan> _attackers = new HashMap<>();
|
||||
private ArrayList<L2Spawn> _guards;
|
||||
|
||||
public SiegableHall _hall;
|
||||
public ScheduledFuture<?> _siegeTask;
|
||||
@@ -151,7 +150,7 @@ public abstract class ClanHallSiegeEngine extends Quest implements Siegable
|
||||
{
|
||||
if (_guards == null)
|
||||
{
|
||||
_guards = new FastList<>();
|
||||
_guards = new ArrayList<>();
|
||||
try (Connection con = L2DatabaseFactory.getInstance().getConnection();
|
||||
PreparedStatement statement = con.prepareStatement(SQL_LOAD_GUARDS))
|
||||
{
|
||||
@@ -225,7 +224,7 @@ public abstract class ClanHallSiegeEngine extends Quest implements Siegable
|
||||
|
||||
// XXX Attacker clans management -----------------------------
|
||||
|
||||
public final FastMap<Integer, L2SiegeClan> getAttackers()
|
||||
public final HashMap<Integer, L2SiegeClan> getAttackers()
|
||||
{
|
||||
return _attackers;
|
||||
}
|
||||
@@ -262,7 +261,7 @@ public abstract class ClanHallSiegeEngine extends Quest implements Siegable
|
||||
@Override
|
||||
public List<L2SiegeClan> getAttackerClans()
|
||||
{
|
||||
FastList<L2SiegeClan> result = new FastList<>();
|
||||
ArrayList<L2SiegeClan> result = new ArrayList<>();
|
||||
result.addAll(_attackers.values());
|
||||
return result;
|
||||
}
|
||||
@@ -271,7 +270,7 @@ public abstract class ClanHallSiegeEngine extends Quest implements Siegable
|
||||
public List<L2PcInstance> getAttackersInZone()
|
||||
{
|
||||
final Collection<L2PcInstance> list = _hall.getSiegeZone().getPlayersInside();
|
||||
List<L2PcInstance> attackers = new FastList<>();
|
||||
List<L2PcInstance> attackers = new ArrayList<>();
|
||||
|
||||
for (L2PcInstance pc : list)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user