showChatWindow(player, "residence2/clanhall/game_manager014.htm");
return;
}
if (siegeClan.getPlayers().isEmpty())
{
Party party = player.getParty();
if (party == null)
{
showChatWindow(player, player.isClanLeader() ? "residence2/clanhall/game_manager005.htm" : "residence2/clanhall/game_manager002.htm");
return;
}
if (!player.isClanLeader())
{
showChatWindow(player, "residence2/clanhall/game_manager004.htm");
return;
}
if (party.getMemberCount() < 5)
{
showChatWindow(player, "residence2/clanhall/game_manager003.htm");
return;
}
if (party.getPartyLeader() != player)
{
showChatWindow(player, "residence2/clanhall/game_manager006.htm");
return;
}
for (Player member : party.getPartyMembers())
{
if (member.getClan() != player.getClan())
{
showChatWindow(player, "residence2/clanhall/game_manager007.htm");
return;
}
}
int index = siegeClans.indexOf(siegeClan);
SpawnExObject spawnEx = miniGameEvent.getFirstObject("arena_" + index);
Location loc = (Location) spawnEx.getSpawns().get(0).getCurrentSpawnRange();
for (Player member : party.getPartyMembers())
{
siegeClan.addPlayer(member.getObjectId());
member.teleToLocation(Location.coordsRandomize(loc, 100, 200));
}
}