|
Axe Software Forums
Quest Developer Forum Question
|
Author | Topic: Question |
I think Im Back |
posted 15-01-2003 18:08 GMT
So, if I remember correctly quest doesn't have any kind of math parser right? Like, I can't take 3 numeric variables(a,b,c) and add them together? I'm starting to get heavily into random dice rolls and stat numbers as I'm trying to develop some sort of combat/training system. So far I've just been planning things out in my head, figured I'd ask here before I started trying to code any of it. |
Alex |
posted 15-01-2003 19:08 GMT
Quest's maths routines are fairly basic - they'll only accept two numbers as a parameter. So, if you want to add three numbers together A, B and C, you'll need to add A+B together and store it in another numeric variable (say, D), then add D+C. |
I think Im Back |
posted 16-01-2003 18:16 GMT
But it will mulitply/divide/subtract/add any two numbers? |
Computer Whizz |
posted 16-01-2003 18:37 GMT
I'm working on a maths parser : ) I'll probably have it so it can come out with lines which can be put into Quest so instead of thinking it all out you just put in a complicated equation and out pops 5 lines to put into Quest. Computer Whizz |
Alex |
posted 17-01-2003 12:09 GMT
Yes you can add, subtract, multiply or divide two numbers or variables. If you're using QDK, instead of just entering one number in the parameter for "Set a numeric variable", you can use things like: %something% / 2 |
Computer Whizz |
posted 17-01-2003 17:20 GMT
It even does stuff like "x to the power y".... All you need to do is put a sum into a loop to y! It can also work out factorials on that principal... Computer Whizz |