Offline Shops ip
Forum rules
READ NOW: L2j Forums Rules of Conduct
READ NOW: L2j Forums Rules of Conduct
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Offline Shops ip
Hi
How can i make it that offline shops not be counted
I have Maximum number of players per IP 5
but if i put 2 offline shops to server i can put only 3 online charts.
how can i make it i can log 5 charts to game and still got ofline shops at the server.
thanks
How can i make it that offline shops not be counted
I have Maximum number of players per IP 5
but if i put 2 offline shops to server i can put only 3 online charts.
how can i make it i can log 5 charts to game and still got ofline shops at the server.
thanks
- LasTravel
- Posts: 888
- Joined: Tue Jan 05, 2010 12:08 am
- Location: Spain
Re: Offline Shops ip
Dont count detached clients from the same ip.
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Re: Offline Shops ip
can you tell me how do I do thatLasTravel wrote:Dont count detached clients from the same ip.
- LasTravel
- Posts: 888
- Joined: Tue Jan 05, 2010 12:08 am
- Location: Spain
Re: Offline Shops ip
Show me your code and I'll tell you how to change it.
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Re: Offline Shops ip
thanksLasTravel wrote:Show me your code and I'll tell you how to change it.
But If you can tell me what code you want to see from me?
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Re: Offline Shops ip
Someone tell me wat to need to change thisAttila wrote:thanksLasTravel wrote:Show me your code and I'll tell you how to change it.
But If you can tell me what code you want to see from me?
-
- L2j Senior Developer
- Posts: 795
- Joined: Sun Aug 14, 2005 11:27 am
Re: Offline Shops ip
LasTravel means you have to do this in java. Instead of counting all players which are returned by L2World#getAllPlayers(), you need to loop through the array returned by L2World#getAllPlayers() and only count the players with a network connection. Something like
Code: Select all
L2PcInstance[] worldPlayers = L2World.getInstance().getAllPlayers();
int actualOnlinePlayers = 0;
for (L2PcInstance worldPlayer : worldPlayers)
{
if (!worldPlayer.getConnection().isDetached())
{
++actualOnlinePlayers;
}
}
Away cause of a bulding side in my place.
H5 GeoData from Nos & FBIagent
GoD Ch3 Lindvior GeoData from Nos & FBIagent
Yet another Buffer (Freya & HighFive)
Party Teleporter (Freya & HighFive)
FBIagent
H5 GeoData from Nos & FBIagent
GoD Ch3 Lindvior GeoData from Nos & FBIagent
Yet another Buffer (Freya & HighFive)
Party Teleporter (Freya & HighFive)
FBIagent
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Re: Offline Shops ip
Sorry but were do i need to change this ?HorridoJoho wrote:LasTravel means you have to do this in java. Instead of counting all players which are returned by L2World#getAllPlayers(), you need to loop through the array returned by L2World#getAllPlayers() and only count the players with a network connection. Something likeCode: Select all
L2PcInstance[] worldPlayers = L2World.getInstance().getAllPlayers(); int actualOnlinePlayers = 0; for (L2PcInstance worldPlayer : worldPlayers) { if (!worldPlayer.getConnection().isDetached()) { ++actualOnlinePlayers; } }
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Re: Offline Shops ip
Someone can explain what i need to do pleaseHorridoJoho wrote:LasTravel means you have to do this in java. Instead of counting all players which are returned by L2World#getAllPlayers(), you need to loop through the array returned by L2World#getAllPlayers() and only count the players with a network connection. Something likeCode: Select all
L2PcInstance[] worldPlayers = L2World.getInstance().getAllPlayers(); int actualOnlinePlayers = 0; for (L2PcInstance worldPlayer : worldPlayers) { if (!worldPlayer.getConnection().isDetached()) { ++actualOnlinePlayers; } }
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Re: Offline Shops ip
help how do i make this work
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Re: Offline Shops ip
can someone tell me how i can do this
I really don't not how I how I do this
Please help
thanks
I really don't not how I how I do this
Please help
thanks
- LasTravel
- Posts: 888
- Joined: Tue Jan 05, 2010 12:08 am
- Location: Spain
Re: Offline Shops ip
You have an example at this post, no one will do it for you.
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Re: Offline Shops ip
LasTravel wrote:You have an example at this post, no one will do it for you.
i don't no were do i made to change it
where do need to look to what file
What is the file name ?
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Re: Offline Shops ip
In what java file i need to look can you tell me were pleaseLasTravel wrote:You have an example at this post, no one will do it for you.