fixed script functions to handle both constants and ints for new functions as well as some old functions.
Authored by: SumolX 2007-08-12
Parent: [r959]
Child: [r961]