I coded it without testing, directly in the quick reply box so that's why the function was defined in the wrong place. And everything that has single quotes was written by me, I copy pasta'd the rest
Also, you can't make functions defined in a table local, besides, "self" already is a local variable in the script handler. That is why the lua interpreter is telling you about "(" expected near ":"
See "Method calling conventions":
http://lua-users.org/wiki/ObjectOrientationTutorial