fix script loading in maps