Esempio n. 1
0
 def MakeToolTip(self):
     toolTip = uiToolTip.ToolTip()
     toolTip.SetParent(self)
     toolTip.SetPosition(1, 1)
     toolTip.SetFollow(False)
     toolTip.Show()
     self.toolTip = toolTip
Esempio n. 2
0
    def __SetEmotionSlot(self):

        self.emotionToolTip = uiToolTip.ToolTip()

        for slot in (self.soloEmotionSlot, self.dualEmotionSlot):
            slot.SetSlotStyle(wndMgr.SLOT_STYLE_NONE)
            slot.SetSelectItemSlotEvent(ui.__mem_func__(self.__SelectEmotion))
            slot.SetUnselectItemSlotEvent(
                ui.__mem_func__(self.__ClickEmotionSlot))
            slot.SetUseSlotEvent(ui.__mem_func__(self.__ClickEmotionSlot))
            slot.SetOverInItemEvent(ui.__mem_func__(self.__OverInEmotion))
            slot.SetOverOutItemEvent(ui.__mem_func__(self.__OverOutEmotion))
            slot.AppendSlotButton("d:/ymir work/ui/game/windows/btn_plus_up.sub",\
                    "d:/ymir work/ui/game/windows/btn_plus_over.sub",\
                    "d:/ymir work/ui/game/windows/btn_plus_down.sub")

        for slotIdx, datadict in emotion.EMOTION_DICT.items():
            emotionIdx = slotIdx

            slot = self.soloEmotionSlot
            if slotIdx > 50:
                slot = self.dualEmotionSlot

            slot.SetEmotionSlot(slotIdx, emotionIdx)
            slot.SetCoverButton(slotIdx)
Esempio n. 3
0
	def LoadWindow(self):
		try:
			pyScrLoader = ui.PythonScriptLoader()
			pyScrLoader.LoadScriptFile(self, "exscript/dungeonintro.py")
		except:
			import exception
			exception.Abort("DungeonIntroWindow.LoadWindow.LoadObject")
		
		self.difficultyToolTip = uiToolTip.ToolTip()
		self.difficultyToolTip.HideToolTip()
		
		self.descListBox = self.GetChild("desc_box")
		self.descScrollBar = self.GetChild("scrollBar")
		self.descScrollBar.Hide()
		
		self.descListBox.InsertDescItem("Brauchte mal ne Pause vom blöden C++,")
		self.descListBox.InsertDescItem("denn der scheiß stinkt!!! Also ne Dungeon")
		self.descListBox.InsertDescItem("EintrittsGUI ka. Mit schwierigkeits")
		self.descListBox.InsertDescItem("auswahl. Es ist 00:43Uhr meine gedanken")
		self.descListBox.InsertDescItem("ergeben irgendwie keinen sinn mehr")
		self.descListBox.InsertDescItem("ich geh besser Pennen. ^^")
		self.descListBox.InsertEmptyItem()
		self.descListBox.InsertDescItem("P.s: Die Schwierigkeitsanzeige hat nen")
		self.descListBox.InsertDescItem("     geilen ToolTip! HaHa. Gute Nacht.")
		self.difficultyNumber = self.GetChild("difficulty_number")
		self.difficultyPlus = self.GetChild("plus_button")
		self.difficultyMinus = self.GetChild("minus_button")
		self.difficultyFrame = self.GetChild("difficulty_frame")
		
		self.difficultyPlus.SetEvent(self.PlusDifficulty)
		self.difficultyMinus.SetEvent(self.MinusDifficulty)
		self.UpdateChangeButtonStatus()
    def Open(self):
        #print "OPEN EMPIRE WINDOW ----------------------------------------------------------------------------"

        self.SetSize(wndMgr.GetScreenWidth(), wndMgr.GetScreenHeight())
        self.SetWindowName("SelectEmpireWindow")
        self.Show()

        if not self.__LoadScript(uiScriptLocale.LOCALE_UISCRIPT_PATH +
                                 "New_SelectEmpireWindow.py"):
            dbg.TraceError("SelectEmpireWindow.Open - __LoadScript Error")
            return

        self.OnSelectEmpire(self.empireID)
        self.__CreateButtons()
        self.__CreateDescriptionBox()
        app.ShowCursor()

        if musicInfo.selectMusic != "":
            snd.SetMusicVolume(systemSetting.GetMusicVolume())
            snd.FadeInMusic("BGM/" + musicInfo.selectMusic)

            self.toolTip = uiToolTip.ToolTip()
            self.toolTip.ClearToolTip()

            self.ShowToolTip = False
Esempio n. 5
0
    def __init__(self):
        ui.ExpandedImageBox.__init__(self)

        self.loverName = ""
        self.lovePoint = 0

        self.toolTip = uiToolTip.ToolTip(100)
        self.toolTip.HideToolTip()
