(i did it) Another skill idea

anyway to make a skill that has more accuracy the more ammo you have?
i use 2 variables for ammo (1 for the current ammo and another one for the max ammo)
Can use a plugin for a custom accuracy formula for the skill.

Since you're using MV, something like: http://www.yanfly.moe/wiki/Hit_Accuracy_(YEP)

And then factoring in the variable for bonus accuracy like:
Code:
a.hit - b.eva + v[1]
Another option is Victor Engine's Hit Formula. That allows you to use notetags to have customized hit formulae on specific skills.

Yanfly's formula is universal, so in order to account for just one skill (if that's what you want to do), you'd have to embed some JavaScript.
Another option is Victor Engine's Hit Formula. That allows you to use notetags to have customized hit formulae on specific skills.

Yanfly's formula is universal, so in order to account for just one skill (if that's what you want to do), you'd have to embed some JavaScript.
yeah i only want 1 skill to do that could you like give me the javascript thing pls?
Not really, you haven't said what you want your formula to be.

You reference the value of a variable with $gameVariables.value(ID) where ID is the ID of the variable, no leading zeros.
i mean it's like a random number between your 1 and your max ammo
and if you roll a number that = or > than your current ammo it hits
Rolling a random number is Math.randomInt(X) which generates a value from 0 to X-1.

And I told you above how to reference game variables. Only you know how you're tracking what someone's max ammo is or what the item ID for ammo is, so plug it all into your formula.
ok it works thx

Original thread: https://forums.rpgmakerweb.com/threads/i-did-it-another-skill-idea.168412/