Jump to content
  • 0

[ask] Box limit only for Online pg


Question

10 answers to this question

Recommended Posts

  • 0
Posted

Check Enterworld.java and put condition

if(!activeChar.isOnline) 

u serious? this is not going to work.

 

You will need to do such check in EnterWorld at the beginning

String ip = activeChar.getClient().getConnection().getInetAddress().getHostAddress()
int onlinePerIp = 0;
for(L2PcInstance player : L2World.getInstance().getAllPlayers())//not sure about getAllPlayers, i dont remember method name.
if(player.getClient().getConnection().getInetAddress().getHostAddress().equals(ip))
{
onlinePerIp++;
if(onlinePerIp>=1)
{
getClient().closeNow();
return;
}

thats it i think, good luck :)

  • 0
Posted

@Jokkerino

I think that condition is useless. How is supposed anyone to be offline while logging in? O.o...

 

@author

Should be one method when a char logout that remove it from being found by dualbox limit.

You must find it and add into offline trader method.

 

Edit: maybe it's what vampir posted, it depends on how is your code working, did u show it to us?

  • 0
Posted

I don't see the path that has enterworld.java Q_Q

 

i dont know what u mean, enterworld is in client packets in network as i remember, u need to add my code after setting activeChar.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...