Trying to make an attack do wildly random damage

I want to make an attack that can do anywhere from 2 damage to 9999 damage, independent of the user's or targets' stats. What's the best way to go about doing that?
Could try to put the damage formula to 9999 and set th variance to 98% to see if it that causes th variance you want
Drop the below in the damage formula for the skill:
JavaScript:
Math.randomInt(9998) + 2

It will first pick a random number from 0 - 9997, then add 2 to that number.
(You should set variance to 0 as the variance is in the formula itself.)
In my opinion, the first question is what is the average damage you want this skill to inflict?
Because a 1-9999 damage range with a uniform distribution means an average of 5000 damage per use. Which can be a lot... or very few, depending on how you manage HP, DEF and damage in your game.
If my characters are hitting enemies for 150 damage with regular skills, I will always use the 1-9999 skill! But if they do 7000 damage with regular skills, I will never use it.
In my opinion, the first question is what is the average damage you want this skill to inflict?
Because a 1-9999 damage range with a uniform distribution means an average of 5000 damage per use. Which can be a lot... or very few, depending on how you manage HP, DEF and damage in your game.
If my characters are hitting enemies for 150 damage with regular skills, I will always use the 1-9999 skill! But if they do 7000 damage with regular skills, I will never use it.
Yeah, I realized that when I went to test one of the methods posted earlier, so I actually brought it down to 2000 😅. The idea is for it to be a skill based on making a random guess on a test question. It might work great, but it should, in most situations, be moderately useful at best. Either way, i have it figured out now!

Original thread: https://forums.rpgmakerweb.com/threads/trying-to-make-an-attack-do-wildly-random-damage.176429/