Hiding Skills - Yanfly plugin

Sarah_yt

Veteran
Veteran
Joined
Oct 25, 2015
Messages
75
Reaction score
90
First Language
English
Hi guys,

I'm trying to set up a skill tree system where you start with a base skill, with several chances to upgrade as the game progresses. Each time you upgrade, you get two choices on how to upgrade it but choosing one will block off the other path.

E.g.
Skill 20 = base
Skill 21 = 1st upgrade available choice(a)
Skill 22 = 1st upgrade available choice(b)
...

Learning skill 20 will cause that to disappear from the list, making skills 21 and 22 appear as choices (already got that bit down pat). But when I go to choose either 21 or 22, the other doesn't disappear.

I'm using Yanfly's Skill Learn plug in and have read similar posts, but I can't figure it out. Here's the code I've been using:
<Learn Show Eval>
if(!this._actor.isLearnedSkill(20) || this._actor.isLearnedSkill(21) || this._actor.isLearnedSkill(22) { value = false; }
else value = true;
</Learn Show Eval>

And here's the error that pops up.
SkillLearnerror.PNG

EDIT: Whoops, forgot to ask - I think it could be fixed by including a check in Skill 21 to see if the actor has not learned skill 22 (and visa versa) but I don't know how to get the program to run that check.

Many thanks for your help!
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
There's a missing ) after checking for skill 22. That's why it's telling you the { is unexpected - you haven't finished the condition yet.

I see you have some different versions of the formula showing up there. All of those need an extra ) after skill 22. Some of them have 2 and need 3, some of them have 1 and need 2.
 

Sarah_yt

Veteran
Veteran
Joined
Oct 25, 2015
Messages
75
Reaction score
90
First Language
English
XD Thank you so much! I added the ) and it works perfectly :D gotta love a second pair of eyes.

EDIT: It solved the issue of appearing in the 'Learn Skill' section, but it didn't hide it from the battle or skill menu screen.

I've gone back to experimenting with Yanfly's basic Skill Core plugin, but the 'Hide if Learned Skill: ...' note never seems to work. Here's a picture:
YanflySkillCore.png

PS: I changed the title of the thread to better reflect the issue I was having. Sorry if this caused any confusion.
 
Last edited:

Sarah_yt

Veteran
Veteran
Joined
Oct 25, 2015
Messages
75
Reaction score
90
First Language
English
I think I figured it out - the issue was with <Hide if Learned Skill: x to y>. If I just used <Hide if Learned Skill: x>, it works perfectly - even with the <Learn Show Eval> note tag too. Woot!

Thanks again for your help Shaz!

If anyone is interested in seeing more, I can upload some screenshots demonstrating what I mean.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??

Forum statistics

Threads
105,865
Messages
1,017,059
Members
137,574
Latest member
nikisknight
Top