Code cleanup on client/*.lua