Esempio n. 6
0
	def __LoadVariables(self):
		self.SetDefaultStatistic()
		self.SetDefaultPageVar()
		self.loadingBar = LoadingBar()
		self.quest_cmd = ''
		self.qid = 0
		self.last_update = 0
		self.toolTip = uiToolTip.ToolTip()
Esempio n. 7
0
 def OnMouseOverIn(self):
     if -1 != self.lovePoint:
         if not self.lovePointToolTip:
             self.lovePointToolTip = uiToolTip.ToolTip(100)
             self.lovePointToolTip.SetTitle(self.name)
             self.lovePointToolTip.AppendTextLine(
                 localeInfo.AFF_LOVE_POINT % (self.lovePoint))
             self.lovePointToolTip.ResizeToolTip()
         self.lovePointToolTip.ShowToolTip()
Esempio n. 8
0
	def OnUpdate(self):
		self.GetObject('main','textLimitChars').SetText(localeInfo.ANNOUNCEMENT_MANAGER_LENGTH_TEXT.format(len(self.GetObject('main','text_value').GetText()), LOCALE_MAX_TEXT_LENGTH[self.selectType]))
	
		(mouseX, mouseY) = wndMgr.GetMousePosition()
		for i in xrange(app.LANGUAGE_MAX_NUM + 1):
			if self.GetObject('main','checkBox')[i][0].IsIn():
				self.toolTip = uiToolTip.ToolTip()
				self.toolTip.SetPosition(mouseX + 25, mouseY)
				self.toolTip.AppendDescription(LOCALE_DESCRIPTION_LANGUAGE[i], None, 0xffffa879)
Esempio n. 9
0
	def OnUpdate(self):
		(mouseX, mouseY) = wndMgr.GetMousePosition()

		for i in xrange(app.LANGUAGE_MAX_NUM + 1):
			if self.checkBoxDataList[i].IsIn():
				self.toolTipDialog = uiToolTip.ToolTip()
				self.toolTipDialog.SetPosition(mouseX + self.X_PARSER_TOOLTIP, mouseY)
				self.toolTipDialog.RectSize(self.WND_TOOLTIP_WIDTH, 0)
				self.toolTipDialog.AppendDescription(LOCALE_DESCRIPTION_LANGUAGE[i], None, 0xffffa879)	
Esempio n. 10
0
	def OnUpdate(self):
		(x, y) = wndMgr.GetMousePosition()

		for key in xrange(oxevent.MAX_RANGE):
			if self.main["elements"]["slot"][key].IsIn() ^ self.main["elements"]["face"][key].IsIn():
				if self.GetExistKey(key):
					self.textToolTip = uiToolTip.ToolTip()
					self.textToolTip.SetPosition(x + 15, y)
					self.textToolTip.AppendPlayersDesc(self.main["data"]["name"].get(key),self.main["data"]["level"].get(key),self.main["data"]["guild"].get(key), self.main["data"]["empire"].get(key),self.main["data"]["job"].get(key), self.main["data"]["date"].get(key),self.main["data"]["correct_answers"].get(key))
Esempio n. 11
0
    def __init__(self):
        ui.ExpandedImageBox.__init__(self)

        self.loverName = ""
        self.lovePoint = 0
        self.potionType = fgGHGjjFHJghjfFG1545gGG.AUTO_POTION_TYPE_HP
        self.filePath = ""

        self.toolTip = uiToolTip.ToolTip(100)
        self.toolTip.HideToolTip()
Esempio n. 12
0
 def __init__(self):
     ui.Window.__init__(self)
     self.SetSize(16, 16)
     # self.SetPosition(wndMgr.GetScreenWidth() - 149,58)
     self.MakeSkull()
     self.toolTip = uiToolTip.ToolTip()
     self.toolTip.HideToolTip()
     self.name = "NoName"
     self.respawnTime = 0
     self.Show()
Esempio n. 13
0
    def __CreateGameTypeToolTip(self, title, descList):
        tooltip = uiToolTip.ToolTip()
        tooltip.SetTitle(title)
        tooltip.AppendSpace(7)

        for desc in descList:
            tooltip.AutoAppendTextLine(desc)

        tooltip.AlignHorizonalCenter()
        tooltip.SetTop()
        return tooltip
 def CreateInfoToolTip(self):
     toolTip = uiToolTip.ToolTip()
     toolTip.SetTitle(localeInfo.CHANGE_TOOLTIP_TITLE)
     toolTip.AppendSpace(5)
     toolTip.AutoAppendTextLine(localeInfo.CHANGE_TOOLTIP_LINE1)
     toolTip.AutoAppendTextLine(localeInfo.CHANGE_TOOLTIP_LINE2)
     toolTip.AutoAppendTextLine(localeInfo.CHANGE_TOOLTIP_LINE3)
     toolTip.AutoAppendTextLine(localeInfo.CHANGE_TOOLTIP_LINE4)
     toolTip.AutoAppendTextLine(localeInfo.CHANGE_TOOLTIP_LINE5)
     toolTip.AutoAppendTextLine(localeInfo.CHANGE_TOOLTIP_LINE6)
     toolTip.AlignHorizonalCenter()
     return toolTip
