Ashfell

Veteran
Veteran
Joined
May 31, 2017
Messages
103
Reaction score
33
First Language
english
Primarily Uses
RMMV
Im trying to find a way to change the color of the default text color for the menu HP,MP,TP and am having no luck anyone know ?
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
44,645
Reaction score
15,728
First Language
English
Primarily Uses
RMMV
Are you using plugins that affect menu appearance?

And do you mean the words HP, MP, TP, or the numbers?

From what I can see, it uses the system colour to draw the text, then a different colour for the text (tp/mp are normal colour - probably white-ish, hp depends on actor status), and then normal colour again for the max.
 

Ashfell

Veteran
Veteran
Joined
May 31, 2017
Messages
103
Reaction score
33
First Language
english
Primarily Uses
RMMV
I have no addons new project and they are all light blue and i mean HP MP TP the numbers are fine
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
44,645
Reaction score
15,728
First Language
English
Primarily Uses
RMMV
Save the following as a .js file in your js/plugins folder and add it to the plugin manager (doesn't matter what you call it, as long as the extension is .js)

Code:
Window_Base.prototype.drawActorHp = function(actor, x, y, width) {
    width = width || 186;
    var color1 = this.hpGaugeColor1();
    var color2 = this.hpGaugeColor2();
    this.drawGauge(x, y, width, actor.hpRate(), color1, color2);
    this.changeTextColor(this.systemColor()); // <<<<<< change this line
    this.drawText(TextManager.hpA, x, y, 44);
    this.drawCurrentAndMax(actor.hp, actor.mhp, x, y, width,
                           this.hpColor(actor), this.normalColor());
};

Window_Base.prototype.drawActorMp = function(actor, x, y, width) {
    width = width || 186;
    var color1 = this.mpGaugeColor1();
    var color2 = this.mpGaugeColor2();
    this.drawGauge(x, y, width, actor.mpRate(), color1, color2);
    this.changeTextColor(this.systemColor());  // <<<<<< change this line
    this.drawText(TextManager.mpA, x, y, 44);
    this.drawCurrentAndMax(actor.mp, actor.mmp, x, y, width,
                           this.mpColor(actor), this.normalColor());
};

Window_Base.prototype.drawActorTp = function(actor, x, y, width) {
    width = width || 96;
    var color1 = this.tpGaugeColor1();
    var color2 = this.tpGaugeColor2();
    this.drawGauge(x, y, width, actor.tpRate(), color1, color2);
    this.changeTextColor(this.systemColor());  // <<<<<< change this line
    this.drawText(TextManager.tpA, x, y, 44);
    this.changeTextColor(this.tpColor(actor));
    this.drawText(actor.tp, x + width - 64, y, 64, 'right');
};

There are 3 lines that say this.changeTextColor(this.systemColor()). Change systemColor() with whatever colour you want to use. The defined colours are listed from line 179 to 237 in rpg_windows.js (version 1.6.1) but if you don't want any of those, just use this.textColor(n) where n is a number corresponding to the swatches in the lower right of the window.png file in the img/system folder. The first one is 0, and they go up as you move to the right.
 

Ashfell

Veteran
Veteran
Joined
May 31, 2017
Messages
103
Reaction score
33
First Language
english
Primarily Uses
RMMV
ty that worked perfect
 

Latest Threads

Latest Profile Posts

After the initial success with one event, I set up four different events on the same map to detect who is in which slot in my current party, and fortunately it managed to work as intended, with the events changing image to match the party members even as I swapped their positions around in formation. This will be a great tool for immersive scene design.
Finally finished the first hand-drawn map! It took me a week, but I'm so proud!
Actual line of code I just had to write for a plugin:

return Object.keys(this._shopStock).map(key => key.split(",")).map(element => element.map(value => Number(value))).filter(key => key[0] === mapId && key[1] === eventId);

Forum statistics

Threads
118,447
Messages
1,116,056
Members
155,420
Latest member
catboyfirsttimer
Top