• 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

Help with eval script

Kaleb

Well-known member
I am doing an eval script for Fleet footed adds 10' to base movement when wearing light or medium armor here is what I have I took the base dor the Feat Fleet and made some changes
Finia; Phase 100
~ If we're disabled, do nothing
doneif (tagis[Helper.FtDisable] <> 0)

~ If we fail the test for being speedy, get out
if (hero.tagis[Encumbered.Light+Medium] = 0) then
perform assign[Helper.SpcDisable]
done
elseif hero.tagis[Hero.HeavyArmor] <> 0) then
perform assign[Helper.SpcDisable]
done


What does [Helper.SpcDisable] do
Where is the additioanl speed being added I think it is being added by the filld abvalue so I changed it the value to 10

I am getting the following errors

Hero Lab was forced to stop compilation after the following errors were detected:

File: PFRPG_Slayer's Charge.user (line 34) - Thing 'cFlFooted' - Invalid unique id 'abvalue ' for attribute 'field'
 
What does [Helper.SpcDisable] do
Disables the Special Ability. But without a doneif() logic a script does not actually stop executing.

File: PFRPG_Slayer's Charge.user (line 34) - Thing 'cFlFooted' - Invalid unique id 'abvalue ' for attribute 'field'
HL is case sensitive. abvalue is NOT the same as abValue.

As for the speed change I would assume Fleet Foot has more than one script on it. As the above script would NOT change a characters speed.
 
Your script above is missing the line:
Code:
      ~ We passed, so add to our base speed.
      hero.child[Speed].field[tSpeed].value += field[abValue].value
 
Well first things first there is no tag called "Encumbered.Light+Medium" they are 2 separated tags. so

Code:
~if we're not light or medium encumbered, disable us
if (hero.tagos[Encumbered.Light] + here.tagis[Encumbered.Medium] = 0)
  perform assign[Helper.SpcDisable]
  done

The next part says if we're wearing heavy armor we're disabled.
Code:
elseif (hero.tagis[Hero.HeavyArmor] <> 0) then
  perform assign[Helper.SpcDisable]
  done
  endif

You seem to be missing the part that actually adds the speed bonus

Code:
       ~ We passed, so add to our base speed.
      hero.child[Speed].field[tSpeed].value += field[abValue].value

there is no field called abvalue on a feat, it is called abValue case matters for variables and field names.

Helper.SpcDisable marks a special as disabled.
 
Back
Top