Jump to content

Question

2 answers to this question

Recommended Posts

  • 0
Posted (edited)
1 hour ago, Equi93 said:



can you help me fix this?

New Bitmap Image.jpg

its bad coded , update the sql connection and at least replace the player loop with : L2World.getInstance().getPlayer(playerName)

 

instead of a whole loop inside another loop.  it can be done like :

L2PcInstance player =  L2World.getInstance().getPlayer(playerName);

 

if(player != null && player.isOnline() == 1)

{

    add item etc.

}

 

final code 

 

if(id > 0 && count > 0 && !playername.isEmpty())

{

    L2PcInstance player =  L2World.getInstance().getPlayer(playerName);

     if(player != null && player.isOnline() == 1)

     {

        your code to add item here.

     }

}

 

Edited by AbsolutePower
Guest
This topic is now closed to further replies.


×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock