Beispiel #1
0
    def Open(self, maxValue, unitValue=1):

        if localeInfo.IsYMIR() or localeInfo.IsCHEONMA(
        ) or localeInfo.IsHONGKONG():
            unitValue = ""

        width = self.GetWidth()
        (mouseX, mouseY) = wndMgr.GetMousePosition()

        if mouseX + width / 2 > wndMgr.GetScreenWidth():
            xPos = wndMgr.GetScreenWidth() - width
        elif mouseX - width / 2 < 0:
            xPos = 0
        else:
            xPos = mouseX - width / 2

        self.SetPosition(xPos, mouseY - self.GetHeight() - 20)

        if localeInfo.IsARABIC():
            self.maxValueTextLine.SetText("/" + str(maxValue))
        else:
            self.maxValueTextLine.SetText(" / " + str(maxValue))

        self.pickValueEditLine.SetText(str(unitValue))
        self.pickValueEditLine.SetFocus()

        ime.SetCursorPosition(1)

        self.unitValue = unitValue
        self.maxValue = maxValue
        self.Show()
        self.SetTop()
    def Open(self):
        print "OPEN LOADING WINDOW -------------------------------------------------------------------------------"

        #app.HideCursor()

        try:
            pyScrLoader = ui.PythonScriptLoader()

            if localeInfo.IsYMIR() or localeInfo.IsWE_KOREA(
            ) or localeInfo.IsCANADA() or localeInfo.IsBRAZIL(
            ) or localeInfo.IsEUROPE() or localeInfo.IsJAPAN():
                pyScrLoader.LoadScriptFile(
                    self,
                    uiScriptLocale.LOCALE_UISCRIPT_PATH + "LoadingWindow.py")
            else:
                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")
            self.tipTextLine = self.GetChild("tipTextLine")
        except:
            import exception
            exception.Abort("LodingWindow.Open - LoadScriptFile Error")

        self.errMsg.Hide()

        if localeInfo.IsHONGKONG():
            imgFileNameDict = {
                0: app.GetLocalePath() + "/ui/loading/loading0.sub",
                1: app.GetLocalePath() + "/ui/loading/loading1.sub",
                2: app.GetLocalePath() + "/ui/loading/loading2.sub",
                3: app.GetLocalePath() + "/ui/loading/loading3.sub",
                4: app.GetLocalePath() + "/ui/loading/loading4.sub",
                5: app.GetLocalePath() + "/ui/loading/loading5.sub",
                6: app.GetLocalePath() + "/ui/loading/loading6.sub"
            }
        elif localeInfo.IsCIBN10():
            imgFileNameDict = {
                0: app.GetLocalePath() + "/ui/loading/loading0.jpg",
                1: app.GetLocalePath() + "/ui/loading/loading1.jpg",
                2: app.GetLocalePath() + "/ui/loading/loading2.jpg",
                3: app.GetLocalePath() + "/ui/loading/loading3.jpg",
                4: app.GetLocalePath() + "/ui/loading/loading4.jpg",
                5: app.GetLocalePath() + "/ui/loading/loading5.jpg",
                6: app.GetLocalePath() + "/ui/loading/loading6.jpg",
                7: app.GetLocalePath() + "/ui/loading/loading7.jpg",
            }
        elif localeInfo.IsYMIR() or localeInfo.IsWE_KOREA(
        ) or localeInfo.IsCANADA() or localeInfo.IsBRAZIL(
        ) or localeInfo.IsEUROPE() or localeInfo.IsJAPAN():
            imgFileNameDict = {
                0: "yamato_load/loading01.jpg",
            }
        elif 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,
                len(imgFileNameDict) - 1)]
            self.loadingImage.LoadImage(imgFileName)

        except:
            print "LoadingWindow.Open.LoadImage - %s File Load Error" % (
                imgFileName)
            self.loadingImage.Hide()

        self.tipTextLine.SetText(settinginfo.GetTipText())

        width = float(wndMgr.GetScreenWidth()) / float(
            self.loadingImage.GetWidth())
        height = float(wndMgr.GetScreenHeight()) / float(
            self.loadingImage.GetHeight())

        self.loadingImage.SetScale(width, height)
        self.loadingGage.SetPercentage(2, 100)

        self.Show()

        chrSlot = self.stream.GetCharacterSlot()
        GFHhg54GHGhh45GHGH.SendSelectCharacterPacket(chrSlot)

        app.SetFrameSkip(0)
Beispiel #3
0
import chat
import wndMgr
import GFHhg54GHGhh45GHGH
import app
import ime
import localeInfo
import colorInfo
import constInfo
import systemSetting
import fgGHGjjFHJghjfFG1545gGG

ENABLE_CHAT_COMMAND = True
ENABLE_LAST_SENTENCE_STACK = True
ENABLE_INSULT_CHECK = True

if localeInfo.IsHONGKONG():
    ENABLE_LAST_SENTENCE_STACK = True

if localeInfo.IsEUROPE():
    ENABLE_CHAT_COMMAND = False

if localeInfo.IsCANADA():
    ENABLE_LAST_SENTENCE_STACK = False

chatInputSetList = []


def InsertChatInputSetWindow(wnd):
    global chatInputSetList
    chatInputSetList.append(wnd)