How create something like the battle math of a classic FF game? - or direction to get started

Found this , not sure how i missed it

I think this is a good starting point , but yeah any info feel free to post