Repaired issues with calling scripted functions. Wrote preliminary "return" function.

Signed-off-by: Christian Gunderman <christian@sonofboss.cwru.edu>