d7a3e35f46
With some help from pippin, moved variable declarations into more sensible positions within their functions, changed a function name, and found a better way to unref a script once its associated actor has been destroyed.