Esempio n. 15
0
    def LoadWindow(self):
        try:
            pyScrLoader = ui.PythonScriptLoader()
            pyScrLoader.LoadScriptFile(self, "exscript/adventboard.py")
        except:
            import exception
            exception.Abort("AdventWindow.LoadWindow.LoadObject")

        # self.GetChild("Close_Button").SetEvent(self.Close)
        self.rewardDialog = self.GetChild("reward_background")
        self.rewardDialogTitle = self.GetChild("rewardTitle")
        self.rewardDialogItemName = self.GetChild("rewardItemName")
        self.rewardDialogInfo = self.GetChild("rewardDialogReminder")
        self.rewardDialogItemImage = self.GetChild("rewardItemSlot")
        self.rewardDialogCloseButton = self.GetChild(
            "Close_RewardDialogButton")
        i = 1
        self.adventDayButtonDict = []
        while i <= 24:
            self.adventDayButtonDict.append(
                self.GetChild("button_day_0" + str(i)))
            self.adventDayButtonDict[i - 1].SetEvent(
                lambda arg=i: self.OnClickAdventButton(arg))
            self.adventDayButtonDict[
                i -
                1].ShowToolTip = lambda arg=i: self.__OverInAdventButton(arg)
            self.adventDayButtonDict[
                i -
                1].HideToolTip = lambda arg=i: self.__OverOutAdventButton()
            if ENABLE_DAY_TEXT_LINE:
                self.adventDayButtonDict[i - 1].SetText(str(i))
            self.adventDayButtonDict[i - 1].Hide()
            i = i + 1

        self.rewardDialog.SetColor(self.BOARD_COLOR)
        self.rewardDialogItemName.SetFontColor(0.5411, 0.7254, 0.5568)
        self.rewardDialogTitle.SetFontColor(0.9490, 0.9058, 0.7568)
        self.rewardDialogCloseButton.SetEvent(self.CloseRewardDialog)
        self.toolTip = uiToolTip.ToolTip()

        # self.explodeTest = Explosion()
        # self.explodeTest.SetParent(self)
        # self.explodeTest.SetPosition(100,100)

        ##################
        ## DEV SPÄTER LÖSCHEN!!!
        self.Open()

        self.SetCurrentDay(5)
        for i in xrange(24):
            self.InitAdventButton(i + 1, app.GetRandom(1, 2))

        self.OpenRewardDialog(27001, 1)
Esempio n. 16
0
	def CreateToolTip(self, parent, title, desc, x, y):
		import uiToolTip
		self.toolTip = uiToolTip.ToolTip()
		self.toolTip.SetWindowHorizontalAlignCenter()
		self.toolTip.SetFollow(False)
		self.toolTip.SetTitle(title)
		self.toolTip.SetPosition(x, y)

		desc = desc.replace("|", "/")
		for line in desc.split("/"):
			self.toolTip.AutoAppendTextLine(line)

		self.toolTip.ResizeToolTip()
		self.toolTip.Hide()
Esempio n. 17
0
    def MakeButton(self):

        self.toolTip = uiToolTip.ToolTip()
        self.toolTip.HideToolTip()

        self.button = ui.Button()
        self.button.SetParent(self)
        self.button.SetPosition(0, 0)
        self.button.SetUpVisual("yamato_button/q_mark_01.tga")
        self.button.SetOverVisual("yamato_button/q_mark_02.tga")
        self.button.SetDownVisual("yamato_button/q_mark_02.tga")
        self.button.ShowToolTip = lambda arg=1: self.ShowToolTip(arg)
        self.button.HideToolTip = lambda arg=1: self.HideToolTip()
        self.button.Show()
Esempio n. 18
0
	def __CreateGameTypeToolTip(self, title, descList):
		toolTip = uiToolTip.ToolTip()
		toolTip.SetTitle(title)

		for desc in descList.itervalues():
			if desc == "[ENTER]":
				# Show horizontal line if token is found in desc.
				toolTip.AppendHorizontalLine()
			else:
				toolTip.AutoAppendTextLine(desc)
				toolTip.AppendSpace(1)

		toolTip.TextAlignHorizonalCenter()
		toolTip.SetTop()
		return toolTip
Esempio n. 19
0
	def __Construct(self):
		self.isLoaded = False
		self.isInformationPage = False

		self.isRolling = False

		self.reelResult = {}
		self.rollTime = {}
		self.isRolled = {}

		self.hasWon = 0
		self.hasJackpot = 0
		self.betIndex = 0

		self.toolTip = uiToolTip.ToolTip()
		self.toolTipHelp = None
