Difference between revisions of "EliteMobs/指南/创建自定义Boss"
|Line 12:||Line 12:|
|Line 47:||Line 47:|
== 是否启用 ==
== 是否启用 ==
== 实体类型 ==
== 实体类型 ==
Latest revision as of 15:07, 9 April 2021
|自定义附魔||喷火 · 钻孔 · 星陨 · 精英锋利 · 精英保护 · 致命打击 · 破冰 · 灵魂绑定|
- 1 创建自定义boss
/em spawn [customboss] [level]指令或使用spawnChance配置选项生成。高级生成选项只在7.2.0版本后才有。
isEnabled: true entityType: ZOMBIE name: '&eTest boss' level: dynamic timeout: 10 isPersistent: false healthMultiplier: 2.0 damageMultiplier: 0.5 helmet: GOLDEN_HELMET chestplate: IRON_CHESTPLATE leggings: LEATHER_LEGGINGS boots: CHAINMAIL_BOOTS mainHand: GOLDEN_AXE offHand: SHIELD isBaby: false powers: - invulnerability_knockback.yml spawnMessage: A test boss has been spawned! deathMessage: A test boss has been slain by $players! escapeMessage: A test boss entity has escaped! locationMessage: 'Test entity: $location' uniqueLootList: - magmaguys_toothpick.yml:1 dropsEliteMobsLoot: true dropsVanillaLoot: true trails: - BARRIER onDamageMessages: - I've hit you! onDamagedMessages: - I've been hit! spawnChance: 0
entityType sets the type of entity the Boss Mob will be. This uses the Spigot API values which you can find here. Only entity types that can be Elite Mobs in the first place can be Custom Bosses (the entities in the mobproperties folder).
name sets the display name of the Custom Boss. If you want to use color codes, make sure you surround your name with '' (such as '&2Test')
level sets the level of the Custom Boss. The valid options for these are:
- Any positive natural numeric value
Using a positive natural number (such as a number between
1500) will force the Custom Boss to always use that level.
dynamic sets the mob level to be challenging for the highest tier player currently online. As such, no one in the server will find it easy to kill, although lower tier players will have a particularly hard time at it. Also note that this is ignored in the spawn command, as you set the level in the command arguments.
timeout sets the amount of time, in minutes, that passes before the Custom Boss "escapes" or, in other words, automatically despawns. When set to
0, the Custom Boss will never despawn from a timeout.
isPersistent sets whether the Custom Boss can survive a chunk unload. This is recommended for big bosses, but not for minions / trash mobs. Too many active persistent Custom Bosses may cause some performance issues (when in the hundreds).
healthMultiplier modifies the amount of hit necessary to kill a Custom Boss. Values between
0.9999 lower the amount of hits needed to kill the Custom Boss. Values above
1 increase the amount of hits needed to kill the Custom Boss. This multiplier doesn't actually change the health, just give it damage reduction or damage increase (armor), but it is called
healthMultiplier for the sake of simplicity.
damageMultiplier modifies the damage the Custom Boss deals to players. Values between
0.9999 lowers the damage. Values above
1 increase it. Does not affect the custom damage of some very specific powers (such as the GoldShotgun).
offHand set the items in those slots. This uses the Spigot API values which you can find here. This only affects entity types that can wear armor.
isBaby sets whether that Custom Boss is spawned as a baby entity. This is only applicable for entity types that can have baby entity variants, such as Zombies.
powers lists the powers that the Custom Boss has. These powers are the filenames of the powers that can be found the in
~/EliteMobs/powers directory. Some entity types can't have certain powers, and though I can not provide a full list of incompatibilities, I'll let you know that the Phantom entity is prone to causing a some issues. These are not fixable, as they are vanilla Minecraft limitations.
spawnMessage sets the message that gets broadcasted to players upon Custom Boss spawn.
deathMessage sets the message that gets broadcasted to players upon Custom Boss death. This uses the `$players$ placeholder which gets replaced with a list of all the players that participated in killing the Custom Boss using their display name.
deathMessages sets a list of messages that get broadcasted to players upon Custom Boss Death. This is far more extensive than the deathMessage option, and follows this format:
escapeMessage sets the message that gets broadcasted to players upon Custom Boss escape. This only happens if a
timeout time has been set for the Custom Boss, and when that time has elapsed.
deathMessages: - '&e&l---------------------------------------------' - '&4The Test Boss has been killed!' - '&c&l 1st Damager: $damager1name &cwith $damager1damage damage!' - '&6&l 2nd Damager: $damager2name &6with $damager2damage damage!' - '&e&l 3rd Damager: $damager3name &ewith $damager3damage damage!' - '&4Slayers: $players' - '&e&l---------------------------------------------'
As you can see, it uses the following placeholders:
$damager1name etc. display the display name of the player.
$damager1damageetc. display the damage the player has dealt to the boss throughout the fight.
$players displays a list of all damagers. Numbers 1-3 go through players from the highest damage dealt to the lower damage dealt.
locationMessage sets the message shown in the BossBar. This is used to track both Custom Boss health and its location in the server. It uses the
$location placeholder which gets automatically replaced with the custom boss' coordinates. The
$location placeholder can be removed from the message (or the entire configuration option can be removed) for server that do not wish to display the locations near player bases.
uniqueLootList sets the loot that drops from the custom boss. This is a list of items which follows the following format:
item field is filled with the file name of the custom item in the
~/EliteMobs/customitems directory. In our case, it's
chanceToDrop is a value between
1 which expresses the odds of the item dropping.
0 expresses a 0% chance to drop, whereas
1 expresses a 100% chance to drop.
0.5 is 50%.
The item dropped does not necessarily have to have the
dropsEliteMobsLoot sets whether the Custom Boss will drop EliteMobs loot, excluding items in the
uniqueLootList. This affects the loot that would drop from a normal Elite Mob and the loot shower coins. It is highly recommended that you disable this for trash mobs and reinforcement mobs.
dropsVanillaLoot sets whether the Custom Boss will drop the vanilla loot usually associated to its vanilla mob type.
trails sets the type of trail that the Custom Boss have. These are a list, so multiple can be selected (and repeatedly) to craft unique effects. Trails can both be particles or items. Both particles and item names have to be pulled from the Spigot API - here for items and here for trails.
onDamageMessage sets the message that the Boss Mob displays when they hit a player. This is a list, and the one used is randomized from the list.
onDamagedMessage sets the message that the Boss Mob displays when damaged by a player. This is a list, and the one used is randomized from the list.
spawnChance sets the chance of the custom boss spawning naturally. The odds are contained between
0 is a 0% chance and
1 is a 100% chance (
0.5 is a 50% chance). Only Elite Mobs of the same type are eligible for becoming Custom Bosses. This means that if you set your
0.5 and your custom boss is a Blaze entity type, every time an Elite Blaze spawns there's a 50% chance that it will become your Custom Boss. I recommend you keep the odds of conversion between 1/100 and 1/1000 (
0.001) depending on how many players you have and how rare you want your Custom Boss to be.
mountEntity allows the Custom Boss to mount an entity. Two types of values are allowed here:
- Entity types from the spigot api if you want your boss to mount a normal mob (example:
- File names of custom bosses if you want your custom boss to mount another custom boss (example:
Regional bosses will share their leash with the entity they're mounting, meaning they'll both be dragged back to the spawn location if they exceed the distance allowed by their leash.
announcementPriority sets the priority level for the spawn/kill/escape announcements and allows or prevents the Custom Boss from being tracked by players. The accepted values are
3, with the default being 1. You can click here for more details on how the Announcement Priority System works.
Here's an example of a boss that is trackable, is able to send spawn/death/escape messages on chat and on Discord:
Note: You will have to configure the spawnMessage, deathMessage/deathMessages, escapeMessage for chat and discord announcements and the locationMessage for the tracking feature if you wish to use the corresponding Announcement Priority level.
followDistanceset the Minecraft follow distance attribute. This is used to set custom aggro distances. Note that this sometimes does not work properly for certain mob types due to inconsistencies with Minecraft AI.
followDistance: 30 sets a range of 30 blocks where if a player gets within that distance near the boss it will start chasing/attacking the player.
``Note:** The higher the followDistance, the more intensive the boss. Try to keep these reasonable and make sure you only use them when it matters.
onDeathCommandssets the list of commands to run on custom boss death. The list supports the following placeholders:
$level for the level of the Elite Mob,
$name for the name of the Elite Mob and
$players for the players that killed the elite mob.
Please note that this probably doesn't work the way you assume it does! The
$players placeholder will make the command run multiple times and each time it will replace the placeholder with the name of a player who damaged the Elite Mob. As an example:
onDeathCommands: - broadcast $players has killed $name! That was level $level!
If Player1, Player2 and Player3 all damaged the boss before killing it, this is what the command output will be from console:
broadcast Player1 has killed CustomBossName! That was level X! broadcast Player2 has killed CustomBossName! That was level X! broadcast Player3 has killed CustomBossName! That was level X!
The main goal of this command is not to broadcast messages, but to allow admins to give specific non-elitemobs rewards to players for killing Elite Mobs.