Hey! Question for you: I have a script right now that updates the help window in the Skill Menu scene with a description I set for each skill type. It works just fine with your plugin, but it's a bit of a hassle having to set the description for each skill type twice. Any way to modify it or adapt it to load the same description I set in your plugin parameters?
Great plugin by the way, I've been looking for exactly this functionality so I appreciate it!
(() => {
// Override the updateHelp method for Window_SkillType
Thank you for the praise and patronage, much appreciated 😊
Yes, you can retrieve this info through my plugin’s API.
(() => {
// Override the updateHelp method for Window_SkillType
Window_SkillType.prototype.updateHelp = function() {
const skillTypeId = this.currentExt(); // Get the skill type ID from the command
const bcd = TS_Battle_Command_Descriptions.parameters.battleCommandDescriptions
.find(bcd => bcd.skillTypeIds.includes(skillTypeId));
if (bcd) this._helpWindow.setText(bcd.description);
else this._helpWindow.setText(""); // Default empty text
};
})();
I haven’t tested this, but it should work. It’s not necessary to include null/undefined checks for most properties in my plugins since I normalise them to always be populated.
Hi, I have a setup in which all the skills are shown in the actor command window (so no SKILLS or MAGIC option). I tried your plugin, but it does not show the description for these skills aside from ATTACK and GUARD. Could you improve the plugin so that it shows the skill description of other skills as well? From your plugin description I assumed that it would do just that... but now I have empty windows.
You’re using VisuMZ_1_BattleCore to set up the menu, right?
Due to its obfuscation and lack of public API, I don’t support its custom features directly.
That said, you can load your code as separate plugin after mine, to make it easier to update my code:
'use strict';
// Untested, but very likely to work.
const oldGetActorCommandHelp = TS_Battle_Command_Descriptions.getActorCommandHelp;
TS_Battle_Command_Descriptions.getActorCommandHelp = function (commandData) {
if (commandData && commandData.symbol === 'singleSkill') {
const object = $dataSkills[commandData.ext];
const help = object && object.description;
if (typeof help === 'string') return help;
}
return oldGetActorCommandHelp.apply(this, arguments);
};
You don’t need to look up the _list entry because commandData should be exactly that object already. It’s also a good idea to avoid accessing the window through SceneManager._scene, as another plugin may reuse Window_ActorCommand in a different scene or under a different property name.
Thank you for your patronage and for sharing your issue and solution!
The 'attack' and 'guard' skills can differ depending on the actor. That’s why I didn’t just use 1 and 2 there for their ID.
It’s only an extension point in the engine for plugins though, so you can’t change this in the editor by default. There’s a WeaponSkill.js plugin floating around that makes use of this, for example. (I’d link the original page but I’m not sure where it is from.)
← Return to RPG Maker plugin
Comments
Log in with itch.io to leave a comment.
Hey! Question for you: I have a script right now that updates the help window in the Skill Menu scene with a description I set for each skill type. It works just fine with your plugin, but it's a bit of a hassle having to set the description for each skill type twice. Any way to modify it or adapt it to load the same description I set in your plugin parameters?
Great plugin by the way, I've been looking for exactly this functionality so I appreciate it!
(() => {
// Override the updateHelp method for Window_SkillType
Window_SkillType.prototype.updateHelp = function() {
const skillTypeId = this.currentExt(); // Get the skill type ID from the command
switch (skillTypeId) {
case 1: //Kyokushin
this._helpWindow.setText("Sensei Hugg's special style of Kyokushin Karate. I'm 2nd Kyu, but I'm rusty these days...");
break;
case 2: // Scrapping
this._helpWindow.setText("Moves I've learned from movies, TV, video games, comic books, and from getting myself in fights.");
break;
case 3: //Insults
this._helpWindow.setText("Getting in somebody's head can hurt them just as a punch or a kick. A weak mind makes a weak person.");
break;
case 4: //Self-talk
this._helpWindow.setText("I have mental health too... gotta make sure I can keep my head in the game. Big girls don't cry.");
break;
// Add more cases for additional skill types if needed
default:
this._helpWindow.setText(""); // Default empty text
break;
}
};
})();
Thank you for the praise and patronage, much appreciated 😊
Yes, you can retrieve this info through my plugin’s API.
I haven’t tested this, but it should work. It’s not necessary to include
null
/undefined
checks for most properties in my plugins since I normalise them to always be populated.Works perfectly! Thanks so much!
Hi, I have a setup in which all the skills are shown in the actor command window (so no SKILLS or MAGIC option). I tried your plugin, but it does not show the description for these skills aside from ATTACK and GUARD. Could you improve the plugin so that it shows the skill description of other skills as well? From your plugin description I assumed that it would do just that... but now I have empty windows.
FYI, I solved this with the help of a friend by adding the following in the getActorCommandHelp(commandData) function:
You’re using VisuMZ_1_BattleCore to set up the menu, right?
Due to its obfuscation and lack of public API, I don’t support its custom features directly.
That said, you can load your code as separate plugin after mine, to make it easier to update my code:
You don’t need to look up the
_list
entry becausecommandData
should be exactly that object already. It’s also a good idea to avoid accessing the window throughSceneManager._scene
, as another plugin may reuseWindow_ActorCommand
in a different scene or under a different property name.Thank you for your patronage and for sharing your issue and solution!
Thanks! Just for my benefit because I'm still a novice with JavaScript... why are the parts :
const action = BattleManager.inputtingAction();
const actor = action && action.subject();
...omitted in the patch in your last post? Asking because I genuinely don't understand what these do but just included them to be on the "safe" side.
The
'attack'
and'guard'
skills can differ depending on the actor. That’s why I didn’t just use1
and2
there for their ID.It’s only an extension point in the engine for plugins though, so you can’t change this in the editor by default. There’s a WeaponSkill.js plugin floating around that makes use of this, for example. (I’d link the original page but I’m not sure where it is from.)