Open rubydragon44 opened 10 years ago
Not complex, just the performance implications of having to perform a filter every single time you fetch features...which happens very often.
Conditions can change, features can change, and so on.
I see. So I think I will have to use these boosts the way certain RPG equipment like in Dissidia works, with states that act as traits. Like a state, Hearty Strength, which boosts ATK when HP is full, something that doesn't stack among objects. Using a passive state script, of course. But then if you wanted it so that equipment has their own passive abilities, you might end up dedicating a lot of states.
You can also have it that it checks every 300 frames (5 seconds) or so, or merely just have it so that it only checks when the menu is opened or at action end (like when you use Heal on party members) on the map, as unless you're using an ABS system, mostly these features would only be relevant on the menu and in battle, not while you're walking around, and in battle you could have it so that the conditions update at turn start, action end, and turn end in battle, I /think/.
Most of the performance-related issues I'm talking about is purely theoretical based on code analysis (eg: do a loop here, do a bunch of checks there).
I haven't actually verified that it will cause massive drops in FPS. Maybe it wouldn't even be that big of a deal, since computers can process millions upon millions of instructions in a fraction of a second. Who cares if you have to do an extra 10 conditional checks.
I've updated the script to support individual feature conditions. See how it performs.
Check the script for usage instructions. I haven't updated the blog post.
Like how effects have an ID, what if Feature/Traits had IDs and conditions? Like a state multiplies ATK and MAT *112% and further multiplies them when HP is low. Or is that not possible or too complex? I remember "Note that feature conditions are applied to all features in an object and currently cannot be applied to specific features within an object."