Esempio n. 20
0
	def LoadWindow(self):
		try:
			pyScrLoader = ui.PythonScriptLoader()
			pyScrLoader.LoadScriptFile(self, "exscript/calenderwindow.py")
		except:
			import exception
			exception.Abort("CalenderWindow.LoadWindow.LoadObject")
			
		self.GetChild("TitleBar").SetCloseEvent(self.Close)
		self.GetChild("bottom_tutorial_line").SetFontColor(0.9490, 0.9058, 0.7568)
		
		self.toolTip = uiToolTip.ToolTip()
		
		i = 1
		self.eventDayTextLine = []
		while i <= self.boxSlots:
			self.eventDayTextLine.append(self.GetChild("day_slot_0" + str(i) + "_text"))
			i = i + 1
		
		i = 1
		self.eventDayImage = []
		while i <= self.boxSlots:
			self.eventDayImage.append(self.GetChild("day_slot_0" + str(i) + "_img"))
			i = i + 1

		i = 1
		while i <= self.boxSlots:
			self.GetChild("day_slot_0" + str(i) + "_button").SetEvent(lambda arg=i: self.OnClickEventSlot(arg))
			i = i + 1

			
		i = 1
		while i <= self.boxSlots:
			self.GetChild("day_slot_0" + str(i) + "_button").ShowToolTip = lambda arg=i: self.__OverInEventButton(arg)
			self.GetChild("day_slot_0" + str(i) + "_button").HideToolTip = lambda arg=i: self.__OverOutEventButton()
			i = i + 1			
			

			
			
		
		self.SetCalenderStartEndPosition(1,30)	
		
		
		self.AppendEventInfo(18,"test","17:00")
		self.AppendEventInfo(22,"ox","17:00")
Esempio n. 21
0
	def __CreateAffectToolTip(self):
		affectToolTip = uiToolTip.ToolTip(220)
		affectToolTip.Hide()
		self.affectToolTip = affectToolTip
Esempio n. 22
0
					height = self.GetHeight()
					width = self.GetWidth()
					self.SetSize(width, height - 22)
					self.GetChild("board").SetSize(width, height - 22)

				else:
					self.wndMoneyIcon = self.GetChild("Money_Icon")
					self.wndChequeIcon = self.GetChild("Cheque_Icon")
				
					self.wndMoneyIcon.SetEvent(ui.__mem_func__(self.EventProgress), "mouse_over_in", 0)
					self.wndChequeIcon.SetEvent(ui.__mem_func__(self.EventProgress), "mouse_over_in", 1)
				
					self.wndMoneyIcon.SetEvent(ui.__mem_func__(self.EventProgress), "mouse_over_out", 0)
					self.wndChequeIcon.SetEvent(ui.__mem_func__(self.EventProgress), "mouse_over_out", 1)
				
					self.toolTip = uiToolTip.ToolTip()
					self.toolTip.ClearToolTip()
# ********************************************************************** #
#Search:
		## RefineDialog

#Add BEFORE:
		## PickETCDialog
		if app.ENABLE_CHEQUE_SYSTEM:
			dlgPickETC = uiPickETC.PickETCDialog()
			dlgPickETC.LoadDialog()
			dlgPickETC.Hide()
# ********************************************************************** #
#Search:
		self.wndMoneySlot.SetEvent(ui.__mem_func__(self.OpenPickMoneyDialog))
#Add
if app.ENABLE_SORT_INVEN:
	import uiToolTip
	
#Find
			self.equipmentTab.append(self.GetChild("Equipment_Tab_02"))

#Add
			if app.ENABLE_SORT_INVEN:
				self.yenilebutton = self.GetChild2("YenileButton")
				self.yenilebutton.SetEvent(ui.__mem_func__(self.ClickYenileButton))
				self.tooltipI = uiToolTip.ToolTip()
				self.tooltipI.Hide()
				self.tooltipInfo = [self.tooltipI]*4
				self.InformationText = [localeInfo.YENILE_BUTTON_TITLE,
										localeInfo.YENILE_BUTTON,
										localeInfo.YENILE_BUTTON2,
										localeInfo.YENILE_BUTTON3
				]
				for i in xrange(len(self.tooltipInfo)):
					self.tooltipInfo[i].SetFollow(True)
					self.tooltipInfo[i].AlignHorizonalCenter()
					if i == 0:
						self.tooltipInfo[i].AppendTextLine(self.InformationText[i], 0xffffff00)
					else:
						self.tooltipInfo[i].AppendTextLine(self.InformationText[i])
					self.tooltipInfo[i].Hide()

#Find
	def Close(self):
		self.Hide()
Esempio n. 24
0
    def __init__(self):
        ui.ExpandedImageBox.__init__(self)

        #self.textLineList = []
        self.toolTip = uiToolTip.ToolTip(100)
        self.toolTip.HideToolTip()
