Variable requirement for skills?

I was wonder if there is any way to make a skill that requires a variable to be at a certain number to use

Like for example:
Skill 1 requires Variable 2 = 3 to use and if the variable isn't equal to three, you can't use the skill?

Is there a way to do that?
Not in the base engine, but if you use Yanfly's Skill Core you can add a custom requirement notetag and make the condition the variable being 3.
Not in the base engine, but if you use Yanfly's Skill Core you can add a custom requirement notetag and make the condition the variable being 3.
I looked at the skill core plugin but i don't know how i can do that with the skill core plugin

All i could see was something about lunatic mode which i don't really know how to use
Plugin link for convenience:
You could try this notetag:

<Custom Requirement> value = $gameVariables.value(2) === 3; </Custom Requirement>
I.e. "the skill is usable iff game variable ID 2 is equal to 3".

Note that by default skill ID 1 is the Attack skill. Not sure what safety precautions exist there but you may want to ensure there's always at least one skill available.
Plugin link for convenience:
You could try this notetag:

<Custom Requirement> value = $gameVariables.value(2) === 3; </Custom Requirement>

I.e. "the skill is usable iff game variable ID 2 is equal to 3".

Note that by default skill ID 1 is the Attack skill. Not sure what safety precautions exist there but you may want to ensure there's always at least one skill available.
Thanks! I'll try this all say if it works like i was thinking
Thanks! I'll try this all say if it works like i was thinking
This works exactly how i wanted it to work. Thanks for the help @caethyril
You're welcome, happy RPG Making!

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/variable-requirement-for-skills.147041/