• Please note: In an effort to ensure that all of our users feel welcome on our forums, we’ve updated our forum rules. You can review the updated rules here: http://forums.wolflair.com/showthread.php?t=5528.

    If a fellow Community member is not following the forum rules, please report the post by clicking the Report button (the red yield sign on the left) located on every post. This will notify the moderators directly. If you have any questions about these new rules, please contact support@wolflair.com.

    - The Lone Wolf Development Team

Numeric variable in eval rule

Redcap's Corner

Well-known member
I have the following code in an eval rule:

Code:
var enhancement as number
enhancement = hero.child[cFixMagAP2].field[ActUser].value

foreach pick in hero where "thingid.cFixMagAPW"
  enhancement += eachpick.field[abValue].value
nexteach

validif (enhancement <= hero.child[cFixMagAP].field[xCount].value)

I keep getting a syntax error for line #1 that says "invalid identifier in declaration". Is there some reason why numeric variables aren't allowed in eval rules? Or is there some reason why this variable wouldn't be a number? Or am I missing something else?
 
Back
Top