Esempio n. 25
0
	def __LoadWindow(self):
		try:
			pyScrLoader = ui.PythonScriptLoader()
			pyScrLoader.LoadScriptFile(self, "uiscript/PetInformationWindow.py")
		except:
			import exception
			exception.Abort("PetInformationWindow.LoadWindow.LoadObject")
			
		try:
			self.feedwind = uipetfeed.PetFeedWindow()
			self.board = self.GetChild("board")
			self.boardclose = self.GetChild("CloseButton")
			
			self.slotimgpet = self.GetChild("UpBringing_Pet_Slot")
			self.evolname = self.GetChild("EvolName")
			self.petname = self.GetChild("PetName")
			
			self.expwind = self.GetChild("UpBringing_Pet_EXP_Gauge_Board")
			self.tooltipexp = []
			for i in range(0,4):
				self.tooltipexp.append(self.TextToolTip(15*i))
				self.tooltipexp[i].Hide()
			
			self.petlifeg = self.GetChild("LifeGauge")
			
			self.petlevel = self.GetChild("LevelValue")
			self.petexpa = self.GetChild("UpBringing_Pet_EXPGauge_01")
			self.petexpb = self.GetChild("UpBringing_Pet_EXPGauge_02")
			self.petexpc = self.GetChild("UpBringing_Pet_EXPGauge_03")
			self.petexpd = self.GetChild("UpBringing_Pet_EXPGauge_04")
			self.petexpe = self.GetChild("UpBringing_Pet_EXPGauge_05")
			self.petexppages = []			
			self.petexppages.append(self.petexpa)
			self.petexppages.append(self.petexpb)
			self.petexppages.append(self.petexpc)
			self.petexppages.append(self.petexpd)
			self.petexppages.append(self.petexpe)
			
			for exp in self.petexppages:
				exp.SetSize(0, 0)
				#exp.Hide()
				
			
			
			
			
			self.petages = self.GetChild("AgeValue")
			
			self.petdur = self.GetChild("LifeTextValue")
			
			#gaugehp
			
			self.nutribtn = self.GetChild("FeedLifeTimeButton")
			self.sviluppobtn = self.GetChild("FeedEvolButton")
			self.itemexp = self.GetChild("FeedExpButton")
			
			self.pethp = self.GetChild("HpValue")
			self.petdef = self.GetChild("DefValue")
			self.petsp = self.GetChild("SpValue")
			
			self.petskill0 = self.GetChild("PetSkillSlot0")
			
			
			
			
			
			
			
			#self.petskill0.SetPetSkillSlot(0, 2, 10)
			#self.petskill0.SetPetSkillSlot(1, 11, 10)
			#self.petskill0.SetPetSkillSlot(2, 5, 10)
			self.petskill0.SetSlot(0, 2, 32, 32, petskill.GetEmptySkill())
			self.petskill0.SetSlot(1, 2, 32, 32, petskill.GetEmptySkill())
			self.petskill0.SetSlot(2, 2, 32, 32, petskill.GetEmptySkill())
			#self.petskill0.SetCoverButton(0)
			#self.petskill0.SetCoverButton(1)
			#self.petskill0.SetCoverButton(2)
			#self.petskill0.SetAlwaysRenderCoverButton(0, TRUE)
			#self.petskill0.SetAlwaysRenderCoverButton(1, TRUE)
			#self.petskill0.SetAlwaysRenderCoverButton(2, TRUE)
			self.petskill0.SetSelectItemSlotEvent(ui.__mem_func__(self.UseSkill))
			self.petskill0.SetUseSlotEvent(ui.__mem_func__(self.UseSkill))
			self.petskill0.SetOverInItemEvent(ui.__mem_func__(self.PetSkillTooltipShow))
			self.petskill0.SetOverOutItemEvent(ui.__mem_func__(self.PetSkillTooltipHide))	
			
			
			
			self.SetDefaultInfo()
			
			self.arrytooltip = [ [-1,-1], [-1,-1], [-1,-1]]
			PET_FILE_NAME = "%s/pet_skill.txt" % app.GetLocalePath()
			PET_FILE_SKILL = "%s/pet_skill_bonus.txt" % app.GetLocalePath()
			self.linespet = pack_open(PET_FILE_NAME, "r").readlines()
			self.linespetskill = pack_open(PET_FILE_SKILL, "r").readlines()
			self.SkillTooltip = uiToolTip.ToolTip(180)
			
			
			#Event
			self.boardclose.SetEvent(ui.__mem_func__(self.Close,))
			self.nutribtn.SetToggleDownEvent(lambda arg=0,arg1=1: self.OpenFeedBox(arg,arg1))
			self.nutribtn.SetToggleUpEvent(lambda arg=1,arg1=0: self.OpenFeedBox(arg,arg1))
			self.itemexp.SetToggleDownEvent(lambda arg=0,arg1=3: self.OpenFeedBox(arg,arg1))
			self.itemexp.SetToggleUpEvent(lambda arg=1,arg1=0: self.OpenFeedBox(arg,arg1))
			self.sviluppobtn.SetToggleDownEvent(lambda arg=0: self.evolution(arg))
			self.sviluppobtn.SetToggleUpEvent(lambda arg=1: self.evolution(arg))
			
			
		except:
			import exception
			exception.Abort("PetInformationWindow.LoadWindow.BindObject")
