Switch some commands over to lua