IdleLands / IdleLandsOld

[DEPRECATED] A full-blown idling RPG. It has a modular backend that can be added to any existing frontend via a REST API.
http://idlelands.github.io/IdleLandsOld
MIT License
41 stars 28 forks source link

blessItem should only bless stats that aren't "special stats" #233

Closed seiyria closed 9 years ago

seiyria commented 10 years ago
A demon decides to play a trick on Goomba by placing a curse on his +4 annihilating ring. [crit 13 -> 11] Zep dropped his chain in a puddle and it got all dirty! [_calcScore 4 -> 3] that's ridiculous. however, the method that prevents this needs to either constrain it by str/int/%/etc, or it needs to have a list of these special stats. I think the base stats are pretty solid and not likely to change in the future so it would be a better idea to maintain a list of those instead of prone, crit, etc because those effects will keep getting added.
seiyria commented 10 years ago

While doing this, the algorithm should also be tuned in such a fashion:

First, pick all of the blessable stats and categorize them into tiers:

luckPercent - t4, 1%
luck - t3, 5%
gold / xp / hp / mp / % - t2, 10%
intPercent / strPercent  / etc - t1, 20%
int / str / etc - t0, 100%

Then, try to bless for each tier in descending order, if there is a stat that can be chosen. If the stat is chosen @ the tier percent, then pick that stat. otherwise, keep going down until you get to t0. you will always pick a t0 stat at random if there is one available.

Additionally, if the lowest tier does not have any entries, then it should always shift to the next tier. Meaning, if there are no t0 stats available, pick a t1 stat. If there are no t1, pick a t2, etc.