Found the proper license in the source.
Whoops, I can't read. never mind.
HOLY AUTOMATED REFACTORING BATMAN.
Anyways, I've written a script that pulled out the functions from the event numbers in doEvent.as, and then went through all the .as files in ./includes and replaced the event numbers with the corresponding functions. Hopefully, it won't cause too many issues, it certainly compiles, in any event.
Horribly messy script for automating refactoring stuff.
Updates broke too much stuff, rolling back the master until I get it working.

This reverts commit 393b04a9a1566062e76396e44837d30157863a32.