Felskis Skilltree Plugin

● ARCHIVED · READ-ONLY
Started by Felski 294 posts Page 3 of 15 View original ↗
  1. @Felski

    Hope you are doing well.

    I've implemented your wordwrap code change and unfortunately it seems like nothing has changed. Below is a screenshot regarding what I'm talking about more specifically, just in case it was not initially clear.

    https://i.imgur.com/2xTUcPg.png

    This is the final lines of the code in your .JS with the change (as the wordwrap function seems to take place at the very end, this is the most convenient way to show you what I have done).

    Code:
    //************************************************************************************************
    //
    // Utility Stuff
    //
    //************************************************************************************************
    
    Window_Base.prototype.drawTextAutoWrap = function (text, x, y, maxWidth) {
        if (!text) {
            return 0;
        }
        const words = text.split(' ');
        let lines = 1;
        let x2 = x;
        let y2 = y;
        words.forEach((word) => {
            word = this.convertEscapeCharacters(word);
            const width = this.textWidth(word + ' ');
            // Check for linebreak symbol '/n'
            if (word === `\x1bn`) {
                lines++;
                y2 += this.lineHeight();
                x2 = 0;
            }
            if (x2 + width >= maxWidth) {
                lines++;
                y2 += this.lineHeight();
                x2 = 0;
            }
            this.drawText(word + ' ', x+x2, y2);
            x2 += width;
        });
        return lines;
    };
    
        function jsonCopy(src) { //Credits and thanks to Farzad YZ on medium.com
            return JSON.parse(JSON.stringify(src));
        }
    
    })();

    Let me know if I've simply messed something up. Thanks again.
  2. Hi folks,
    I just released an update for my skill tree plugin. You can now use animations and I've added a few more options to customize the look of the skill tree further. Check it out here:


    Hey @falken14,
    thanks for your feedback. I really like the idea of an animation. So I added it. It's part of the new update I just released.
    You can set animations globally, per tree and per node. It uses the normal RPG Maker MV animations, so you can also play multiple sound effects and flash the screen. Again, thanks alot for this suggestion. I really like the outcome.

    Hi @Crysillion,
    I've checked out the coding and the issue is that the function drawTextAutoWrap isn't used for the tech description.
    Search for the function
    Code:
    Window_Techtree_Confirm.prototype.drawNodeInfo
    and find this line:
    Code:
    this.drawText(technode.tech_description, x, y+lh*2, w, 'center');
    and change it to
    Code:
    this.drawTextAutoWrap(technode.tech_description, x, y+lh*2, w, 'center');
    These issues are also fixed in the new release. I also added plugin parameters to show and hide the tech description, the skill name, the skill description and the skill icon.
  3. @Felski I've downloaded your demo, version 1.1.1, but I can't see the option for the Skilltree in the menu once I start the Game Test. Am I doing something wrong? There are no error messages on the console, neither.
  4. Oscar92player said:
    @Felski I've downloaded your demo, version 1.1.1, but I can't see the option for the Skilltree in the menu once I start the Game Test. Am I doing something wrong? There are no error messages on the console, neither.

    I had that same problem when I tried to use it with RPG MV less than V1.6. What version are you using?
  5. Felski said:
    Hi folks,
    Hey @falken14,
    thanks for your feedback. I really like the idea of an animation. So I added it. It's part of the new update I just released.
    You can set animations globally, per tree and per node. It uses the normal RPG Maker MV animations, so you can also play multiple sound effects and flash the screen. Again, thanks alot for this suggestion. I really like the outcome.

    @Felski, Wow, brilliant! Now I think it is complete. The ability to customise the animation to the node enhances the presentation aspect greatly, as you can have elemental skills show the respective elemental animation when activated, and so on. Wonderful work.
  6. falken14 said:
    I had that same problem when I tried to use it with RPG MV less than V1.6. What version are you using?

    I'm using RPG Maker MV v1.5.1 at the moment. But... how is that supposed to be? Even if the editor uses the 1.5.1 version, if the project has the most updated core version, there shouldn't be problems, right?
  7. Oscar92player said:
    I'm using RPG Maker MV v1.5.1 at the moment. But... how is that supposed to be? Even if the editor uses the 1.5.1 version, if the project has the most updated core version, there shouldn't be problems, right?

    As falken14 already mentioned, the plugin is made with V1.6. but I think that you are right too. The project has the up to date files, so it should work. Maybe the RPG Maker overwrites stuff when testplaying?
    I'm gonna investigate it once I'm back at home.
  8. Felski said:
    As falken14 already mentioned, the plugin is made with V1.6. but I think that you are right too. The project has the up to date files, so it should work. Maybe the RPG Maker overwrites stuff when testplaying?
    I'm gonna investigate it once I'm back at home.

    Since the update for RPG Maker MV v1.6.1, Playtesting is a pain almost for everything, not only the bad optimization with AMD Graphic Cards, but a lot of incompatibilities with plugins and other weird things.

    Maybe it is related...
  9. Oscar92player said:
    Since the update for RPG Maker MV v1.6.1, Playtesting is a pain almost for everything, not only the bad optimization with AMD Graphic Cards, but a lot of incompatibilities with plugins and other weird things.

    Maybe it is related...

    Hey @Oscar92player
    I've just downloaded the demo and checked it in MV. It works there fine. So I think the issue is related to the older maker version.
    Sadly I can't support other maker versions, as the expenditure is just to big. Sorry.
  10. Hey @Oscar92player
    I've just downloaded the demo and checked it in MV. It works there fine. So I think the issue is related to the older maker version.
    Sadly I can't support other maker versions, as the expenditure is just to big. Sorry.

    Yep, it seems that it is a problem with the MV version, since I've installed the newest version 1.6.1, and now it shows the Skill Tree on the Playtest. I need to investigate if this can work on deployed games with 1.5.1, since Playtest gives me too much problems.

    EDIT: Yep... just as I feared, it only works with core version of 1.6.1, and previous versions don't work with this plugin. Maybe you should specify that on the main thread...
  11. Oscar92player said:
    Yep, it seems that it is a problem with the MV version, since I've installed the newest version 1.6.1, and now it shows the Skill Tree on the Playtest. I need to investigate if this can work on deployed games with 1.5.1, since Playtest gives me too much problems.

    EDIT: Yep... just as I feared, it only works with core version of 1.6.1, and previous versions don't work with this plugin. Maybe you should specify that on the main thread...

    I edited the first post. Sorry for the inconvenience and thanks for you testing.
  12. It looks great plugin, I have a question, why I do not appear in the menu option skilltree?
    or how can I do it to visualize it?
    Beforehand thank you very much.
    20181201092304.png
  13. Osviii said:
    It looks great plugin, I have a question, why I do not appear in the menu option skilltree?
    or how can I do it to visualize it?
    Beforehand thank you very much.
    20181201092304.png

    Hi @Osviii,

    what version of RPG Maker MV are you using? This plugin only works with 1.6.1.
    Best regards,
    Felski
  14. Hey Felski,

    I'm still a novice and I haven't interacted with the plugin (albeit much of the engine yet), but I wanted to know if its possible to have a skill tree be locked until an outside event has occurred. For example, when a character advances through a plot point in the story is it possible for them to be rewarded with a new skill tree?

    If that has a complex answer, then a yes or a no is fine enough.

    Thanks again for the plug-in!
  15. Hi @valtols,

    this can be done. In multiple ways even.

    You could hide the skill tree menu point uing a main menu manager plugin like Yanfly's Main Menu Manager.

    You could add the skill tree to the character at a certain point in the game. This is done via the plugin command ADDTECHTREE [actorId] [techtree uid].

    You could change the class of the player to a class that has the skill tree attached to it. To attach a class you just need to add a notetag to the class like:
    <techtree>
    HOLY
    HEALER
    </techtree>

    You could set the visibility requirements of each node in the skilltree to a switch. This switch needs to be activated for the nodes to be fully revealed. The player would still be able to access the skill tree and see how many nodes are there and how they are connected. He wouldn't be able to learn any of them tho. This would be a nice teaser for what is to come for the player.

    Best regards,
    Felski
  16. Felski said:
    Hi @valtols,

    this can be done. In multiple ways even.

    You could hide the skill tree menu point using a main menu manager plugin like Yanfly's Main Menu Manager.

    You could add the skill tree to the character at a certain point in the game. This is done via the plugin command ADDTECHTREE [actorId] [techtree uid].

    You could change the class of the player to a class that has the skill tree attached to it. To attach a class you just need to add a notetag to the class like:
    <techtree>
    HOLY
    HEALER
    </techtree>

    You could set the visibility requirements of each node in the skilltree to a switch. This switch needs to be activated for the nodes to be fully revealed. The player would still be able to access the skill tree and see how many nodes are there and how they are connected. He wouldn't be able to learn any of them tho. This would be a nice teaser for what is to come for the player.

    Best regards,
    Felski

    Thank you very much for the reply and detailed answer!
  17. Hello @Felski !
    I was testing your plugin. Amazing! I wonder if it is possible to add attribute gain (example: ONLY +200HP, +10ATK...) rather than skill. What I wanted to do is a specific node for attributes and others only for skills. As in Final Fantasy X - Sphere Grid System. If it is, how does it work?
    Thanks in advance <3
  18. Hi @LucasRiot,

    Thanks for your idea. I think it is something I might implement in the future. Sound like a cool thing to have. Currently I don't work on the plugin tho.
    But there are other ways to achieve what you want. You have two options.
    First:
    Create common events that just use the Change Parameter event command. Then run the common events on node activation.

    Second (One warning here. I haven't tested this, but I think it should work.):
    If you want to allow resetting the trees, use Yanflys Base Parameter Control and Yanflys Auto Passive States. Create passive states that use the <stat Plus: +x> notetag from Base Parameter Control to make states that give you the stats (+200 HP etc.). Then create skills and use the <Passive State: x> notetag from Auto Passive States that give you the states when ever you have the skills learned. And then finally give the characters the skills via my plugin.
    That way you could even use Yanflys Class Core to allow class switching.

    Best regards,
    Felski
  19. Felski said:
    Hi @LucasRiot,

    Thanks for your idea. I think it is something I might implement in the future. Sound like a cool thing to have. Currently I don't work on the plugin tho.
    But there are other ways to achieve what you want. You have two options.
    First:
    Create common events that just use the Change Parameter event command. Then run the common events on node activation.

    Second (One warning here. I haven't tested this, but I think it should work.):
    If you want to allow resetting the trees, use Yanflys Base Parameter Control and Yanflys Auto Passive States. Create passive states that use the <stat Plus: +x> notetag from Base Parameter Control to make states that give you the stats (+200 HP etc.). Then create skills and use the <Passive State: x> notetag from Auto Passive States that give you the states when ever you have the skills learned. And then finally give the characters the skills via my plugin.
    That way you could even use Yanflys Class Core to allow class switching.

    Best regards,
    Felski

    OK! I've tested both plugins. But it didn't work. I used Change Parameter event command and it was ok! Thank you :D
    Other question, @Felski
    Is there any way to edit a Skill Tree already made (using treeeditor-to import a Skilltree) or will I always have to redo everthing if I wanted to add new skills?
  20. LucasRiot said:
    OK! I've tested both plugins. But it didn't work. I used Change Parameter event command and it was ok! Thank you :D
    Other question, @Felski
    Is there any way to edit a Skill Tree already made (using treeeditor-to import a Skilltree) or will I always have to redo everthing if I wanted to add new skills?

    Hi @LucasRiot,

    you can just copy paste your skilltree into the Techtree JSON Output field (it only shows [] when you open the editor). Then click the "Update Form" button above it. This should load your tree for more editing.
    Best regards,
    Felski