4.0 Condition-System Revamp

The condition system of MythicMobs has undertaken some pretty nifty changes and we hope you guys will find it as fascinating and useful as we do! We have been putting quite some effort into quasi “remaking” it and are very happy with the newly found powers which it provides.

None of the conditions you were previously able to use with MythicMobs are gone - they are in-fact all still there and we even added a bunch of new ones. The most important part about this change is how the system now works and the new possibilities it offers.

Old conditions were very basic and only executed on the mob and/or the mob's target. The new system now works according to one of three ways: on the skill's caster, on the skill's target, or on the entity that triggered the skill. Conditions are now also divided into Entity conditions and Location conditions, similar to skill mechanics.

NOTE: You can still use old conditions by instead using “LegacyConditions:” For example: The new version of targetlineinsight would be:

  - lineofsight true
The old version can still be used like this:
  - targetlineofsight true

Read on for further details on how to use each type of condition.


Conditions now have an updated format. Most old conditions should work the way they did, but conditions can now optionally include multiple options and actions.

The new format(s) work like so:

- condition [variable]
- condition [variable] [action]
- condition [variable] [action] [action_variable]
- condition{variable1=value;variable2=value} [action] [action_variable]

The old format will still work in most cases and the majority of skills should not break. However, this also allows for more advanced conditions that can evaluate multiple variables.

All of these are valid examples of the new format:

- day required
- stance defensive power 0.5
- stance{stance=defensive} power 0.5
- score{objective=test;value=>20} cancel
- haspotioneffect{type=POISON;level=>0;duration=0 to 100} true


The “Conditions” field on skills now specifically always evaluates the condition against the caster. The condition failing means that the skill will not trigger.


The “TargetConditions” field on skills lets you run a skill only on targets that meet the conditions. Any targets inherited by the skill will be filtered according to the conditions, and targets that do not meet them will be removed from the skill's target list.


# Mob
  Type: ZOMBIE
  - skill{s=Flare} @PlayersInRadius{r=20}
# Skill
  - lineofsight true
  - ignite{d=10}

The skill in this example would only ignite targets that were in the mob's line of sight.


The “TriggerConditions” field on skills specifically always evaluates the condition against the entity that triggered the skill. The condition failing means that the skill will not trigger.

  - entitytype ZOMBIE true

This example skill would not cast unless the triggering entity was a zombie.

Condition Actions

Condition Actions are a new feature that allow you to do additional things based off of conditions. Before conditions were always a “requirement”, but now you can specify other meanings for them.

Here is a list of actions being added:

  • required (or true) (default) - The condition is required for the skill to run.
  • cancel (or false) - The skill will not run if this condition is met.
  • power [power multiplier] - Modifies the skill's power (e.i. power 2.0 would double the skill's power)
  • cast [skill] - NOT YET IMPLEMENTED Casts an additional skill if the condition is met.
  • castinstead [skill] - NOT YET IMPLEMENTED Casts a different skill instead if the condition is met.


NEW: Altitude Condition

* Detects the targets height above the ground.
* Can be a single number, a range (20-40), or >10 <5, etc.

NEW: Crouching Condition

* Detects if the entity (must be a player) is crouching.

NEW: Distance Condition

* Checks the distance between the target and the casting entity.

NEW: EntityType Condition

* Detects if the target matches the entitytype.

  - entitytype PLAYER true

NEW: FallSpeed Condition

* Detects falling speed of the mob. Can be positive or negative. (For jumping.)
* Can be a single number, a range (20-40), or >10 <5, etc. Example:

- fallspeed{speed=>0.7845} true

NEW: Gliding Condition

* Checks target to see if it is gliding with elytra.

NEW: HasPotionEffect Condition

* Checks the target to see if it has the potion effect.
* You can specify a number of options, including the level of the effect, and the duration.

- haspotioneffect{type=POISON;level=>1;duration=0 to 100} true
This will only work if the target has the poison effect at a level of 2 or above, and a duration of 0 to 100 ticks.

NEW: HasTag Condition

* Checks target for scoreboard tags. Can be added using Add Tag mechanic.

  - hastag{tag=Test} true

NEW: LineOfSight Condition

* Checks if the entity can see its target/if there are no blocks in the way.

NEW: OnGround Condition

* Checks if the caster is on the ground. Pretty self-explanatory.

NEW: Score Condition

* Replaces the old targetscore and mobscore mechanics.
* Can be a single number, a range (20-40), or >10 <5, etc.

- score{objective=test;v=>20} true
Only will run when the objective “test” has a value of more than 20 for the target.



NEW: Interactable: [true/false]



NEW: AddTag

Adds a scoreboard tag to a target entity.

NEW: CancelEvent

CancelEvent will cancel whatever event triggered the skill.

This mechanic has several important requirements in order to execute properly:

  • The mechanic (or the first skill that leads to it) must be run with sync=true in the mob's skill list.
  • There can be no “delays” leading to its execution (no delay mechanics, and nothing else with delays such as projectiles)
  • It only works with specific triggers that make sense (works with onDamaged, onAttack, etc but not onDeath!)

NEW: Lunge

Accelerates the caster towards the target.

NEW: RemoveTag

Removes a scoreboard tag from a target entity.

NEW: SetHealth

NEW: SetMaxHealth

NEW: SetOwner

NEW: SudoSkill

The SudoSkill mechanic allows you to force the targeted entity to “cast” a MythicMobs skill. This skill will inherit the previous targets in the stack from a previous parent skill, and is even able to force players to use MythicMobs skills.


  • fromOrigin now defaults to false.


  • Added startYoffset attribute.


  • Added owner to targets.

Target filters

  • Added samefaction to target filters.

API Update

The API has been changed significantly in this update, and comes with many new improvements. Plugins that used MythicMobs prior to 4.0 will need to be recompiled using the new API, though.

Information about the new API will be expanded on in the future.


JavaDocs for the API can now be found at http://www.mythicmobs.net/javadocs

Custom Mechanics

Developers can now add custom mechanics to MythicMobs at runtime using the MythicMechanicLoadEvent. Examples will be available on the manual and in the API forum.

Custom Conditions

Developers can now add custom mechanics to MythicMobs at runtime using the MythicConditionLoadEvent. Examples will be available on the manual and in the API forum.

New API Events

  • MythicConditionLoadEvent - Called on startup/reload for each custom condition referenced in the plugin.
  • MythicMechanicLoadEvent - Called on startup/reload for each custom condition referenced in the plugin.
  • MythicReloadedEvent - Called after MythicMobs finishes reloading



  • Fixed several issues with MPets compatibility

Bug Fixes / Other

  • Fixed issues with 1.11 support
  • Fixed mob eggs
  • Fixed various bugs with spawners
  • Many, many other bug fixes

4.0.x_changelogs.txt · Last modified: 2020/06/30 21:13 (external edit)