Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #CODE BY JOIN(ADI)
- import ui
- import player
- import constInfo
- import chat
- import event
- import uiZapis
- class TeleportDialog(ui.ScriptWindow):
- def __init__(self):
- ui.ScriptWindow.__init__(self)
- self.__LoadDialog()
- self.UpdateMaps()
- self.wndZapis = uiZapis.ZapisDialog()
- def __del__(self):
- ui.ScriptWindow.__del__(self)
- def __LoadDialog(self):
- try:
- pyScrLoader = ui.PythonScriptLoader()
- pyScrLoader.LoadScriptFile(self, "uiscript/tpwindow.py")
- self.GetChild("TitleBar").SetCloseEvent(ui.__mem_func__(self.Close))
- self.Jinno = self.GetChild("jinno")
- self.Shinsoo = self.GetChild("shinsoo")
- self.Jinnom2 = self.GetChild("jinnom2")
- self.Shinsoom2 = self.GetChild("shinsoom2")
- self.Exp1 = self.GetChild("exp1")
- self.Exp2 = self.GetChild("exp2")
- self.Exp3 = self.GetChild("exp3")
- self.Exp4 = self.GetChild("exp4")
- self.Exp5 = self.GetChild("exp5")
- self.Exp6 = self.GetChild("exp6")
- self.Exp7 = self.GetChild("exp7")
- self.Exp8 = self.GetChild("exp8")
- self.Zapis1 = self.GetChild("zapis1")
- self.Zapis2 = self.GetChild("zapis2")
- self.Zapis3 = self.GetChild("zapis3")
- self.Zapis4 = self.GetChild("zapis4")
- self.Zapis5 = self.GetChild("zapis5")
- self.Zapis6 = self.GetChild("zapis6")
- self.Zapis7 = self.GetChild("zapis7")
- self.Zapis8 = self.GetChild("zapis8")
- self.Jinno.SetEvent(ui.__mem_func__(self.ClickJinno))
- self.Shinsoo.SetEvent(ui.__mem_func__(self.ClickShinsoo))
- self.Jinnom2.SetEvent(ui.__mem_func__(self.ClickJinnom2))
- self.Shinsoom2.SetEvent(ui.__mem_func__(self.ClickShinsoom2))
- self.Exp1.SetEvent(ui.__mem_func__(self.ClickExp1))
- self.Exp2.SetEvent(ui.__mem_func__(self.ClickExp2))
- self.Exp3.SetEvent(ui.__mem_func__(self.ClickExp3))
- self.Exp4.SetEvent(ui.__mem_func__(self.ClickExp4))
- self.Exp5.SetEvent(ui.__mem_func__(self.ClickExp5))
- self.Exp6.SetEvent(ui.__mem_func__(self.ClickExp6))
- self.Exp7.SetEvent(ui.__mem_func__(self.ClickExp7))
- self.Exp8.SetEvent(ui.__mem_func__(self.ClickExp8))
- self.Zapis1.SetEvent(ui.__mem_func__(self.ClickZapis1))
- self.Zapis2.SetEvent(ui.__mem_func__(self.ClickZapis2))
- self.Zapis3.SetEvent(ui.__mem_func__(self.ClickZapis3))
- self.Zapis4.SetEvent(ui.__mem_func__(self.ClickZapis4))
- self.Zapis5.SetEvent(ui.__mem_func__(self.ClickZapis5))
- self.Zapis6.SetEvent(ui.__mem_func__(self.ClickZapis6))
- self.Zapis7.SetEvent(ui.__mem_func__(self.ClickZapis7))
- self.Zapis8.SetEvent(ui.__mem_func__(self.ClickZapis8))
- except:
- import exception
- exception.Abort("TeleportDialog.LoadDialog.BindObject")
- def ClickJinno(self):
- constInfo.INPUT_DATA = 1
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickShinsoo(self):
- constInfo.INPUT_DATA = 2
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickJinnom2(self):
- constInfo.INPUT_DATA = 3
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickShinsoom2(self):
- constInfo.INPUT_DATA = 4
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickExp1(self):
- constInfo.INPUT_DATA = 5
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickExp2(self):
- constInfo.INPUT_DATA = 6
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickExp3(self):
- constInfo.INPUT_DATA = 7
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickExp4(self):
- constInfo.INPUT_DATA = 8
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickExp5(self):
- constInfo.INPUT_DATA = 9
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickExp6(self):
- constInfo.INPUT_DATA = 10
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickExp7(self):
- constInfo.INPUT_DATA = 11
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickExp8(self):
- constInfo.INPUT_DATA = 12
- event.QuestButtonClick(constInfo.TP_QUEST)
- def ClickZapis1(self):
- # if self.wndZapis.IsShow():
- # self.wndZapis.Hide()
- # else:
- self.wndZapis.Show()
- constInfo.ZAPIS_DATA = 13
- def ClickZapis2(self):
- # if self.wndZapis.IsShow():
- # self.wndZapis.Hide()
- # else:
- self.wndZapis.Show()
- constInfo.ZAPIS_DATA = 14
- def ClickZapis3(self):
- # if self.wndZapis.IsShow():
- # self.wndZapis.Hide()
- # else:
- self.wndZapis.Show()
- constInfo.ZAPIS_DATA = 15
- def ClickZapis4(self):
- # if self.wndZapis.IsShow():
- # self.wndZapis.Hide()
- # else:
- self.wndZapis.Show()
- constInfo.ZAPIS_DATA = 16
- def ClickZapis5(self):
- # if self.wndZapis.IsShow():
- # self.wndZapis.Hide()
- # else:
- self.wndZapis.Show()
- constInfo.ZAPIS_DATA = 17
- def ClickZapis6(self):
- # if self.wndZapis.IsShow():
- # self.wndZapis.Hide()
- # else:
- self.wndZapis.Show()
- constInfo.ZAPIS_DATA = 18
- def ClickZapis7(self):
- # if self.wndZapis.IsShow():
- # self.wndZapis.Hide()
- # else:
- self.wndZapis.Show()
- constInfo.ZAPIS_DATA = 19
- def ClickZapis8(self):
- # if self.wndZapis.IsShow():
- # self.wndZapis.Hide()
- # else:
- self.wndZapis.Show()
- constInfo.ZAPIS_DATA = 20
- def UpdateMaps(self):
- self.Zapis1.SetText(constInfo.MAP_NAME.split("|")[0].replace("_", " "))
- self.Zapis2.SetText(constInfo.MAP_NAME.split("|")[1].replace("_", " "))
- self.Zapis3.SetText(constInfo.MAP_NAME.split("|")[2].replace("_", " "))
- self.Zapis4.SetText(constInfo.MAP_NAME.split("|")[3].replace("_", " "))
- self.Zapis5.SetText(constInfo.MAP_NAME.split("|")[4].replace("_", " "))
- self.Zapis6.SetText(constInfo.MAP_NAME.split("|")[5].replace("_", " "))
- self.Zapis7.SetText(constInfo.MAP_NAME.split("|")[6].replace("_", " "))
- self.Zapis8.SetText(constInfo.MAP_NAME.split("|")[7].replace("_", " "))
- def Close(self):
- self.Hide()
- if self.wndZapis.IsShow():
- self.wndZapis.Close()
- def OnPressEscapeKey(self):
- self.Close()
- if self.wndZapis.IsShow():
- self.wndZapis.Close()
- return TRUE
Advertisement
Add Comment
Please, Sign In to add comment