How To Test For Good Evil Neutral

Main.HowToTestForGoodEvilNeutral History

Show minor edits - Show changes to markup

December 30, 2008, at 05:14 PM EST by admin
Added line 4:
Added line 6:
December 30, 2008, at 05:14 PM EST by admin
December 30, 2008, at 05:14 PM EST by admin
Added lines 1-6:

The old mobprog system had 3 commands for isgood, isevil and isneutral. The Lua based system allows you to be more specific and test the character alignment number. To get the equivalents of the old commands use:

if ch.align >= 875 then .... (good alignment) if ch.align <= -875 then .... (evil alignment) if ch.align > -875 and ch.align < 875 then .... (neutral)