applyLevelToMob

open override fun applyLevelToMob(lmEntity: LivingEntityWrapper, level: Int, isSummoned: Boolean, bypassLimits: Boolean, additionalLevelInformation: MutableSet<AdditionalLevelInformation>?)

This method applies a level to the target mob.

You can run this method on a mob regardless if they are already levelled or not.

This method DOES NOT check if it is LEVELLABLE. It is assumed that plugins make sure this is the case (unless they intend otherwise).

It is highly recommended to leave bypassLimits = false, unless the desired behaviour is to override the user-configured limits.

Thread-safety intended, but not tested.

Parameters

lmEntity

target mob

level

the level the mob should have

isSummoned

if the mob was spawned by LevelledMobs, not by the server

bypassLimits

whether LM should disregard max level, etc.

additionalLevelInformation

used to determine the source event