MV SOLVED Keep skills from being greyed out in Skill Menu even if unusable.

I did not see an answer to this question while searching, so I figure it best to ask. Hopefully this is the correct section for what I am aiming to do.

I am building a game that doesn't have any skills able to be used outside of the battle scene. However, I still want all skills to appear with full brightness in the skill menu outside of battle as if they were usable. Mainly for visual ease. I don't want to change any other settings regarding brightness outside of the skill menu, nor do I intend to activate these skills to be used inside this menu either.

Is there an easy enough solution to do this? Thank you.

Picture below to highlight what I mean. Ideally all skills should have the same color and brightness as the 'apply state' skill, without affecting their brightness/dimness in other areas of the game (such as the battle scene, where skills that are unable to be used will maintain the faded visual effect).

1715238949769.png
Not sure if this will work but worth a shot, try adding /c[0] before the skill's names in your database to force them to stay white. Not sure if that will override the greyed out functionality or not.
Thank you, unfortunately the skills remain greyed out even with color codes added. Even if this did work however, it would also apply to the skill screen in the battle scene as well, meaning skills that are unable to be used would then appear usable.
find drawItemName() in the code, I forget where it is, there's a line that says change_color(color, [ENABLED])
that [ENABLED] is passed as a parameter, based on whether the item is usable or not (comes from the menu object, to the list object where drawitemname() runs)
comment it out, or change the parameter to true.
find drawItemName() in the code, I forget where it is, there's a line that says change_color(color, [ENABLED])
that [ENABLED] is passed as a parameter, based on whether the item is usable or not (comes from the menu object, to the list object where drawitemname() runs)
comment it out, or change the parameter to true.

Hey, thank you for that. That actually did it. The line in question is Window_SkillList.prototype.drawItem = function(index) {
found in rpg_windows.js

I commented out the following line.

JavaScript:
Window_SkillList.prototype.drawItem = function(index) {
    var skill = this._data[index];
    if (skill) {
        var costWidth = this.costWidth();
        var rect = this.itemRect(index);
        rect.width -= this.textPadding();
//        this.changePaintOpacity(this.isEnabled(skill));
        this.drawItemName(skill, rect.x, rect.y, rect.width - costWidth);
        this.drawSkillCost(skill, rect.x, rect.y, rect.width);
        this.changePaintOpacity(1);
    }
};

Will move this to my own plugin so the changes are not reverted in case of an update to the default scripts.

SOLVED (as far as it appears anyways)

On further inspection, this also prevents the skills in the battle scene from becoming greyed out when unusable. Perhaps I am working with the wrong function here. Will mess around and see if I can find anything more specific to just the skill window in the standard menu.

Since it appears that this function applies globally, the best solution that I can think of would be to include a conditional check to not call this.changePaintOpacity(this.isEnabled(skill)); when the standard menu is open, or rather to only call it when the standard window is not open.

Any input as how to go about this would be appreciated, as well as another solution that I may be overlooking.
Will mess around and see if I can find anything more specific to just the skill window in the standard menu.
you gonna have to duplicate drawItemName from window_Base over to the skill window then, without the call to change color.
drawItemName should be common to both items and skills, as they're both items to the code.

make drawItemName a local override to Window_Base.drawitemname(), within the skill list.
notice that there's Scene_Skill (the menu outside of battle) that calls Window_SkillList, and Window_BattleSkill that is used within Scene_Battle.
override as needed.
you gonna have to duplicate drawItemName from window_Base over to the skill window then, without the call to change color.
drawItemName should be common to both items and skills, as they're both items to the code.

make drawItemName a local override to Window_Base.drawitemname(), within the skill list.
notice that there's Scene_Skill (the menu outside of battle) that calls Window_SkillList, and Window_BattleSkill that is used within Scene_Battle.
override as needed.
You don't have to do this, just add an

if $gameParty.inBattle()

condition to the call to changePaintOpacity.
You don't have to do this, just add an

if $gameParty.inBattle()

condition to the call to changePaintOpacity.
Thank you to both of you for the assistance. What would be the version of this for the skill menu screen? I am using a custom battle system and have other instances outside of battle where I would like to keep the opacity change.

Something like

if $gameParty.inSkillMenu()


Actually that ended up working perfectly. I changed the line referenced above to the following.

JavaScript:
Window_SkillList.prototype.drawItem = function(index) {
    var skill = this._data[index];
    if (skill && $gameParty.inBattle() ) {
        var costWidth = this.costWidth();
        var rect = this.itemRect(index);
        rect.width -= this.textPadding();
        this.changePaintOpacity(this.isEnabled(skill));
        this.drawItemName(skill, rect.x, rect.y, rect.width - costWidth);
        this.drawSkillCost(skill, rect.x, rect.y, rect.width);
        this.changePaintOpacity(1);
    } else if (skill) {
        var costWidth = this.costWidth();
        var rect = this.itemRect(index);
        rect.width -= this.textPadding();
//        this.changePaintOpacity(this.isEnabled(skill));
        this.drawItemName(skill, rect.x, rect.y, rect.width - costWidth);
        this.drawSkillCost(skill, rect.x, rect.y, rect.width);
        this.changePaintOpacity(1);
    }
};

I am sure there is a cleaner way to do this but I am perfectly fine with this.

Thread SOLVED!
Thank you to both of you for the assistance. What would be the version of this for the skill menu screen? I am using a custom battle system and have other instances outside of battle where I would like to keep the opacity change.

Something like

if $gameParty.inSkillMenu()


Actually that ended up working perfectly. I changed the line referenced above to the following.

JavaScript:
Window_SkillList.prototype.drawItem = function(index) {
    var skill = this._data[index];
    if (skill && $gameParty.inBattle() ) {
        var costWidth = this.costWidth();
        var rect = this.itemRect(index);
        rect.width -= this.textPadding();
        this.changePaintOpacity(this.isEnabled(skill));
        this.drawItemName(skill, rect.x, rect.y, rect.width - costWidth);
        this.drawSkillCost(skill, rect.x, rect.y, rect.width);
        this.changePaintOpacity(1);
    } else if (skill) {
        var costWidth = this.costWidth();
        var rect = this.itemRect(index);
        rect.width -= this.textPadding();
//        this.changePaintOpacity(this.isEnabled(skill));
        this.drawItemName(skill, rect.x, rect.y, rect.width - costWidth);
        this.drawSkillCost(skill, rect.x, rect.y, rect.width);
        this.changePaintOpacity(1);
    }
};

I am sure there is a cleaner way to do this but I am perfectly fine with this.

Thread SOLVED!
JavaScript:
Window_SkillList.prototype.drawItem = function(index) {
    var skill = this._data[index];
    if (skill) {
        var costWidth = this.costWidth();
        var rect = this.itemRect(index);
        rect.width -= this.textPadding();
        if ($gameParty.inBattle()) {
          this.changePaintOpacity(this.isEnabled(skill));
        }
        this.drawItemName(skill, rect.x, rect.y, rect.width - costWidth);
        this.drawSkillCost(skill, rect.x, rect.y, rect.width);
        this.changePaintOpacity(1);
    }
};
Ok, that is a lot cleaner. I had tried that at first but it looks like I botched it because I forgot the extra set of () around $gameParty. Should probably finish drinking my coffee before I try to do anything syntax related 😅

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/solved-keep-skills-from-being-greyed-out-in-skill-menu-even-if-unusable.168497/