Hi everyone,
seeing how my next project is going to use very low HP (1-2 digits) I'm going to focus on accuracy and manipulation of it.
I'd like the basic chance for the ranged skills to be something like LUK + (AGI / 4) - enemy's AGI/2 and the chance to hit with melee skills to be (ATK*10 + (AGI /4)) - enemy's AGI/2. Is there any reasonably easy way to do this or would I need some complex scripting?
Also, how do I adjust Hit rate on separate skills? Supposedly there is a way to give a skill an extra 10% or something, but I just can't find it.
Thanks in advance! 🙂
You could, using Yanfly's extra parameters script, change the to hit to be ATK * 10 + AGL / 4, and then the enemies EVA could be AGI / 2. Then, you just need to set it up in the game so that your chance to hit with an attack is:
chance to hit = Your to hit - enemies EVA.
Then, have the game roll a random number between 0.0 and 1.0 like it currently does. If it is lower than your chance to hit, you hit. If it is higher, you missed.
Would take a few edits to existing lines, and you would need to comment out the evaded line (or missed line), as you would only have evading or missing, but not both. But, it could work.
However, I'm not sure if it can be done for two different hit formulas for the game. That may take scripting and you would have to call two different algorithms depending on if it was a melee or missile attack.
Hmm, alright. Sadly the different chances to hit depending on skill types were supposed to be one of the key features, as I don't want ranged characters to massacre people in melee... I'll look for some alternative perhaps.
Thanks for the tip. If anyone knows a way to have two formulas that would be greatly appreciated. 🙂
The only other way I can think of to do this would be to have the skill activate an invisible state that has a static effect on your hit rate, that terminates at the end of the action. I know that's not what you're looking for either, but it is an option.
I'll weed through some scripts, see if I can find something like it for you.
I think you could do it by adding a second damage formula, then having the missile characters call that formula? Would take a script to give the missile characters a different default attack, then in that attack, have the damage formula call a command? I know it can be done, but I don't recall how (I think the details are in the thread on things you can do with custom formula).
You can pretty much make a script snippet for this. The base code is in Game_Battler
def item_hit
which, by the way is a horrendous method for calculating it in my opinion.
I don't know the specifics but there should be a way to check the skills type then you can write your own unique formula.