rename lua scripts and clean up handling