Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
trustme
var sanity as number
var current as number
var mythos as number
current = field[trkUser].value
if (current <> 0) then
~ How to do equality comparison? The wiki only shows greater than less than and == throws an error
else
sanity = 15 + ((#trait[attrWil] + #trait[attrEssenc]) * 5)
field[trkUser].value = sanity
else
~ The character already had a recorded sanity value.. Let's see if I can figure out what I 'should' do here...
~ We may still be in character creation, in which case we should re-determine the maximum.
~ We may be playing, in which case we should just apply the current value.. This doesn't work as it prevent's the sanity value from changing at all
~ We may be playing in which case, maybe we should re-calculate the current value from a stored starting sanity and a lost sanity tracker?
endif
~ This can be run anytime as the mythos should only be 0 at char creation.
mythos = hero.childfound[trkCthulhu].field[trkUser].value
if (mythos <> 0) then
field[trkMax].value -= mythos
endif