Remove Attack Command (Sometimes)

Hey all; new here, so forgive me if I make some error when posting this.


Essentially, my question is how I remove the attack command for certain characters under certain conditions. I can disable it easily enough, but I'd like to remove it from the window entirely to indicate that a certain class of character or a certain 'weapon' simply cannot be used for basic attacks. The same too goes for the Guard command.


(I'm still new to RPG Maker MV, so if anybody has the answer, please don't worry about patronising me by stating the obvious)


Thanks


x
You'll need a command manager plugin with options for dynamic command lists.


There are a few command managers available, but unfortunately I don't know if any has a dynamic options - commonly only static changes (give the actor its own command list for the entire game) are used.


I've moved this thread to Plugin Request. Please be sure to post your threads in the correct forum next time. Thank you.
Well you could use Yanfly's Skill Core to hide or show skills or commands with switches or other methods. Or you can use Hime's Actor Battle Command to change the battle command layout.
Thanks for your help: I've downloaded the Skill Core, and I'm fairly confident I can bodge a system where I remove the Default Attack and assign a new (identical) skill called Attack to every weapon/class that would enable it, but... I have no idea what to do with the plugin. I get that there are note-tags, but... where do I put them? Do I just simply stick them in the Notes section under skills? That doesn't seem right. Upon testing it, if that is right, I'm doing it wrong, because it's not hidden when I use the <Hide in Battle> Note Tag.


Forgive me if I'm missing something super-obvious, but... I think I'm missing something super-obvious. Thanks again.
Thanks for your help: I've downloaded the Skill Core, and I'm fairly confident I can bodge a system where I remove the Default Attack and assign a new (identical) skill called Attack to every weapon/class that would enable it, but... I have no idea what to do with the plugin. I get that there are note-tags, but... where do I put them? Do I just simply stick them in the Notes section under skills? That doesn't seem right. Upon testing it, if that is right, I'm doing it wrong, because it's not hidden when I use the <Hide in Battle> Note Tag.


Forgive me if I'm missing something super-obvious, but... I think I'm missing something super-obvious. Thanks again.



You can set it up like that and yes you put the note tags in the Notebox of the skill. You should have a plugin that came with MV that can replace the default skill with another skill. If you set it up correctly then any skills that you put  <Hide in Battle> shouldn't show up in the menu and if the character is wielding a weapon that replaces the hidden skill, the one attached to the weapon is shown.
Is it simply a case that Battle Test... doesn't really work? I haven't yet set up any encounters for this project so I wanted to test the Hide in Battle thing in the battle test.
Update: so I rigged a basic map to do an extended battle test, and I find that the Hide in Battle note tag only seems to disable the Attack command rather than remove it altogether. I've double-checked everything, and I can't see what I'm doing wrong. Any ideas?
I'm still stuck with this. It does seem like there's a solution, but I still don't really know how to implement it. Although I can use the default weapon skills plugin to change what Attack and Guard actually do, I can't for the life of me remove them from the menu entirely. In particular, I want to remove Guard from the project entirely so there's no point having it sit there in the menu as though it might crop up at some stage - it won't.
In your project folder go to the JS folder and open rpg_windows javascript file, then use cntl + f to search
" Window_ActorCommand.prototype.makeCommandList " . then delete this line " this.addAttackCommand(); ". That should work for you.
So if I understood this correctly, you want to hide attack/guard from the battle menu entirely when these skills are disabled?
If that is the case, you can use this script:

Code:
Window_ActorCommand.prototype.makeCommandList = function() {
    if (this._actor) {
        if (this._actor.canAttack) {
            this.addAttackCommand();
        }
        this.addSkillCommands();
        if (this._actor.canGuard()) {
            this.addGuardCommand();
        }
        this.addItemCommand();
    }
};
Add it as a plugin, don't edit rpg_windows.js directly.
@Doctor B use this Plugin.
Don't forget to give Credits.

It Gives you the option to Remove Either Attack or Guard command or both at the same time.

Original thread: https://forums.rpgmakerweb.com/threads/remove-attack-command-sometimes.58831/