Remove useless code and order some scripts on the map editor