Esempio n. 26
0
 def MakeToolTip(self):
     toolTip = uiToolTip.ToolTip()
     toolTip.Show()
     self.toolTip = toolTip
Esempio n. 27
0
	def __BindObject(self):
		self.toolTip = uiToolTip.ToolTip()
		self.toolTipJob = uiToolTip.ToolTip()
		self.toolTipAlignment = uiToolTip.ToolTip(130)		

		self.faceImage = self.GetChild("Face_Image")

		faceSlot=self.GetChild("Face_Slot")
		if 949 == app.GetDefaultCodePage():
			faceSlot.SAFE_SetStringEvent("MOUSE_OVER_IN", self.__ShowJobToolTip)
			faceSlot.SAFE_SetStringEvent("MOUSE_OVER_OUT", self.__HideJobToolTip)

		self.statusPlusLabel = self.GetChild("Status_Plus_Label")
		self.statusPlusValue = self.GetChild("Status_Plus_Value")		

		self.characterNameSlot = self.GetChild("Character_Name_Slot")			
		self.characterNameValue = self.GetChild("Character_Name")
		self.guildNameSlot = self.GetChild("Guild_Name_Slot")
		self.guildNameValue = self.GetChild("Guild_Name")
		self.characterNameSlot.SAFE_SetStringEvent("MOUSE_OVER_IN", self.__ShowAlignmentToolTip)
		self.characterNameSlot.SAFE_SetStringEvent("MOUSE_OVER_OUT", self.__HideAlignmentToolTip)

		self.activeSlot = self.GetChild("Skill_Active_Slot")
		self.activeSkillPointValue = self.GetChild("Active_Skill_Point_Value")
		self.supportSkillPointValue = self.GetChild("Support_Skill_Point_Value")
		self.skillGroupButton1 = self.GetChild("Skill_Group_Button_1")
		self.skillGroupButton2 = self.GetChild("Skill_Group_Button_2")
		self.activeSkillGroupName = self.GetChild("Active_Skill_Group_Name")

		self.tabDict = {
			"STATUS"	: self.GetChild("Tab_01"),
			"SKILL"		: self.GetChild("Tab_02"),
			"EMOTICON"	: self.GetChild("Tab_03"),
			"QUEST"		: self.GetChild("Tab_04"),
		}

		self.tabButtonDict = {
			"STATUS"	: self.GetChild("Tab_Button_01"),
			"SKILL"		: self.GetChild("Tab_Button_02"),
			"EMOTICON"	: self.GetChild("Tab_Button_03"),
			"QUEST"		: self.GetChild("Tab_Button_04")
		}

		self.pageDict = {
			"STATUS"	: self.GetChild("Character_Page"),
			"SKILL"		: self.GetChild("Skill_Page"),
			"EMOTICON"	: self.GetChild("Emoticon_Page"),
			"QUEST"		: self.GetChild("Quest_Page")
		}

		self.titleBarDict = {
			"STATUS"	: self.GetChild("Character_TitleBar"),
			"SKILL"		: self.GetChild("Skill_TitleBar"),
			"EMOTICON"	: self.GetChild("Emoticon_TitleBar"),
			"QUEST"		: self.GetChild("Quest_TitleBar")
		}

		self.statusPlusButtonDict = {
			"HTH"		: self.GetChild("HTH_Plus"),
			"INT"		: self.GetChild("INT_Plus"),
			"STR"		: self.GetChild("STR_Plus"),
			"DEX"		: self.GetChild("DEX_Plus"),
		}

		self.statusMinusButtonDict = {
			"HTH-"		: self.GetChild("HTH_Minus"),
			"INT-"		: self.GetChild("INT_Minus"),
			"STR-"		: self.GetChild("STR_Minus"),
			"DEX-"		: self.GetChild("DEX_Minus"),
		}

		self.skillPageDict = {
			"ACTIVE" : self.GetChild("Skill_Active_Slot"),
			"SUPPORT" : self.GetChild("Skill_ETC_Slot"),
			"HORSE" : self.GetChild("Skill_Active_Slot"),
		}

		self.skillPageStatDict = {
			"SUPPORT"	: player.SKILL_SUPPORT,
			"ACTIVE"	: player.SKILL_ACTIVE,
			"HORSE"		: player.SKILL_HORSE,
		}

		self.skillGroupButton = (
			self.GetChild("Skill_Group_Button_1"),
			self.GetChild("Skill_Group_Button_2"),
		)

		
		global SHOW_ONLY_ACTIVE_SKILL
		global HIDE_SUPPORT_SKILL_POINT
		if SHOW_ONLY_ACTIVE_SKILL or HIDE_SUPPORT_SKILL_POINT:	
			self.GetChild("Support_Skill_Point_Label").Hide()

		self.soloEmotionSlot = self.GetChild("SoloEmotionSlot")
		self.dualEmotionSlot = self.GetChild("DualEmotionSlot")
		self.__SetEmotionSlot()

		self.questShowingStartIndex = 0
		self.questScrollBar = self.GetChild("Quest_ScrollBar")
		self.questScrollBar.SetScrollEvent(ui.__mem_func__(self.OnQuestScroll))
		self.questSlot = self.GetChild("Quest_Slot")
		for i in xrange(quest.QUEST_MAX_NUM):
			self.questSlot.HideSlotBaseImage(i)
			self.questSlot.SetCoverButton(i,\
											"d:/ymir work/ui/game/quest/slot_button_01.sub",\
											"d:/ymir work/ui/game/quest/slot_button_02.sub",\
											"d:/ymir work/ui/game/quest/slot_button_03.sub",\
											"d:/ymir work/ui/game/quest/slot_button_03.sub", True)

		self.questNameList = []
		self.questLastTimeList = []
		self.questLastCountList = []
		for i in xrange(quest.QUEST_MAX_NUM):
			self.questNameList.append(self.GetChild("Quest_Name_0" + str(i)))
			self.questLastTimeList.append(self.GetChild("Quest_LastTime_0" + str(i)))
			self.questLastCountList.append(self.GetChild("Quest_LastCount_0" + str(i)))
