@Hit, ARGN1 and floatval/feval
Whats up guys, I was cruising along on my custom @Hit algorithms and I was making major progress until I hit this scenario and I can't figure out the magic formula.
Ok, so in my @Hit I have a long equation that, lets just say for ease, set ARGN1 = 22
That formula has been tested extensively ingame and works great.
Then I wanted to grant a bonus to that ARGN1 algorithm if the weapon in question was a 2hander.
So I simply wanted to take my ARGN1 = 22, and give a 10% bonus if it was a 2hander instead of a 1hander.
So logically I make ARGN1 = 22 * 1.1
Well, in the debugging process I instantly saw that eval was dropping it.
So I instantiated a variable, LOCAL.TWHOHANDBONUS equal to 1.1, and I tried 0.1, and I tried .1
Next I tried <floatval <LOCAL.TWOHANDBONUS>>, <floatval <fval <LOCAL.TWOHANDBONUS>>>
None of which worked, so here I am asking for help, I need to take my ARGN1 value in @Hit and add 10% to it, any ideas?
Thanks as always for the help.
-Murmur
I just thought about maybe doing all the math outside of ARGN1, then calling the result via a variable on the ARGN1 line?
Found the FLOAT.*** information in the WIKI, and I tried to do FLOAT.TWOHANDSBONUS = 1.1
I did ARGN1=22*<FLOAT.TWOHANDSBONUS> and it creates some massive numbers.. So still looking for the solution.
*you glance to your left to a region you just surveyed... you glimpse a magical being, more shadow than substance, caught midway in transformation... the figure smiles, the corners of his mouth jut upwards slightly on the edges, suddenly stretched to a length not at all human...*
(This post was last modified: 05-10-2017 03:41 PM by Murmur.)
|