QuantumApprentice
Where'd That 6th Toe Come From?

ah ok-2147483648 is already within 32bit integer range. I don't know why you'd assume you need to "truncate" it.
"if (pMode == SPECIAL) then debug_msg("SPECIAL mode flag unset!");" works just fine for me when exting dialogue.
EDIT: if you mean cases when it's mixed with other flags (e.g. entering barter), yes, use bwand SPECIAL. Just like how the game does for checking various bit flags in scripts.
so wait...should I be doing my checks like this?
Code:
if (arg1 bwand DIALOG) then begin