Esempio n. 28
0
 def __init__(self):
     ui.ExpandedImageBox.__init__(self)
     self.toolTip = uiToolTip.ToolTip(250)
     self.toolTip.HideToolTip()
Esempio n. 29
0
	def Open(self):
		print "OPEN CREATE WINDOW ----------------------------------------------------------------------------"

		playerSettingModule.LoadGameData("INIT")

		self.reservingRaceIndex = -1
		self.reservingShapeIndex = -1
		self.reservingStartTime = 0
		self.stat = [0, 0, 0, 0]

		self.gender = 0
		self.slot = -1
		#
		self.instanceIDs = []
		if app.ENABLE_WOLFMAN_CHARACTER:
			self.shapeList = [
				[0, 0, 0, 0, 0],
				[0, 0, 0, 0]]
		else:
			self.shapeList = [
				[0, 0, 0, 0],
				[0, 0, 0, 0]]

		self.descIndex = 0

		try:
			dlgBoard = ui.ScriptWindow()
			pythonScriptLoader = ui.PythonScriptLoader()
			pythonScriptLoader.LoadScriptFile(dlgBoard, uiScriptLocale.LOCALE_UISCRIPT_PATH + "createcharacterwindow.py")

		except:
			import exception
			exception.Abort("CreateCharacterWindow.Open.LoadObject")

		try:
			getChild = dlgBoard.GetChild

			self.NameList = {}
			self.NameList[MAN] = []
			self.NameList[MAN].append(getChild("name_warrior"))
			self.NameList[MAN].append(getChild("name_assassin"))
			self.NameList[MAN].append(getChild("name_sura"))
			self.NameList[MAN].append(getChild("name_shaman"))
			if app.ENABLE_WOLFMAN_CHARACTER:
				self.NameList[MAN].append(getChild("name_wolfman"))
			self.NameList[WOMAN] = []
			self.NameList[WOMAN].append(getChild("name_warrior"))
			self.NameList[WOMAN].append(getChild("name_assassin"))
			self.NameList[WOMAN].append(getChild("name_sura"))
			self.NameList[WOMAN].append(getChild("name_shaman"))

			self.GaugeList = []
			self.GaugeList.append(getChild("hth_gauge"))
			self.GaugeList.append(getChild("int_gauge"))
			self.GaugeList.append(getChild("str_gauge"))
			self.GaugeList.append(getChild("dex_gauge"))

			self.btnCreate = getChild("create_button")
			self.btnCancel = getChild("cancel_button")
			self.btnPrev = getChild("prev_button")
			self.btnNext = getChild("next_button")
			self.btnLeft = getChild("left_button")
			self.btnRight = getChild("right_button")
			self.textBoard = getChild("text_board")

			self.genderButtonList = []
			self.genderButtonList.append(getChild("gender_button_01"))
			self.genderButtonList.append(getChild("gender_button_02"))

			self.shapeButtonList = []
			self.shapeButtonList.append(getChild("shape_button_01"))
			self.shapeButtonList.append(getChild("shape_button_02"))

			self.editCharacterName = getChild("character_name_value")

			self.statValue = []
			self.statValue.append(getChild("hth_value"))
			self.statValue.append(getChild("int_value"))
			self.statValue.append(getChild("str_value"))
			self.statValue.append(getChild("dex_value"))

			getChild("hth_button").ShowToolTip = lambda arg=self.STAT_CON: self.OverInStatButton(arg)
			getChild("hth_button").HideToolTip = lambda arg=self.STAT_CON: self.OverOutStatButton()
			getChild("int_button").ShowToolTip = lambda arg=self.STAT_INT: self.OverInStatButton(arg)
			getChild("int_button").HideToolTip = lambda arg=self.STAT_INT: self.OverOutStatButton()
			getChild("str_button").ShowToolTip = lambda arg=self.STAT_STR: self.OverInStatButton(arg)
			getChild("str_button").HideToolTip = lambda arg=self.STAT_STR: self.OverOutStatButton()
			getChild("dex_button").ShowToolTip = lambda arg=self.STAT_DEX: self.OverInStatButton(arg)
			getChild("dex_button").HideToolTip = lambda arg=self.STAT_DEX: self.OverOutStatButton()

			getChild("hth_button").Hide()
			getChild("int_button").Hide()
			getChild("str_button").Hide()
			getChild("dex_button").Hide()

			self.backGround = getChild("BackGround")

		except:
			import exception
			exception.Abort("CreateCharacterWindow.Open.BindObject")

		self.btnCreate.SetEvent(ui.__mem_func__(self.CreateCharacter))
		self.btnCancel.SetEvent(ui.__mem_func__(self.CancelCreate))
		self.btnPrev.SetEvent(ui.__mem_func__(self.PrevDescriptionPage))
		self.btnNext.SetEvent(ui.__mem_func__(self.NextDescriptionPage))
		self.btnLeft.SetEvent(ui.__mem_func__(self.__DecreaseSlotIndex))
		self.btnRight.SetEvent(ui.__mem_func__(self.__IncreaseSlotIndex))

		self.genderButtonList[0].SetEvent(ui.__mem_func__(self.__SelectGender), MAN)
		self.genderButtonList[1].SetEvent(ui.__mem_func__(self.__SelectGender), WOMAN)

		self.shapeButtonList[0].SetEvent(ui.__mem_func__(self.__SelectShape), SHAPE0)
		self.shapeButtonList[1].SetEvent(ui.__mem_func__(self.__SelectShape), SHAPE1)
		self.editCharacterName.SetReturnEvent(ui.__mem_func__(self.CreateCharacter))
		self.editCharacterName.SetEscapeEvent(ui.__mem_func__(self.CancelCreate))
		self.dlgBoard = dlgBoard

		self.curRotation	= [] + self.SLOT_ROTATION[self.gender]
		self.destRotation	= [] + self.SLOT_ROTATION[self.gender]
		self.curNameAlpha	= [0.0, 0.0, 0.0, 0.0, 0.0]
		self.destNameAlpha	= [0.0, 0.0, 0.0, 0.0, 0.0]
		self.curGauge		= [0.0, 0.0, 0.0, 0.0]
		self.destGauge		= [0.0, 0.0, 0.0, 0.0]

		self.descriptionBox = self.DescriptionBox()
		self.descriptionBox.Show()

		self.chrRenderer = self.CharacterRenderer()
		self.chrRenderer.SetParent(self.backGround)
		self.chrRenderer.Show()

		self.toolTip = uiToolTip.ToolTip()
		self.toolTip.ClearToolTip()

		self.editCharacterName.SetText("")

		self.EnableWindow()
		self.__SelectSlot(0)

		app.SetCamera(500.0, 10.0, 180.0, 95.0)

		self.__MakeCharacter(MAN, 0, playerSettingModule.RACE_WARRIOR_M)
		self.__MakeCharacter(MAN, 1, playerSettingModule.RACE_ASSASSIN_M)
		self.__MakeCharacter(MAN, 2, playerSettingModule.RACE_SURA_M)
		self.__MakeCharacter(MAN, 3, playerSettingModule.RACE_SHAMAN_M)
		if app.ENABLE_WOLFMAN_CHARACTER:
			self.__MakeCharacter(MAN, 4, playerSettingModule.RACE_WOLFMAN_M)

		self.__MakeCharacter(WOMAN, 0, playerSettingModule.RACE_WARRIOR_W)
		self.__MakeCharacter(WOMAN, 1, playerSettingModule.RACE_ASSASSIN_W)
		self.__MakeCharacter(WOMAN, 2, playerSettingModule.RACE_SURA_W)
		self.__MakeCharacter(WOMAN, 3, playerSettingModule.RACE_SHAMAN_W)

		self.__SelectGender(app.GetRandom(MAN, WOMAN))
		self.__SelectShape(0)
		self.__SelectSlot(app.GetRandom(0, SLOT_COUNT[self.gender]-1))

		self.dlgBoard.Show()
		self.Show()

		if musicInfo.createMusic != "":
			snd.SetMusicVolume(systemSetting.GetMusicVolume())
			snd.FadeInMusic("BGM/"+musicInfo.createMusic)

		app.ShowCursor()
Esempio n. 30
0
	def __init__(self):
		ui.Window.__init__(self)
		self.SetWindowName("ExpandedMoneyTaskBar")
		self.toolTip = uiToolTip.ToolTip(40)
		self.LoadWindow()