An open library of RPG Maker MZ plugins, powered by the community.

PGMZ - The Community-Driven Plugin Library for RPG Maker MZ

MZ plugins

NRP Battler Name Color - NRP_BattlerNameColor.js

Plugin desc : v1.00 Change the color of the battler's name according to the condition.

License :
・Copyright: Retained
・Commercial Use: Allowed
・Modification: Allowed
・Redistribution: Allowed
・Details: See Download Page / In-plugin documentation

Author : Takeshi Sunagawa (https://newrpg.seesaa.net/)

Website : https://github.com/NewRPGProject/MZMV_Plugin/blob/main/NRP_BattlerNameColor.js

Desc page : https://newrpg.seesaa.net/article/505945545.html

Download Page : https://raw.githubusercontent.com/NewRPGProject/MZMV_Plugin/main/NRP_BattlerNameColor.js

File name : NRP_BattlerNameColor.js

Help of plugin :

Change the color of the battler's name according to the condition.
 * Basically, it is intended to change when the enemy's HP is reduced.
 * 
 * In short, this is a feature found in Dragon Quest,
 * Octopath Traveler, etc.
 * It can be made conditional on something other than HP,
 * or applied to an actor.
 * 
 * The initial settings are as follows
 * 
 * - Changed to red on dead.
 * - Changes to yellow when dying (less than 25% HP)
 * - Changes to light blue when less than 50% HP
 * 
 * ※Dead and Dying are in accordance
 *   with RPG Maker's specifications (Actor).
 * ※Note the distinction between less than and less than or equal to.
 * ※Dead is for actor only.
 * ※The plugin also allows you to change the dying condition.
 * 
 * Incidentally, Dragon Quest and Octopath Traveler seem to be yellow
 * at less than 50% HP and red at less than 25% HP.
 * Note that if you imitate it as it is,
 * it will be out of alignment with the actor's display!
 * 
 * -------------------------------------------------------------------
 * [Usage]
 * -------------------------------------------------------------------
 * Register the settings in NameColorList.
 * The default settings are as follows.
 * If there is no problem, you may leave it as it is.
 * 
 * - Red (system color 18) when unable to dead (a.isDead())
 * - Yellow (system color 17) when dying (a.dying())
 * - Light blue (system color 4) when less than 50% HP (a.hpRate() < 0.5)
 * 
 * The setting on the top has priority over the setting on the bottom.
 * 
 * The default setting is not reflected on the actor,
 * so please switch it if necessary.
 * Note that the color of the actor's name is
 * linked to the color of its HP.
 * 
 * -------------------------------------------------------------------
 * [Terms]
 * -------------------------------------------------------------------
 * There are no restrictions.
 * Modification, redistribution freedom, commercial availability,
 * and rights indication are also optional.
 * The author is not responsible,
 * but will deal with defects to the extent possible.
 * 
 * @-----------------------------------------------------
 * @ [Plugin Parameters]
 * @-----------------------------------------------------
 * 
 * @param NameColorList
 * @type struct<NameColor>[]
 * @default ["{¥"Condition¥":¥"a.isDead()¥",¥"Color¥":¥"18¥"}","{¥"Condition¥":¥"a.isDying()¥",¥"Color¥":¥"17¥"}","{¥"Condition¥":¥"a.hpRate() < 0.5¥",¥"Color¥":¥"4¥"}"]
 * @desc Define text color conditions and colors.
 * 
 * @param ApplyEnemy
 * @type boolean
 * @default true
 * @desc Reflects the color change in the enemy name.
 * 
 * @param ApplyActor
 * @type boolean
 * @default false
 * @desc Reflects the color change in the actor name.
 * Note that it is also reflected in the HP display!
 * 
 * @param DyingCondition
 * @type string
 * @default a.hpRate() < 0.25
 * @desc This is a condition that is treated as dying in the system.
 * Default: a.hpRate() < 0.25

スポンサードリンク

-MZ plugins

Copyright© PGMZ - The Community-Driven Plugin Library for RPG Maker MZ , 2026 All Rights Reserved.