Jump to content
  • 0

L2Champion Mod


Question

Posted

Hi guys. 

 

Short question. How could I disable the champion spawn for certain monsters with a certain title? The monster type is L2Monster, and the title is MonsterSpawn.

 

Would it be possible to exclude these mobs to be transformed into a champion mob?

 

		if (Config.L2JMOD_CHAMPION_ENABLE)
		{
			// Set champion on next spawn
			if (!(this instanceof L2GrandBossInstance) && !(this instanceof L2RaidBossInstance) && !(this instanceof L2ChestInstance) && !(getTemplate().title.contentEquals("MonsterSpawn") && (this instanceof L2MonsterInstance)
			&& (Config.L2JMOD_CHAMPION_FREQUENCY > 0) && (getLevel() >= Config.L2JMOD_CHAMP_MIN_LVL) && (getLevel() <= Config.L2JMOD_CHAMP_MAX_LVL)))
			{
				final int random = Rnd.get(100);
				if (random < Config.L2JMOD_CHAMPION_FREQUENCY)
				{
					setChampion(true);
				}
			}
		}

As you can see I tried with the getTemplte.title but I doesn't work.

Any help or hint would be great. Thanks!

1 answer to this question

Recommended Posts

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


×
×
  • Create New...

Important Information

This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue..