def Open(self): print "OPEN LOADING WINDOW -------------------------------------------------------------------------------" #app.HideCursor() try: pyScrLoader = ui.PythonScriptLoader() pyScrLoader.LoadScriptFile(self, "UIScript/LoadingWindow.py") except: import exception exception.Abort("LodingWindow.Open - LoadScriptFile Error") try: self.loadingImage=self.GetChild("BackGround") self.errMsg=self.GetChild("ErrorMessage") self.loadingGage=self.GetChild("FullGage") except: import exception exception.Abort("LodingWindow.Open - LoadScriptFile Error") self.errMsg.Hide() if constInfo.SUB2_LOADING_ENABLE: imgFileNameDict={ 0 : "d:/ymir work/uiloading/background_loading_warrior.sub", 1 : "d:/ymir work/uiloading/background_loading_assassin.sub", 2 : "d:/ymir work/uiloading/background_loading_shaman.sub", 3 : "d:/ymir work/uiloading/background_loading_sura.sub", 4 : "d:/ymir work/uiloading/background_loading_assassin2.sub", 5 : "d:/ymir work/uiloading/background_loading_sura2.sub", 6 : "d:/ymir work/uiloading/background_loading_assassin3.sub", 7 : "d:/ymir work/uiloading/background_loading_assassin3.sub", } else: imgFileNameDict={ 0 : "d:/ymir work/ui/intro/pattern/background_loading_warrior.jpg", 1 : "d:/ymir work/ui/intro/pattern/background_loading_assassin.jpg", 2 : "d:/ymir work/ui/intro/pattern/background_loading_shaman.jpg", } try: imgFileName=imgFileNameDict[app.GetRandom(0, 7)] self.loadingImage.LoadImage(imgFileName) except: print "LoadingWindow.Open.LoadImage - %s File Load Error" % (imgFileName) self.loadingImage.Hide() self.loadingImage.SetScale(wndMgr.GetScreenWidth()/800.0, wndMgr.GetScreenHeight()/600.0) self.loadingGage.SetPercentage(2, 100) self.Show() chrSlot=self.stream.GetCharacterSlot() net.SendSelectCharacterPacket(chrSlot) app.SetFrameSkip(0)