public int getPartiesInside(int zoneId)// Calculating parties inside party area.
{
int i = 0;
for (L2ZoneType zone : L2ZoneManager.getInstance().getZones(locationX, locationY, locationZ))
{
if (zone.getId() == zoneId)
{
for (L2Character character : zone.getCharactersInside())
{
if ((character instanceof L2PcInstance) && (!((L2PcInstance) character).getClient().isDetached()) && (((L2PcInstance) character).getParty() != null) && ((L2PcInstance) character).getParty().isLeader((L2PcInstance) character))
{
i++;
}
}
}
}
return i;
}
public int getPlayerInside(int zoneId)// Calculating players inside party area.
{
int i = 0;
for (L2ZoneType zone : L2ZoneManager.getInstance().getZone(locationX, locationY, locationZ))
{
if (zone.getId() == zoneId)
{
for (L2Character character : zone.getCharactersInside())
{
if ((character instanceof L2PcInstance) && (!((L2PcInstance) character).getClient().isDetached()))
{
i++;
}
}
}
}
return i;
}
zone.getCharactersInside()) and getZones in for (L2ZoneType zone : L2ZoneManager.getInstance().getZones(locationX, locationY, locationZ))
yes i have some attachments but they are totally disorganized, i added posts i could find that were made after the backup ive got. there still are some left to do.
when ill have the time ill update them.
old thread was locked and i couldnt update the url.
Question
MarGaZeaS
hello i have a small proble on frozen (4lines)
http://prntscr.com/loli61
public int getPartiesInside(int zoneId)// Calculating parties inside party area. { int i = 0; for (L2ZoneType zone : L2ZoneManager.getInstance().getZones(locationX, locationY, locationZ)) { if (zone.getId() == zoneId) { for (L2Character character : zone.getCharactersInside()) { if ((character instanceof L2PcInstance) && (!((L2PcInstance) character).getClient().isDetached()) && (((L2PcInstance) character).getParty() != null) && ((L2PcInstance) character).getParty().isLeader((L2PcInstance) character)) { i++; } } } } return i; } public int getPlayerInside(int zoneId)// Calculating players inside party area. { int i = 0; for (L2ZoneType zone : L2ZoneManager.getInstance().getZone(locationX, locationY, locationZ)) { if (zone.getId() == zoneId) { for (L2Character character : zone.getCharactersInside()) { if ((character instanceof L2PcInstance) && (!((L2PcInstance) character).getClient().isDetached())) { i++; } } } } return i; }zone.getCharactersInside()) and getZones in for (L2ZoneType zone : L2ZoneManager.getInstance().getZones(locationX, locationY, locationZ))
all code about npc
Edited by MarGaZeaS1 answer to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now