Jump to content

Recommended Posts

Posted (edited)

dude i think you made a logical mistake, in community patch you have this

else if(command.startsWith("_bbsrps") && RankPvpSystemConfig.RANK_PVP_SYSTEM_ENABLED && RankPvpSystemConfig.TOP_LIST_ENABLED)
{
     RankPvpSystemBBSManager.getInstance().parsecmd(command, activeChar);
}
 
and in that method you call you check if top lists are enabled else do something else i think it will always be true ;)
correct me if i am wrong
Edited by valanths1990
Posted

I think it is correct:

else if(command.startsWith("_bbsrps") && RankPvpSystemConfig.RANK_PVP_SYSTEM_ENABLED && RankPvpSystemConfig.TOP_LIST_ENABLED)
{
     RankPvpSystemBBSManager.getInstance().parsecmd(command, activeChar);
}
else if (command is fetched AND rank pvp system enabled AND top list enabled)
{
       do something...
}

If one of conditions returns false, the code inside will be not executed.

 

Example: if TOP_LIST_ENABLED is FALSE then the code inside will be skipped.

Posted (edited)

Not used it, nor checked the code, but the Rank System may refer to few options, like top pvp/pk. So, you can just enable for example JUST pk list, so the check is correct.

Edited by SweeTs
Posted (edited)

valanths1990

 

CommunityBoard:







// Rank PvP System by Masterio
else if(command.startsWith("_bbsrps"))
{ 
	RankPvpSystemBBSManager.getInstance().parsecmd(command, activeChar);
}

RankPvpSystemBBSManager:

	@Override
	public void parsecmd(String command, L2PcInstance activeChar)
	{
		if(RankPvpSystemConfig.RANK_PVP_SYSTEM_ENABLED && RankPvpSystemConfig.TOP_LIST_ENABLED)
		{
			if(command.startsWith("_bbsrps:"))
			{
				int page = 0;
				try
				{
					page = Integer.parseInt(command.split(":", 2)[1].trim());
				}
				catch(Exception e)
				{
					log.info(e.getMessage());
					page = 0;
				}
				
				separateAndSend(RankPvpSystemBBSHtm.getPage(activeChar, page), activeChar);
			}
		}
		else if(!RankPvpSystemConfig.TOP_LIST_ENABLED)
		{
			ShowBoard sb = null;

			sb = new ShowBoard("<html><body><br><br><center>Community Board Top List is disabled in config file</center><br><br></body></html>", "101");

			activeChar.sendPacket(sb);
			activeChar.sendPacket(new ShowBoard(null, "102"));
			activeChar.sendPacket(new ShowBoard(null, "103"));
			
			sb = null;
		}
	}

Fixed.

Edited by >Masterio<
Posted

First af all your share is awesome...thanks

 

But i have a little problem with TopTable, my top killers, top gatherers never update. It always says the message "No one ot top 10 list yet"

 I am using l2frozen(Iinterlude)

Posted

Hi, I have problem with PvP Count, I use Freya version, but I always get the notice: 

 

You can't earn RPC on innocent players!

You can't earn Rank Points on innocent players!

 

If I disable it, only receive PvP when kill Karma player, please help me

Guest
This topic is now closed to further replies.



×
×
  • Create New...