Testing Your Formulas

Hello all,

I am fairly new to RPG maker and I have been taking classes on ruby and trying my best to learn the process as I go. I have got a lot of support from the community and I decided to try and give some back. I have had a LOT of problems trying to figure out my formulas and going back and forth battle testing has been really time consuming. So I have found a way to make it a relatively painless process so I thought I might share it with some of the community.

Here is my sample formula for my attack.

(1.2*a.atk)+70+a.mat

Here is how I test it.

First go to http://www.compileonline.com/execute_ruby_online.php

Paste the sample formula below

atk = 50

mat = 0

x =(1.2*atk)+70+mat

print x

Hit execute script in the upper left and on the right your result will come out. It will also help you pinpoint any errors you might be having.

To test further change the values of mat and atk.

I am still pretty noob so I don't know how helpful this will be to the rest of you but I have found it to be very helpful when my formulas are not coming out right in battle tests. -Thanks
I'm getting a "Problem loading page" 'Connection was reset while loading' error when I click the link. I'll try again later. Hope it works well, that would be a real boon to avoid the loading of the battle testing.
some hours ago that link worked for me, now I'm getting problems as well.

It could be that that simulator is on a low-capacity server and just got stormed with work when being revealed here ;-)
some hours ago that link worked for me, now I'm getting problems as well.

It could be that that simulator is on a low-capacity server and just got stormed with work when being revealed here ;-)
Your probably right
Sorry Did I Post This In The Wrong ForUm I Meant To Put It In Tutorial
It doesn't qualify as a tutorial due to several reasons. But in a staff discussion:

It's a nice and helpful tip - but to call this a tutorial is a bit extreme in my opinion.

That info should definatily be made available somewhere, but I think script support is a better place for this than the tutorial area, especially as someone needs to know scripting to reconfigure the damage formula into a readably script.

 

If he wants it as a tutorial, he has to improve on it telling others how to split a damage formula into a short script to be tested on that link...
There is a helpful link to a tutorial on the Ruby Script, on that site.

Original thread: https://forums.rpgmakerweb.com/threads/testing-your-formulas.16354/