Skill Trees System
JS Plugin Releases (RMMV)I think the treeObj.iconId() refers to the icon id that it will draw.
I could find a skill id that is using this icon in code. But that can lead to other problems if you have skills with the same icon id, or event if the treeObj.iconId() does not refer to the skill Icon id, and instead, just an icon id for visual purposes on the tree system.
So I guess is best to wait an answer from the author ^^
Oh right, duh...iconId refers to the icon sheet. lol😅
So it's in Skills_Window.prototype.drawItem starting on line 767 (772 draws the icon). Reading through the Skill class in the config file, it looks like you should be able to do
$dataSkills[treeObj.lvls[index]].idedit: I see looking back that he's the original freaking author, so obviously he would know how to identify the skill ID...
Well, that was in response to a proposed filter or overlay of some sort. This is an entirely different approach via a separate png file. But anyway, I'll try what you suggested, thx!
Edit: Bummer...tho I'm sure we're on the right track!
Um...how did you "try it"?
@ATT_Turan
Did I do it wrong?...
JavaScript:
if(this._actor.isLearnedSkill($dataSkills[treeObj.lvls[index]].id)){
this.drawIcon(treeObj.iconId(), x, y);
}else{
this.drawIconGray(treeObj.iconId(), x, y)
}
Try
lvls[0]That did it, thanks!😂
Edit: Hmm, now that I'm playing around w/ it...I think it would look/feel even better if instead of "if skill x is learned", the condition should be "if skill x is learnable". Something like:
if (skill.isAvailableToLearn(this._actor, this._tree))Edit2: Of course it didn't work lol, oh wells. XD
Edit3: Solution!
if (this._tree.skills[index].isAvailableToLearn(this._actor, this._tree)) {Edit4: Ooh, I actually need to combine both conditions to get it how I want. Like so...
JavaScript:
if (this._tree.skills[index].isAvailableToLearn(this._actor, this._tree) || this._actor.isLearnedSkill($dataSkills[treeObj.lvls[0]].id)) {
this.drawIcon(treeObj.iconId(), x, y);
} else {
this.drawIconGray(treeObj.iconId(), x, y)
}
Wow, incredible discussion in this thread! Good job guys!
The only thing I can suggest is
Thus, an unfinished skill will not be grayed out if the actor does not have enough job points to learn skill. On the screenshot you can see bright 1/5, but 2/5 will be gray with 0 JP.
Also, changePaintOpacity code is redundant in this way. I used opacity to differ available skills from unavailable, but you do it by coloring.
The only thing I can suggest is
Code:
if (treeObj.isEnabled(this._actor, this._tree)) {
this.drawIcon(treeObj.iconId(), x, y);
} else {
this.drawIconGray(treeObj.iconId(), x, y)
}
Also, changePaintOpacity code is redundant in this way. I used opacity to differ available skills from unavailable, but you do it by coloring.
Any idea how to change opacity to 0 or make transparent for Scene_SkillTrees only ?
its seem Scene_SkillTrees and Scene_Menu combine together.
When I change opacity for Scene_Menu it work, but it make Scene_Menu become transparent
Already try using SRD plugins, but still the opacity not changed
its seem Scene_SkillTrees and Scene_Menu combine together.
When I change opacity for Scene_Menu it work, but it make Scene_Menu become transparent
Already try using SRD plugins, but still the opacity not changed
Bug.
In SkillTreesSystem.js replace
Code:
Scene_SkillTrees.prototype.constructor = Scene_Menu;
Code:
Scene_SkillTrees.prototype.constructor = Scene_SkillTrees;
Dunno if this has already been asked, but is there a way to have multiple squares affecting different parts of the same skill?
Basically, something like this?
(preferably without using a yanfly plugin?)
Basically, something like this?
No, there is noithing similar in my plugin. The current logic: when the skill level increases, the previous database skill is removed and a new one is given.
The easiest way to implement such behaviour is to make "Fortify" depending on game variables. Change game variables in skill upgrades. To change them use OnLearnChangeVariable as OnLearnActions like in example:
The easiest way to implement such behaviour is to make "Fortify" depending on game variables. Change game variables in skill upgrades. To change them use OnLearnChangeVariable as OnLearnActions like in example:
Code:
guard2 = skill('guard2', [2], [
[cost(1), switchReq(1)], // Requires switch 1 to be true.
], [
[changeVar(1, 2)] // On learn action, which increase the game variable 1 by 2.
]);
Hey is it possible to customize this plugin with luna engine
Hello SomeFire!
I don't remember if it was asked before (i was away from creating for some time), but how do i remove skill points from one class's tree?
I tried the following: "actor.addTreesPoints(-10, 11);", but this command didn't do anything....
I am doing something wrong?
I don't remember if it was asked before (i was away from creating for some time), but how do i remove skill points from one class's tree?
I tried the following: "actor.addTreesPoints(-10, 11);", but this command didn't do anything....
I am doing something wrong?
I think no. I don't know how luna engine works.
11 is a class number? You should use treeId (symbol) instead of class number.
Hey, does reseting a skill tree reset the variables back to 0?
No, it works only for points in "Cost" requirement.
If you want to implement it, you can do it in SkillTreesSystem.js
Code:
SkillTreesSystem.resetSkillTree = function(actor, tree) {
Code:
if (req.type === "points")
points += req.price;
Original thread: https://forums.rpgmakerweb.com/threads/skill-trees-system.100429/