Jump to content

Recommended Posts

Posted

Based on this share:

 

http://www.maxcheaters.com/forum/index.php?topic=44025.0

 

The difference is in that share you get it with more work and with more time(because i think its very op in high rates if every hero has hero skills on all subclass).

So that give you all hero skills but only after x Counts(count means how many times you become a hero in row)

 

in L2PcInstance you can put it anywhere

public int getCount()
{

	String HERO_COUNT				= "SELECT count FROM heroes WHERE char_name=?";
	int _count = 0;
	Connection con = null;

	try
	{
		con = L2DatabaseFactory.getInstance().getConnection();
		PreparedStatement statement = con.prepareStatement(HERO_COUNT);
		statement.setString(1, getName());
		ResultSet rset = statement.executeQuery();
		while (rset.next())
		{
			_count=(rset.getInt("count"));
		}

		rset.close();
		statement.close();
	}
	catch (Exception e)
	{
	}
	finally { try { if (con != null) con.close(); } catch (SQLException e) { e.printStackTrace(); } }

	if (_count != 0)
		return _count;
	else
		return 0;
}

 

and the code that give you the skill.replace X with the count you want.

		if (hero && _baseClass == _activeClass)
	{
		for (L2Skill s : HeroSkillTable.getHeroSkills())
			addSkill(s, false); //Dont Save Hero skills to database
	}
	else if (getCount() >= x && hero)
	{
		for (L2Skill s : HeroSkillTable.getHeroSkills())
			addSkill(s, false); //Dont Save Hero skills to database
	}
	else

 

Credits to:

Cobra(the basic share that give the idea)

Rizel for some help

for me

  • 9 months later...
  • 2 weeks later...

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
Reply to this topic...

×   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...