def OnUpdate(self): if self.end: return if self.biologWindow_sliding: if app.GetGlobalTimeStamp( ) >= self.next_move and BIOLOG_BINARY_LOADED["coordonates"][ 0] != wndMgr.GetScreenHeight() - 50 + 500: self.loader_['default'][0].SetPosition( wndMgr.GetScreenWidth() / 2 + 158, BIOLOG_BINARY_LOADED["coordonates"][0] - 10) BIOLOG_BINARY_LOADED["coordonates"][ 0] = BIOLOG_BINARY_LOADED["coordonates"][0] - 5 self.next_move = app.GetGlobalTimeStamp() if BIOLOG_BINARY_LOADED["coordonates"][ 0] == wndMgr.GetScreenHeight() - 50 + 500: self.biologWindow_sliding = 0 self.next_move = app.GetGlobalTimeStamp() + 3 else: if app.GetGlobalTimeStamp( ) >= self.next_move and BIOLOG_BINARY_LOADED["coordonates"][ 0] != wndMgr.GetScreenHeight() - 50 + 900: self.loader_['default'][0].SetPosition( wndMgr.GetScreenWidth() / 2 + 158, BIOLOG_BINARY_LOADED["coordonates"][0] + 10) BIOLOG_BINARY_LOADED["coordonates"][ 0] = BIOLOG_BINARY_LOADED["coordonates"][0] + 5 self.next_move = app.GetGlobalTimeStamp() if BIOLOG_BINARY_LOADED["coordonates"][ 0] == wndMgr.GetScreenHeight() - 50 + 900: self.end = 1 self.CloseInfoBoard()
def RefreshEquipSlotWindow(self): for i in xrange(6): slotNumber = self.__InventoryLocalSlotPosToGlobalSlotPos(player.INVENTORY, player.DRAGON_SOUL_EQUIPMENT_SLOT_START + i) itemVnum = player.GetItemIndex(slotNumber) self.wndEquip.SetItemSlot(player.DRAGON_SOUL_EQUIPMENT_SLOT_START + i, itemVnum, 0) self.wndEquip.EnableSlot(player.DRAGON_SOUL_EQUIPMENT_SLOT_START + i) if itemVnum != 0: item.SelectItem(itemVnum) for j in xrange(item.LIMIT_MAX_NUM): (limitType, limitValue) = item.GetLimit(j) # 밑에서 remain_time이 0이하인지 체크 하기 때문에 임의의 양수로 초기화 remain_time = 999 # 일단 현재 타이머는 이 세개 뿐이다. if item.LIMIT_REAL_TIME == limitType: remain_time = player.GetItemMetinSocket(player.INVENTORY, slotNumber, 0) - app.GetGlobalTimeStamp() elif item.LIMIT_REAL_TIME_START_FIRST_USE == limitType: remain_time = player.GetItemMetinSocket(player.INVENTORY, slotNumber, 0) - app.GetGlobalTimeStamp() elif item.LIMIT_TIMER_BASED_ON_WEAR == limitType: remain_time = player.GetItemMetinSocket(player.INVENTORY, slotNumber, 0) if remain_time <= 0: self.wndEquip.DisableSlot(player.DRAGON_SOUL_EQUIPMENT_SLOT_START + i) break self.wndEquip.RefreshSlot()
def UpdateBossMapTimer(self): if settinginfo.bossMapTimer > app.GetGlobalTimeStamp(): timeLeft = settinginfo.bossMapTimer - app.GetGlobalTimeStamp() self.bossMapTimer.SetFontColor(0.9, 0.4745, 0.4627) self.bossMapTimer.SetText( self.AyFormatRebootTime(timeLeft) + " Min. bis Reset!") else: self.bossMapTimer.SetText("Reset bereit!") self.bossMapTimer.SetFontColor(0.5411, 0.7254, 0.5568)
def add_slot(self,slot): isAttached = mouseModule.mouseController.isAttached() if isAttached: attachedSlotType = mouseModule.mouseController.GetAttachedType() attachedSlotPos = mouseModule.mouseController.GetAttachedSlotNumber() mouseModule.mouseController.DeattachObject() if fgGHGjjFHJghjfFG1545gGG.SLOT_TYPE_INVENTORY != attachedSlotType: return itemvnum = fgGHGjjFHJghjfFG1545gGG.GetItemIndex(attachedSlotPos) if slot == 1: if itemvnum == 91163: constInfo.INPUT_CMD = "ITEMEXP#" event.QuestButtonClick(constInfo.PET_INFOS["qid"]) else: chat.AppendChat(chat.CHAT_TYPE_INFO,"Verdammt! Willst du dein Pet etwa umbringen?") return else: if itemvnum == 55102: if constInfo.PET_INFOS["life"] > app.GetGlobalTimeStamp(): chat.AppendChat(chat.CHAT_TYPE_INFO,"Dein Pet hat noch genügend Laufzeit!") else: constInfo.INPUT_CMD = "REVIVE#" event.QuestButtonClick(constInfo.PET_INFOS["qid"]) else: chat.AppendChat(chat.CHAT_TYPE_INFO,"Verdammt! Willst du dein Pet etwa umbringen?") return
def SendChatPacket(self, text, type): if GFHhg54GHGhh45GHGH.IsChatInsultIn(text): chat.AppendChat(chat.CHAT_TYPE_INFO, locale.CHAT_INSULT_STRING) else: # Antispam Skript if not settinginfo.isGM: if app.GetGlobalTimeStamp() >= self.Time["LAST"]: GFHhg54GHGhh45GHGH.SendChatPacket(text, type) self.Time["LAST"] = app.GetGlobalTimeStamp() + 2 else: chat.AppendChat( chat.CHAT_TYPE_INFO, "[Anti-Spam System]Du kannst nur eine Nachricht alle 2 Sekunde senden!" ) else: GFHhg54GHGhh45GHGH.SendChatPacket(text, type)
def __SetCoolTimePetItemSlot(self, slot, Position, slotNumber, itemVnum): item.SelectItem(itemVnum) itemSubType = item.GetItemSubType() if itemSubType not in [item.PET_UPBRINGING, item.PET_BAG]: return if itemSubType == item.PET_BAG: id = player.GetItemMetinSocket(Position, 2) if id == 0: return (limitType, limitValue) = item.GetLimit(0) if itemSubType == item.PET_UPBRINGING: limitValue = player.GetItemMetinSocket(Position, 1) if limitType in [ item.LIMIT_REAL_TIME, item.LIMIT_REAL_TIME_START_FIRST_USE ]: sock_time = player.GetItemMetinSocket(Position, 0) remain_time = max(0, sock_time - app.GetGlobalTimeStamp()) slot.SetSlotCoolTimeInverse(slotNumber, limitValue, limitValue - remain_time)
def __SetCoolTimePetItemSlot(self, slotNumber, itemVnum): if 0 == itemVnum: return item.SelectItem(itemVnum) itemSubType = item.GetItemSubType() if itemSubType not in [item.PET_UPBRINGING, item.PET_BAG]: return if itemSubType == item.PET_BAG: id = safebox.GetItemMetinSocket(slotNumber, 2) if id == 0: return (limitType, limitValue) = item.GetLimit(0) if itemSubType == item.PET_UPBRINGING: limitValue = safebox.GetItemMetinSocket(slotNumber, 1) if limitType in [ item.LIMIT_REAL_TIME, item.LIMIT_REAL_TIME_START_FIRST_USE ]: sock_time = safebox.GetItemMetinSocket(slotNumber, 0) remain_time = max(0, sock_time - app.GetGlobalTimeStamp()) if slotNumber >= safebox.SAFEBOX_PAGE_SIZE: slotNumber -= (self.curPageIndex * safebox.SAFEBOX_PAGE_SIZE) self.wndItem.SetSlotCoolTimeInverse(slotNumber, limitValue, limitValue - remain_time)
def StartResearch(self): if self.qid == 0: chat.AppendChat(chat.CHAT_TYPE_DEBUG, "Error: No QID!") return if self.questSelect < 0: chat.AppendChat(chat.CHAT_TYPE_DEBUG, "Error: questSelect < 0") return if self.slotData[0]["itemVnum"] == 0: chat.AppendChat(chat.CHAT_TYPE_DEBUG, "Error: No item") return if self.biologistQuestDict[self.questSelect]["time"] >= app.GetGlobalTimeStamp(): chat.AppendChat(chat.CHAT_TYPE_DEBUG, "Error: Timer Active!") return accelerateItem = "no" chanceItem = "no" if self.slotData[1]["itemVnum"] > 0: accelerateItem = self.slotData[1]["itemPos"] # chat.AppendChat(chat.CHAT_TYPE_DEBUG, str(self.slotData[2]["itemVnum"])) # chat.AppendChat(chat.CHAT_TYPE_DEBUG, str(self.slotData[2]["itemPos"])) if self.slotData[2]["itemVnum"] > 0: # chat.AppendChat(chat.CHAT_TYPE_DEBUG, "slot data 2 vnum ist >0") chanceItem = self.slotData[2]["itemPos"] # chat.AppendChat(chat.CHAT_TYPE_DEBUG, "chanceItem: " + str(chanceItem)) # chat.AppendChat(chat.CHAT_TYPE_DEBUG, "research#" + str(self.slotData[0]["itemPos"]) + "#" + str(accelerateItem) + "#" + str(chanceItem) + "#") constInfo.INPUT_CMD = "research#" + str(self.slotData[0]["itemPos"]) + "#" + str(accelerateItem) + "#" + str(chanceItem) + "#" event.QuestButtonClick(self.qid) self.ClearSlotData()
def __UpdateImprisonmentDurationText(self): restTime = max(self.imprisonmentEndTime - app.GetGlobalTimeStamp(), 0) imprisonmentEndTimeText = localeInfo.SecondToDHM(restTime) if imprisonmentEndTimeText != self.imprisonmentEndTimeText: self.imprisonmentEndTimeText = imprisonmentEndTimeText self.serverInfo.SetText("%s: %s" % (uiScriptLocale.AUTOBAN_QUIZ_REST_TIME, self.imprisonmentEndTimeText))
def OnUpdate(self): if self.questSelect >= 0: # chat.AppendChat(chat.CHAT_TYPE_DEBUG, str(self.biologistQuestDict[self.questSelect]["time"]) + " >= " + str(app.GetGlobalTimeStamp())) if self.biologistQuestDict[self.questSelect]["time"] >= app.GetGlobalTimeStamp(): self.ResearchItemSlotBlockImage.Show() self.AcceleratorItemSlotBlockImage.Show() self.ChanceItemSlotBlockImage.Show() self.StartResearchButton.Disable() # self.ResearchInfoTextLine.SetText("Bereit!") sek = self.biologistQuestDict[self.questSelect]["time"] - app.GetGlobalTimeStamp() self.ResearchInfoTextLine.SetText("Wartezeit: " + exterminatus.SecondToDHMS(sek)) else: self.ResearchInfoTextLine.SetText("Bereit!") if mouseModule.mouseController.isAttached(): attachedSlotPos = mouseModule.mouseController.GetAttachedSlotNumber() if fgGHGjjFHJghjfFG1545gGG.SLOT_TYPE_INVENTORY == mouseModule.mouseController.GetAttachedType(): # is ResearchItem if self.biologistQuestDict[self.questSelect]["itemVnum"] == mouseModule.mouseController.GetAttachedItemIndex(): self.ResearchItemSlotBlockImage.Hide() self.AcceleratorItemSlotBlockImage.Show() self.ChanceItemSlotBlockImage.Show() elif IsBiologistAccelerator(mouseModule.mouseController.GetAttachedItemIndex()): self.ResearchItemSlotBlockImage.Show() self.AcceleratorItemSlotBlockImage.Hide() self.ChanceItemSlotBlockImage.Show() elif IsBiologistChanceItem(mouseModule.mouseController.GetAttachedItemIndex()): self.ResearchItemSlotBlockImage.Show() self.AcceleratorItemSlotBlockImage.Show() self.ChanceItemSlotBlockImage.Hide() else: self.ResearchItemSlotBlockImage.Show() self.AcceleratorItemSlotBlockImage.Show() self.ChanceItemSlotBlockImage.Show() else: self.ResearchItemSlotBlockImage.Hide() self.AcceleratorItemSlotBlockImage.Hide() self.ChanceItemSlotBlockImage.Hide()
def SetTime(self, time): time_collect = time - app.GetGlobalTimeStamp() if time_collect < 0: time_collect = 0 if time_collect == 1: self.wndLeftTime = uiprofessionalbiolog.Biolog_TimeExpired() self.wndLeftTime.OpenWindow() self.wndLeftTime.Show() self.time_value.SetText(localeInfo.FormatTime(time_collect))
def OnUpdate(self): if self.bar.IsIn(): self.OnMouseOverIn() else: self.OnMouseOverOut() if self.status == self.STATUS_INACTIVE: self.questTimer.SetText("Noch nicht freigeschaltet!") self.questPercent.SetText("0%") elif self.status == self.STATUS_ACTIVE: if self.timer > app.GetGlobalTimeStamp(): # self.questTimer.SetText(localeInfo.SecondToDHMS(self.timer - app.GetTime())) # chat.AppendChat(chat.CHAT_TYPE_DEBUG,"TIMER ACTIVE!") sek = self.timer - app.GetGlobalTimeStamp() self.questTimer.SetText(exterminatus.SecondToDHMS(sek)) else: self.questTimer.SetText("Bereit!") elif self.status == self.STATUS_COMPLETE: self.questTimer.SetText("Abgeschlossen!") self.questPercent.SetText("100%")
def CloseDialog(self): wndMgr.OnceIgnoreMouseLeftButtonUpEvent() if 0 != self.tooltipItem: self.tooltipItem.HideToolTip() if self.closenotimer == 1: self.time_end = app.GetGlobalTimeStamp() self.close = TRUE else: self.close = FALSE self.Close()
def ShowLevelInfoToolTip(self): self.tooltip.ClearToolTip() MaxMobEXP = (constInfo.PET_INFOS["level"] + 1) * 1000 MaxItemEXP = constInfo.PET_INFOS["level"] + 1 self.tooltip.AppendTextLine("Monster-EXP: " + constInfo.NumberToPointString(constInfo.PET_INFOS["mob_exp"]) + "/" + constInfo.NumberToPointString(MaxMobEXP)) self.tooltip.AppendTextLine("Item-EXP: " + constInfo.NumberToPointString(constInfo.PET_INFOS["item_exp"]) + "/" + constInfo.NumberToPointString(MaxItemEXP)) if constInfo.PET_INFOS["double_exp"] > app.GetGlobalTimeStamp(): self.tooltip.AppendHorizontalLine() self.tooltip.AppendTextLine("[ Pet-EXP Ring aktiv ]") self.tooltip.AppendMallItemLastTime(constInfo.PET_INFOS["double_exp"]) self.tooltip.ShowToolTip()
def UpdateDescription(self): if not self.isClocked: self.__UpdateDescription2() return if not self.description: return toolTip = self.description if self.endTime > 0: leftTime = locale.SecondToDHM(self.endTime - app.GetGlobalTimeStamp()) toolTip += " (%s : %s)" % (locale.LEFT_TIME, leftTime) self.SetToolTipText(toolTip, 0, 40)
def UpdateDailyTimer(self): if self.status == 2: if settinginfo.DailyQuest_Time > app.GetGlobalTimeStamp(): leftSec = max( 0, settinginfo.DailyQuest_Time - app.GetGlobalTimeStamp()) self.MainTimeLine.SetText("[ Neue Quest in " + localeInfo.SecondToDHM(leftSec) + " ]") else: event.QuestButtonClick(settinginfo.DailyQuest_QID) self.SetLayoutType(3) elif self.status == 1: if settinginfo.DailyQuest_Time > app.GetGlobalTimeStamp(): leftSec = max( 0, settinginfo.DailyQuest_Time - app.GetGlobalTimeStamp()) self.MainTimeLine.SetText("[ Verbl. Zeit: " + localeInfo.SecondToDHM(leftSec) + " ]") else: event.QuestButtonClick(settinginfo.DailyQuest_QID) #chat.AppendChat(chat.CHAT_TYPE_INFO,"Die Zeit für die Daily-Quest ist abgelaufen!") self.SetLayoutType(3)
def __LoadWindow(self): self.next_move = app.GetGlobalTimeStamp() self.biologWindow_sliding = 0 self.end = 0 self.createWindow = CreateWindow() try: pyScrLoader = ui.PythonScriptLoader() pyScrLoader.LoadScriptFile(self, "UIScript/biolog_slider.py") except: import exception exception.Abort("Biolog.LoadWindow.LoadObject") try: self.loader_ = { 'default': { 0: self.GetChild("Board"), 1: self.GetChild("Background"), 2: self.GetChild("iRewardItemText"), }, 'loaded': { 0: self.GetChild("iRewardItem"), 1: self.GetChild("iRewardType") } } x = [self.loader_['loaded'][0], self.loader_['default'][2]] for i in x: i.Hide() except: import exception exception.Abort("Biolog.LoadWindow.BindObject") self.iBonusName = {} self.iSlotBonus = {} self.iValueBonus = {} btn = 0 pos_y = 1 + 10 while btn < 2: self.iBonusName[btn] = self.createWindow._AppendTextLine( self.loader_['default'][1], '', 10, pos_y, self.createWindow.RGB(185, 218, 143)) self.iSlotBonus[btn] = self.createWindow._AppendSlot( self.loader_['default'][1], '', 305, pos_y, 66, 16) self.iValueBonus[btn] = self.createWindow._AppendTextLine( self.loader_['default'][1], '', 307, pos_y, self.createWindow.RGB(255, 255, 255)) btn = btn + 1 pos_y = pos_y + 20
def OnSetReels(self, win, jackpot, r1, r2, r3): # Check if machine is rolling. if not self.isRolling: # Set slot machine information. self.hasWon = win self.hasJackpot = jackpot self.reelResult[SLOT_MACHINE_REEL1] = r1 # slot reel 1 self.reelResult[SLOT_MACHINE_REEL2] = r2 # slot reel 2 self.reelResult[SLOT_MACHINE_REEL3] = r3 # slot reel 3 # Check all slot reels. for slotPos in xrange(self.reelIconSlot.GetSlotCount()): # Set reel slot roll time and set unrolled. self.rollTime[slotPos] = app.GetGlobalTimeStamp() + int(2 * (slotPos + 1)) self.isRolled[slotPos] = False # Stop slot machine rolling. self.isRolling = True
def UpdateForestZoneTimer(self): if settinginfo.forest_zone_time > 0: self.bossMapTitle.Show() timeLeft = settinginfo.forest_zone_time - app.GetGlobalTimeStamp() self.bossMapTitle.SetText("Verbl. Zeit im Wald: " + self.AyFormatRebootTime(timeLeft))
class PetBoard(ui.ScriptWindow): PetName = "TestName" PetItemVnum = 55003 PetLifetime = app.GetGlobalTimeStamp() + (60*60*24*3) PetLevel = 135 PetAffects = [1,3000,2,500,3,12] PetSkillLevel = 20 PetSkillStatus = 0 PetMobEXP = 30000 PetItemEXP = 90 isLoaded = 0 PetContentBoardTitleBars = {} PetEXPBubble = {} PetBoni = {} expGauge = {} ItemExpGauge = {} def __init__(self): ui.ScriptWindow.__init__(self) self.LoadUI() def __del__(self): #constInfo.CALOPEN = 1 #chat.AppendChat(chat.CHAT_TYPE_INFO,"closegui") constInfo.PET_INFOS["gui"] = 0 ui.ScriptWindow.__del__(self) self.Board.Hide() def LoadUI(self): if constInfo.PET_INFOS["gui"] == 1: constInfo.PET_INFOS["gui"] = 0 self.__del__() return self.Board = ui.BoardWithTitleBar() self.Board.SetSize(400, 415) self.Board.SetCenterPosition() self.Board.AddFlag("movable") self.Board.AddFlag("float") self.Board.SetTitleName("Pet") self.Board.SetCloseEvent(self.__del__) self.Board.Show() self.tooltip = uiToolTip.ToolTip() self.tooltip.HideToolTip() self.HeadBoard = ui.ThinBoard() self.HeadBoard.SetParent(self.Board) self.HeadBoard.SetPosition(15,35) self.HeadBoard.SetSize(370,80) self.HeadBoard.Show() self.PetItemSlotIMG = ui.ImageBox() self.PetItemSlotIMG.SetParent(self.HeadBoard) self.PetItemSlotIMG.SetPosition(15,17) self.PetItemSlotIMG.LoadImage("exterminatus/new_pet_images/pet_incu_slot_001.tga") self.PetItemSlotIMG.Show() self.PetItemVnumIMG = ui.ImageBox() self.PetItemVnumIMG.SetParent(self.PetItemSlotIMG) self.PetItemVnumIMG.SetPosition(4,4) self.PetItemVnumIMG.LoadImage("icon/item/55001.tga") self.PetItemVnumIMG.Show() self.PetNameSlotBar = ui.SlotBar() self.PetNameSlotBar.SetParent(self.HeadBoard) self.PetNameSlotBar.SetPosition(70,25) self.PetNameSlotBar.SetSize(225,19) self.PetNameSlotBar.Show() self.PetNameTextLine = ui.TextLine() self.PetNameTextLine.SetParent(self.PetNameSlotBar) self.PetNameTextLine.SetPosition(8,2) self.PetNameTextLine.SetText(str(constInfo.PET_INFOS["name"])) self.PetNameTextLine.Show() self.StatBoard = ui.ThinBoard() self.StatBoard.SetParent(self.Board) self.StatBoard.SetPosition(15,120) self.StatBoard.SetSize(370,120) self.StatBoard.Show() i = 0 y = 15 y_add = 120 headlines = [["Level",36],["Erfahrung",28],["Laufzeit",32]] while i < 3: self.PetContentBoardTitleBars[i] = ui.HorizontalBar() self.PetContentBoardTitleBars[i].SetParent(self.StatBoard) self.PetContentBoardTitleBars[i].SetPosition(y,10) self.PetContentBoardTitleBars[i].Create(100) self.PetContentBoardTitleBars[i].Show() self.PetContentBoardTitleBars[i+10] = ui.TextLine() self.PetContentBoardTitleBars[i+10].SetParent(self.PetContentBoardTitleBars[i]) self.PetContentBoardTitleBars[i+10].SetPosition(headlines[i][1],2) self.PetContentBoardTitleBars[i+10].SetText(str(headlines[i][0])) self.PetContentBoardTitleBars[i+10].Show() if i > 0: self.PetContentBoardTitleBars[i+100] = ui.ImageBox() self.PetContentBoardTitleBars[i+100].SetParent(self.StatBoard) self.PetContentBoardTitleBars[i+100].SetPosition(y-11,5) self.PetContentBoardTitleBars[i+100].LoadImage("exterminatus/new_pet_images/pet_trenn_line.tga") self.PetContentBoardTitleBars[i+100].Show() i = i + 1 y = y + y_add self.PetLevelSlotBar = ui.SlotBar() self.PetLevelSlotBar.SetParent(self.StatBoard) self.PetLevelSlotBar.SetPosition(15,35) self.PetLevelSlotBar.SetSize(98,19) self.PetLevelSlotBar.Show() self.PetLevelTextLine = ui.TextLine() self.PetLevelTextLine.SetParent(self.PetLevelSlotBar) self.PetLevelTextLine.SetPosition(39,2) self.PetLevelTextLine.SetText(" 7") self.PetLevelTextLine.Show() i = 0 y = 142 y_add = 17 while i < 5: self.PetEXPBubble[i] = ui.ImageBox() self.PetEXPBubble[i].SetParent(self.StatBoard) self.PetEXPBubble[i].SetPosition(y,35) self.PetEXPBubble[i].LoadImage("exterminatus/new_pet_images/exp_bubble_empty.tga") self.PetEXPBubble[i].Show() if i < 4: self.expGauge[i] = ui.ExpandedImageBox() self.expGauge[i].SetParent(self.StatBoard) self.expGauge[i].SetPosition(y,35) self.expGauge[i].LoadImage("exterminatus/new_pet_images/exp_bubble_full.tga") self.expGauge[i].Show() else: self.ItemExpGauge[0] = ui.ExpandedImageBox() self.ItemExpGauge[0].SetParent(self.StatBoard) self.ItemExpGauge[0].SetPosition(y,35) self.ItemExpGauge[0].LoadImage("exterminatus/new_pet_images/exp_bubble_item.tga") self.ItemExpGauge[0].Show() i = i + 1 y = y + y_add self.PetEXPBlock = ui.ImageBox() self.PetEXPBlock.SetParent(self.StatBoard) self.PetEXPBlock.SetPosition(142,35) self.PetEXPBlock.LoadImage("exterminatus/new_pet_images/pet_exp_block.tga") self.PetEXPBlock.Show() self.SetExperience(0,2000) self.SetItemExperience(0,2) # self.PetItemEXPSlotIMG = ui.ImageBox() # self.PetItemEXPSlotIMG.SetParent(self.StatBoard) # self.PetItemEXPSlotIMG.SetPosition(167,65) # self.PetItemEXPSlotIMG.LoadImage("d:/ymir work/ui/public/slot_base.sub") # self.PetItemEXPSlotIMG.Show() # self.PetItemEXPSlotItemIMG = ui.ImageBox() # self.PetItemEXPSlotItemIMG.SetParent(self.PetItemEXPSlotIMG) # self.PetItemEXPSlotItemIMG.SetPosition(0,0) # self.PetItemEXPSlotItemIMG.LoadImage("icon/item/55100.tga") # self.PetItemEXPSlotItemIMG.Show() # self.PetItemEXPSlotItemIMGCover = ui.ImageBox() # self.PetItemEXPSlotItemIMGCover.SetParent(self.PetItemEXPSlotIMG) # self.PetItemEXPSlotItemIMGCover.SetPosition(2,2) # self.PetItemEXPSlotItemIMGCover.LoadImage("exterminatus/new_pet_images/slot_block.tga") # self.PetItemEXPSlotItemIMGCover.Show() # self.PetItemEXPSlotItemIMGCover1 = ui.ImageBox() # self.PetItemEXPSlotItemIMGCover1.SetParent(self.PetItemEXPSlotIMG) # self.PetItemEXPSlotItemIMGCover1.SetPosition(2,2) # self.PetItemEXPSlotItemIMGCover1.LoadImage("exterminatus/new_pet_images/slot_block.tga") # self.PetItemEXPSlotItemIMGCover1.Show() # self.PetItemEXPSlotItemSlot = ui.GridSlotWindow() # self.PetItemEXPSlotItemSlot.SetParent(self.PetItemEXPSlotIMG) # self.PetItemEXPSlotItemSlot.ArrangeSlot(1,1,1,32,32,0,0) # self.PetItemEXPSlotItemSlot.SetPosition(0, 0) # #self.PetItemEXPSlotItemSlot.SetOverInItemEvent(ui.__mem_func__(self.ShowToolTip)) # #self.PetItemEXPSlotItemSlot.SetOverOutItemEvent(ui.__mem_func__(self.HideToolTip)) # self.PetItemEXPSlotItemSlot.SetSelectEmptySlotEvent(ui.__mem_func__(self.add_slot)) # #self.PetItemEXPSlotItemSlot.SetSelectItemSlotEvent(ui.__mem_func__(self.del_slot)) # self.PetItemEXPSlotItemSlot.Show() self.PetLifeTimeSlotBar = ui.SlotBar() self.PetLifeTimeSlotBar.SetParent(self.StatBoard) self.PetLifeTimeSlotBar.SetPosition(255,35) self.PetLifeTimeSlotBar.SetSize(98,19) self.PetLifeTimeSlotBar.Show() self.PetLifeTimeTextLine = ui.TextLine() self.PetLifeTimeTextLine.SetParent(self.PetLifeTimeSlotBar) self.PetLifeTimeTextLine.SetPosition(18,2) self.PetLifeTimeTextLine.SetText("0") self.PetLifeTimeTextLine.Show() # self.PetLifeTimeSlotIMG = ui.ImageBox() # self.PetLifeTimeSlotIMG.SetParent(self.StatBoard) # self.PetLifeTimeSlotIMG.SetPosition(287,65) # self.PetLifeTimeSlotIMG.LoadImage("d:/ymir work/ui/public/slot_base.sub") # self.PetLifeTimeSlotIMG.Show() # self.PetLifeTimeSlotItemIMG = ui.ImageBox() # self.PetLifeTimeSlotItemIMG.SetParent(self.PetLifeTimeSlotIMG) # self.PetLifeTimeSlotItemIMG.SetPosition(0,0) # self.PetLifeTimeSlotItemIMG.LoadImage("icon/item/55102.tga") # self.PetLifeTimeSlotItemIMG.Show() # self.PetLifeTimeSlotItemIMGCover = ui.ImageBox() # self.PetLifeTimeSlotItemIMGCover.SetParent(self.PetLifeTimeSlotIMG) # self.PetLifeTimeSlotItemIMGCover.SetPosition(2,2) # self.PetLifeTimeSlotItemIMGCover.LoadImage("exterminatus/new_pet_images/slot_block.tga") # self.PetLifeTimeSlotItemIMGCover.Show() # self.PetLifeTimeSlotItemIMGCover1 = ui.ImageBox() # self.PetLifeTimeSlotItemIMGCover1.SetParent(self.PetLifeTimeSlotIMG) # self.PetLifeTimeSlotItemIMGCover1.SetPosition(2,2) # self.PetLifeTimeSlotItemIMGCover1.LoadImage("exterminatus/new_pet_images/slot_block.tga") # self.PetLifeTimeSlotItemIMGCover1.Show() # self.LifeTimeSlotItemSlot = ui.GridSlotWindow() # self.LifeTimeSlotItemSlot.SetParent(self.PetLifeTimeSlotIMG) # self.LifeTimeSlotItemSlot.ArrangeSlot(2,1,1,32,32,0,0) # self.LifeTimeSlotItemSlot.SetPosition(0, 0) # self.LifeTimeSlotItemSlot.SetSelectEmptySlotEvent(ui.__mem_func__(self.add_slot)) # self.LifeTimeSlotItemSlot.Show() self.BoniBoard = ui.ThinBoard() self.BoniBoard.SetParent(self.Board) self.BoniBoard.SetPosition(15,245) self.BoniBoard.SetSize(370,100) self.BoniBoard.Show() self.SkillBoard = ui.ThinBoard() self.SkillBoard.SetParent(self.Board) self.SkillBoard.SetPosition(15,350) self.SkillBoard.SetSize(370,50) self.SkillBoard.Show() i = 0 x = 15 list = 0 boni = ["Verteidigung +75","Stark gegen Monster +20%","Chance auf krit. Treffer +10%"] while i < 3: self.PetBoni[i] = ui.TextLine() self.PetBoni[i].SetParent(self.BoniBoard) self.PetBoni[i].SetPosition(15,x) self.PetBoni[i].SetText("Bonus " + str(i+1) + ":") self.PetBoni[i].Show() self.PetBoni[i+3] = ui.TextLine() self.PetBoni[i+3].SetParent(self.BoniBoard) self.PetBoni[i+3].SetPosition(65,x) self.PetBoni[i+3].SetText(str(self.__CreateAffectString(self.PetAffects[list],self.PetAffects[list+1]*2))) self.PetBoni[i+3].SetFontColor(0.5411, 0.7254, 0.5568) self.PetBoni[i+3].Show() list = list + 2 i = i + 1 x = x + 26 self.PetSkillSlotBGImg = ui.ImageBox() self.PetSkillSlotBGImg.SetParent(self.SkillBoard) self.PetSkillSlotBGImg.SetPosition(8,8) self.PetSkillSlotBGImg.LoadImage("d:/ymir work/ui/public/slot_base.sub") self.PetSkillSlotBGImg.Show() self.PetSkillSlotBGImg1 = ui.GridSlotWindow() self.PetSkillSlotBGImg1.SetParent(self.PetSkillSlotBGImg) self.PetSkillSlotBGImg1.ArrangeSlot(3,1,1,32,32,0,0) self.PetSkillSlotBGImg1.SetPosition(0, 0) #self.PetSkillSlotBGImg1.SetOverInItemEvent(ui.__mem_func__(self.ShowToolTip)) #self.PetSkillSlotBGImg1.SetOverOutItemEvent(ui.__mem_func__(self.HideToolTip)) #self.PetSkillSlotBGImg1.SetSelectEmptySlotEvent(ui.__mem_func__(self.add_slot)) self.PetSkillSlotBGImg1.SetSelectItemSlotEvent(ui.__mem_func__(self.ActivateSkill)) self.PetSkillSlotBGImg1.Show() self.PetSkillSlotBGImg1.SetItemSlot(3, 70002, constInfo.PET_INFOS["skill_level"]) self.PetSkillNameTitle = ui.TextLine() self.PetSkillNameTitle.SetParent(self.SkillBoard) self.PetSkillNameTitle.SetPosition(45,8) self.PetSkillNameTitle.SetText("Automatisches aufheben") self.PetSkillNameTitle.Show() self.PetSkillNameError = ui.TextLine() self.PetSkillNameError.SetParent(self.SkillBoard) self.PetSkillNameError.SetPosition(45,23) self.PetSkillNameError.SetText("Die Fertigkeit kann erst erlernt werden wenn dein Pet lv.10 ist.") self.PetSkillNameError.SetFontColor(0.9, 0.4745, 0.4627) self.PetSkillNameError.Show() constInfo.PET_INFOS["gui"] = 1 def ActivateSkill(self,slot): if constInfo.PET_INFOS["skill_level"] < 20: chat.AppendChat(chat.CHAT_TYPE_INFO,"Die Fertigkeit muss auf Stufe 20 sein!") return if constInfo.PET_INFOS["skill_status"] == 0: constInfo.PET_INFOS["skill_status"] = 1 else: constInfo.PET_INFOS["skill_status"] = 0 def add_slot(self,slot): isAttached = mouseModule.mouseController.isAttached() if isAttached: attachedSlotType = mouseModule.mouseController.GetAttachedType() attachedSlotPos = mouseModule.mouseController.GetAttachedSlotNumber() mouseModule.mouseController.DeattachObject() if fgGHGjjFHJghjfFG1545gGG.SLOT_TYPE_INVENTORY != attachedSlotType: return itemvnum = fgGHGjjFHJghjfFG1545gGG.GetItemIndex(attachedSlotPos) if slot == 1: if itemvnum == 91163: constInfo.INPUT_CMD = "ITEMEXP#" event.QuestButtonClick(constInfo.PET_INFOS["qid"]) else: chat.AppendChat(chat.CHAT_TYPE_INFO,"Verdammt! Willst du dein Pet etwa umbringen?") return else: if itemvnum == 55102: if constInfo.PET_INFOS["life"] > app.GetGlobalTimeStamp(): chat.AppendChat(chat.CHAT_TYPE_INFO,"Dein Pet hat noch genügend Laufzeit!") else: constInfo.INPUT_CMD = "REVIVE#" event.QuestButtonClick(constInfo.PET_INFOS["qid"]) else: chat.AppendChat(chat.CHAT_TYPE_INFO,"Verdammt! Willst du dein Pet etwa umbringen?") return def SetExperience(self, curPoint, maxPoint): curPoint = min(curPoint, maxPoint) curPoint = max(curPoint, 0) maxPoint = max(maxPoint, 0) quarterPoint = maxPoint / 4 FullCount = 0 if 0 != quarterPoint: FullCount = min(4, curPoint / quarterPoint) for i in xrange(4): self.expGauge[i].Hide() for i in xrange(FullCount): self.expGauge[i].SetRenderingRect(0.0, 0.0, 0.0, 0.0) self.expGauge[i].Show() if 0 != quarterPoint: if FullCount < 4: Percentage = float(curPoint % quarterPoint) / quarterPoint - 1.0 self.expGauge[FullCount].SetRenderingRect(0.0, Percentage, 0.0, 0.0) self.expGauge[FullCount].Show() def SetItemExperience(self, curPoint, maxPoint): curPoint = min(curPoint, maxPoint) curPoint = max(curPoint, 0) maxPoint = max(maxPoint, 0) quarterPoint = maxPoint / 1 FullCount = 0 if 0 != quarterPoint: FullCount = min(1, curPoint / quarterPoint) for i in xrange(1): self.ItemExpGauge[i].Hide() for i in xrange(FullCount): self.ItemExpGauge[i].SetRenderingRect(0.0, 0.0, 0.0, 0.0) self.ItemExpGauge[i].Show() if 0 != quarterPoint: if FullCount < 1: Percentage = float(curPoint % quarterPoint) / quarterPoint - 1.0 self.ItemExpGauge[FullCount].SetRenderingRect(0.0, Percentage, 0.0, 0.0) self.ItemExpGauge[FullCount].Show() def ShowLevelInfoToolTip(self): self.tooltip.ClearToolTip() MaxMobEXP = (constInfo.PET_INFOS["level"] + 1) * 1000 MaxItemEXP = constInfo.PET_INFOS["level"] + 1 self.tooltip.AppendTextLine("Monster-EXP: " + constInfo.NumberToPointString(constInfo.PET_INFOS["mob_exp"]) + "/" + constInfo.NumberToPointString(MaxMobEXP)) self.tooltip.AppendTextLine("Item-EXP: " + constInfo.NumberToPointString(constInfo.PET_INFOS["item_exp"]) + "/" + constInfo.NumberToPointString(MaxItemEXP)) if constInfo.PET_INFOS["double_exp"] > app.GetGlobalTimeStamp(): self.tooltip.AppendHorizontalLine() self.tooltip.AppendTextLine("[ Pet-EXP Ring aktiv ]") self.tooltip.AppendMallItemLastTime(constInfo.PET_INFOS["double_exp"]) self.tooltip.ShowToolTip() def HideLevelInfoToolTip(self): self.tooltip.HideToolTip() def OnUpdate(self): if self.IsShow(): if self.PetEXPBlock.IsIn(): # self.Board.SetTitleName("Pet - IN") self.ShowLevelInfoToolTip() else: # self.Board.SetTitleName("Pet - OUT") self.HideLevelInfoToolTip() if constInfo.PET_INFOS["level"] == 0 or constInfo.PET_INFOS["guiclose"] == 1: constInfo.PET_INFOS["skill_status"] = 0 constInfo.PET_INFOS["gui"] = 0 constInfo.PET_INFOS["guiclose"] = 0 self.HideLevelInfoToolTip() self.__del__() return itemVnum = 55001 for i in xrange(fgGHGjjFHJghjfFG1545gGG.INVENTORY_PAGE_SIZE*4): if constInfo.IS_PET_SEAL(fgGHGjjFHJghjfFG1545gGG.GetItemIndex(i)): metinSocket = [fgGHGjjFHJghjfFG1545gGG.GetItemMetinSocket(i, j) for j in xrange(fgGHGjjFHJghjfFG1545gGG.METIN_SOCKET_MAX_NUM)] if metinSocket[0] == 1: itemVnum = fgGHGjjFHJghjfFG1545gGG.GetItemIndex(i) self.PetItemVnumIMG.LoadImage("icon/item/" + str(itemVnum) + ".tga") if constInfo.PET_INFOS["life"] > app.GetGlobalTimeStamp(): leftSec = max(0, constInfo.PET_INFOS["life"] - app.GetGlobalTimeStamp()) self.PetLifeTimeTextLine.SetText(localeInfo.SecondToDHM(leftSec)) self.PetLifeTimeTextLine.SetPosition(18,2) self.PetLifeTimeTextLine.SetFontColor(0.5411, 0.7254, 0.5568) else: self.PetLifeTimeTextLine.SetText("Schläft") self.PetLifeTimeTextLine.SetFontColor(0.9, 0.4745, 0.4627) self.PetLifeTimeTextLine.SetPosition(42,2) if constInfo.PET_INFOS["level"] < 10: self.PetLevelTextLine.SetText(" " + str(constInfo.PET_INFOS["level"])) elif constInfo.PET_INFOS["level"] >= 10 and constInfo.PET_INFOS["level"] < 100: self.PetLevelTextLine.SetText(" " + str(constInfo.PET_INFOS["level"])) elif constInfo.PET_INFOS["level"] >= 100: self.PetLevelTextLine.SetText(str(constInfo.PET_INFOS["level"])) MaxMobEXP = (constInfo.PET_INFOS["level"] + 1) * 1000 MaxItemEXP = constInfo.PET_INFOS["level"] + 1 self.SetExperience(constInfo.PET_INFOS["mob_exp"],MaxMobEXP) self.SetItemExperience(constInfo.PET_INFOS["item_exp"],MaxItemEXP) i = 0 list = 0 while i < 3: self.PetBoni[i+3].SetText(str(self.__CreateAffectString(constInfo.PET_INFOS["attr"][list],constInfo.PET_INFOS["attr"][list+1]))) list = list + 2 i = i + 1 if constInfo.PET_INFOS["skill_status"] == 1: self.PetSkillSlotBGImg1.ActivateSlot(3) self.PetSkillNameError.SetText("(Aktiviert)") else: self.PetSkillSlotBGImg1.DeactivateSlot(3) self.PetSkillNameError.SetText("(Deaktiviert)") if constInfo.PET_INFOS["level"] < 10: self.PetSkillNameError.SetText("Die Fertigkeit kann erst erlernt werden wenn dein Pet lv.10 ist.") self.PetSkillNameError.SetFontColor(0.9, 0.4745, 0.4627) elif constInfo.PET_INFOS["level"] >= 10 and constInfo.PET_INFOS["skill_level"] < 20: self.PetSkillNameError.SetText("Du kannst die Fertigkeit nun mit den Meisterbüchern trainieren.") self.PetSkillNameError.SetFontColor(0.5411, 0.7254, 0.5568) elif constInfo.PET_INFOS["level"] >= 10 and constInfo.PET_INFOS["skill_level"] >= 20: #self.PetSkillNameError.SetText("") self.PetSkillNameError.SetFontColor(0.5411, 0.7254, 0.5568) if constInfo.PET_INFOS["skill_level"] >= 20: self.PetSkillSlotBGImg1.SetItemSlot(3, 70002, 20) else: self.PetSkillSlotBGImg1.SetItemSlot(3, 70002, constInfo.PET_INFOS["skill_level"]) def __CreateAffectString(self, affectType, affectValue): if 0 == affectType: return None if 0 == affectValue: return None try: return AFFECT_DICT[affectType](affectValue) except TypeError: return "UNKNOWN_VALUE[%s] %s" % (affectType, affectValue) except KeyError: return "UNKNOWN_TYPE[%s] %s" % (affectType, affectValue)
def SetImprisonmentDuration(self, duration): self.imprisonmentDuration = duration self.imprisonmentEndTime = app.GetGlobalTimeStamp() + duration self.__UpdateImprisonmentDurationText()
def OnUpdate(self): if self.runTime > app.GetGlobalTimeStamp(): timeLeft = self.runTime - app.GetGlobalTimeStamp() self.runTimeTextLine.SetText(self.FormatTime(timeLeft)) else: self.runTimeTextLine.SetText("Abgelaufen!")
def OnUpdate(self): if self.IsShow(): if self.PetEXPBlock.IsIn(): # self.Board.SetTitleName("Pet - IN") self.ShowLevelInfoToolTip() else: # self.Board.SetTitleName("Pet - OUT") self.HideLevelInfoToolTip() if constInfo.PET_INFOS["level"] == 0 or constInfo.PET_INFOS["guiclose"] == 1: constInfo.PET_INFOS["skill_status"] = 0 constInfo.PET_INFOS["gui"] = 0 constInfo.PET_INFOS["guiclose"] = 0 self.HideLevelInfoToolTip() self.__del__() return itemVnum = 55001 for i in xrange(fgGHGjjFHJghjfFG1545gGG.INVENTORY_PAGE_SIZE*4): if constInfo.IS_PET_SEAL(fgGHGjjFHJghjfFG1545gGG.GetItemIndex(i)): metinSocket = [fgGHGjjFHJghjfFG1545gGG.GetItemMetinSocket(i, j) for j in xrange(fgGHGjjFHJghjfFG1545gGG.METIN_SOCKET_MAX_NUM)] if metinSocket[0] == 1: itemVnum = fgGHGjjFHJghjfFG1545gGG.GetItemIndex(i) self.PetItemVnumIMG.LoadImage("icon/item/" + str(itemVnum) + ".tga") if constInfo.PET_INFOS["life"] > app.GetGlobalTimeStamp(): leftSec = max(0, constInfo.PET_INFOS["life"] - app.GetGlobalTimeStamp()) self.PetLifeTimeTextLine.SetText(localeInfo.SecondToDHM(leftSec)) self.PetLifeTimeTextLine.SetPosition(18,2) self.PetLifeTimeTextLine.SetFontColor(0.5411, 0.7254, 0.5568) else: self.PetLifeTimeTextLine.SetText("Schläft") self.PetLifeTimeTextLine.SetFontColor(0.9, 0.4745, 0.4627) self.PetLifeTimeTextLine.SetPosition(42,2) if constInfo.PET_INFOS["level"] < 10: self.PetLevelTextLine.SetText(" " + str(constInfo.PET_INFOS["level"])) elif constInfo.PET_INFOS["level"] >= 10 and constInfo.PET_INFOS["level"] < 100: self.PetLevelTextLine.SetText(" " + str(constInfo.PET_INFOS["level"])) elif constInfo.PET_INFOS["level"] >= 100: self.PetLevelTextLine.SetText(str(constInfo.PET_INFOS["level"])) MaxMobEXP = (constInfo.PET_INFOS["level"] + 1) * 1000 MaxItemEXP = constInfo.PET_INFOS["level"] + 1 self.SetExperience(constInfo.PET_INFOS["mob_exp"],MaxMobEXP) self.SetItemExperience(constInfo.PET_INFOS["item_exp"],MaxItemEXP) i = 0 list = 0 while i < 3: self.PetBoni[i+3].SetText(str(self.__CreateAffectString(constInfo.PET_INFOS["attr"][list],constInfo.PET_INFOS["attr"][list+1]))) list = list + 2 i = i + 1 if constInfo.PET_INFOS["skill_status"] == 1: self.PetSkillSlotBGImg1.ActivateSlot(3) self.PetSkillNameError.SetText("(Aktiviert)") else: self.PetSkillSlotBGImg1.DeactivateSlot(3) self.PetSkillNameError.SetText("(Deaktiviert)") if constInfo.PET_INFOS["level"] < 10: self.PetSkillNameError.SetText("Die Fertigkeit kann erst erlernt werden wenn dein Pet lv.10 ist.") self.PetSkillNameError.SetFontColor(0.9, 0.4745, 0.4627) elif constInfo.PET_INFOS["level"] >= 10 and constInfo.PET_INFOS["skill_level"] < 20: self.PetSkillNameError.SetText("Du kannst die Fertigkeit nun mit den Meisterbüchern trainieren.") self.PetSkillNameError.SetFontColor(0.5411, 0.7254, 0.5568) elif constInfo.PET_INFOS["level"] >= 10 and constInfo.PET_INFOS["skill_level"] >= 20: #self.PetSkillNameError.SetText("") self.PetSkillNameError.SetFontColor(0.5411, 0.7254, 0.5568) if constInfo.PET_INFOS["skill_level"] >= 20: self.PetSkillSlotBGImg1.SetItemSlot(3, 70002, 20) else: self.PetSkillSlotBGImg1.SetItemSlot(3, 70002, constInfo.PET_INFOS["skill_level"])
def OnUpdate(self): seconds = app.GetGlobalTimeStamp() - self.time_end if self.close and seconds > 4: self.close = FALSE self.Close()
def RefreshStatus(self): pointEnergy = player.GetStatus (player.ENERGY) leftTimeEnergy = player.GetStatus (player.ENERGY_END_TIME) - app.GetGlobalTimeStamp() # 충기환 지속 시간 = 2시간. self.SetEnergy (pointEnergy, leftTimeEnergy, 7200)
def OnUpdate(self): if settinginfo.DailyQuest_Status == 0: if app.GetGlobalTimeStamp() < settinginfo.DailyQuest_Time: self.MainTimeLine.SetText("[ Zeit bis zur nächsten Quest: " + str(self.FormatTime()) + " Std. ]") self.MainTimeLine.SetFontColor(0.9, 0.4745, 0.4627) self.disStartButton.Show() self.startButton.Hide() else: self.MainTimeLine.SetText( "[ Du kannst eine neue Quest beginnen! ]") self.MainTimeLine.SetFontColor(0.5411, 0.7254, 0.5568) self.disStartButton.Hide() self.startButton.Show() i = 0 slot_count = 6 while i < slot_count: self.targetSlots[i].ClearSlot(i) #self.targetSlots[i].SetItemSlot(i, settinginfo.DailyQuest_Monster[i], settinginfo.DailyQuest_Count[i]) self.targetSlots[i].RefreshSlot() rewardSlotCount = i + 7 self.rewardSlots[i].ClearSlot(rewardSlotCount) #self.rewardSlots[i].SetItemSlot(rewardSlotCount, settinginfo.DailyQuest_Reward[i], settinginfo.DailyQuest_RewardCount[i]) self.rewardSlots[i].RefreshSlot() i = i + 1 elif settinginfo.DailyQuest_Status == 1: if app.GetGlobalTimeStamp() < settinginfo.DailyQuest_Time: self.MainTimeLine.SetText("[ Verbl. Zeit: " + str(self.FormatTime()) + " Std. ]") self.MainTimeLine.SetFontColor(0.5411, 0.7254, 0.5568) self.disStartButton.Show() self.startButton.Hide() if len(settinginfo.DailyQuest_Monster) > 0: i = 0 slot_count = 6 while i < slot_count: if i + 1 <= len(settinginfo.DailyQuest_Monster): self.targetSlots[i].ClearSlot(i) self.targetSlots[i].SetItemSlot( i, settinginfo.DailyQuest_Monster[i], settinginfo.DailyQuest_Count[i]) self.targetSlots[i].RefreshSlot() if settinginfo.DailyQuest_Count[i] == 0: self.targetSlots[i].ActivateSlot(i) if i + 1 <= len(settinginfo.DailyQuest_Reward): rewardSlotCount = i + 7 self.rewardSlots[i].ClearSlot(rewardSlotCount) self.rewardSlots[i].SetItemSlot( rewardSlotCount, settinginfo.DailyQuest_Reward[i], settinginfo.DailyQuest_RewardCount[i]) self.rewardSlots[i].RefreshSlot() i = i + 1 else: self.MainTimeLine.SetText("[ Die Zeit ist abgelaufen! ]") self.MainTimeLine.SetFontColor(0.9, 0.4745, 0.4627) self.disStartButton.Show() self.startButton.Hide()
def FormatTime(self): sec = settinginfo.DailyQuest_Time - app.GetGlobalTimeStamp() m, s = divmod(sec, 60) h, m = divmod(m, 60) return "%d:%02d:%02d" % (h, m, s)
class DungeonCooldownToolTip(ui.Window): normalWidth = 200 dungeonCooldown = [ app.GetGlobalTimeStamp() + (1*60), app.GetGlobalTimeStamp() + (15*60), app.GetGlobalTimeStamp() + (3*60), app.GetGlobalTimeStamp() + (5*60) ] def __init__(self,dgButton,dgWindow): ui.Window.__init__(self) self.dgButton = dgButton self.SetSize(self.normalWidth,100) self.dgWindow = dgWindow self.Hide() self.MakeToolTip() def __del__(self): ui.Window.__del__(self) def AdjustPosition(self): x, y = self.dgButton.GetGlobalPosition() # self.SetPosition(x - self.normalWidth - 10 + 22,(y + 630)-self.toolTip.toolTipHeight) self.SetPosition(wndMgr.GetScreenWidth() - 256 - 75 - 20,75) def MakeToolTip(self): toolTip = uiToolTip.ToolTip() toolTip.SetParent(self) toolTip.SetPosition(1, 1) toolTip.SetFollow(False) toolTip.Show() self.toolTip = toolTip def Open(self): # chat.AppendChat(chat.CHAT_TYPE_DEBUG,"Open!") self.toolTip.ClearToolTip() self.toolTip.AppendTextLine("Dungeonkompendium",self.toolTip.TITLE_COLOR) self.toolTip.AppendDescription("Hier findest du alle Infos zu den Dungeons, so das du ja nichts selber rausfinden musst!",26) self.toolTip.AppendSpace(5) self.toolTip.AppendHorizontalLine() self.toolTip.AppendTextLine("Abklingzeiten:",self.toolTip.TITLE_COLOR) self.toolTip.AppendSpace(5) self.toolTip.AppendCooldownTextLine("DungeonName 01 :",0) self.toolTip.AppendCooldownTextLine("Dämonenturm :",0) self.toolTip.AppendCooldownTextLine("Devils Catacomb :",0) self.toolTip.AppendCooldownTextLine("Drachenraum :",self.dungeonCooldown[0]) self.toolTip.AppendCooldownTextLine("Tal der Keine Ahnung :",self.dungeonCooldown[1]) self.toolTip.AppendCooldownTextLine("Höhlen der Planlosigkeit :",self.dungeonCooldown[2]) self.toolTip.AppendCooldownTextLine("WasGibtsNoch-Run :",self.dungeonCooldown[3]) self.toolTip.AppendCooldownTextLine("Verlies des Roten Drachen :",0) self.toolTip.AppendSpace(5) self.toolTip.ResizeToolTip() self.AdjustPosition() self.Show() def Close(self): self.Hide()
def OnUpdate(self): self.updatetimer += 1 if self.updatetimer == 500: net.SendChatPacket("/bosstrackingtest") self.updatetimer = 0 if constInfo.bosstracking == 1: if int(self.newbtcadi1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtcadi1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtcadi1) - app.GetGlobalTimeStamp()))) if int(self.newbtcadi2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtcadi2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtcadi2) - app.GetGlobalTimeStamp()))) if int(self.newbtcadi3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtcadi3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtcadi3) - app.GetGlobalTimeStamp()))) if int(self.newbtcadi4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtcadi4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtcadi4) - app.GetGlobalTimeStamp()))) if int(self.newbtcadi5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtcadi5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtcadi5) - app.GetGlobalTimeStamp()))) if int(self.newbtcadi6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtcadi6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtcadi6) - app.GetGlobalTimeStamp()))) ################################# elif constInfo.bosstracking == 2: if int(self.newbtalevkral1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtalevkral1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtalevkral1) - app.GetGlobalTimeStamp()))) if int(self.newbtalevkral2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtalevkral2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtalevkral2) - app.GetGlobalTimeStamp()))) if int(self.newbtalevkral3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtalevkral3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtalevkral3) - app.GetGlobalTimeStamp()))) if int(self.newbtalevkral4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtalevkral4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtalevkral4) - app.GetGlobalTimeStamp()))) if int(self.newbtalevkral5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtalevkral5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtalevkral5) - app.GetGlobalTimeStamp()))) if int(self.newbtalevkral6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtalevkral6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtalevkral6) - app.GetGlobalTimeStamp()))) ################################# elif constInfo.bosstracking == 3: if int(self.newbtkorumcek1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtkorumcek1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtkorumcek1) - app.GetGlobalTimeStamp()))) if int(self.newbtkorumcek2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtkorumcek2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtkorumcek2) - app.GetGlobalTimeStamp()))) if int(self.newbtkorumcek3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtkorumcek3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtkorumcek3) - app.GetGlobalTimeStamp()))) if int(self.newbtkorumcek4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtkorumcek4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtkorumcek4) - app.GetGlobalTimeStamp()))) if int(self.newbtkorumcek5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtkorumcek5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtkorumcek5) - app.GetGlobalTimeStamp()))) if int(self.newbtkorumcek6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtkorumcek6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtkorumcek6) - app.GetGlobalTimeStamp()))) ################################# elif constInfo.bosstracking == 4: if int(self.newbtsarikaplan1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtsarikaplan1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtsarikaplan1) - app.GetGlobalTimeStamp()))) if int(self.newbtsarikaplan2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtsarikaplan2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtsarikaplan2) - app.GetGlobalTimeStamp()))) if int(self.newbtsarikaplan3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtsarikaplan3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtsarikaplan3) - app.GetGlobalTimeStamp()))) if int(self.newbtsarikaplan4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtsarikaplan4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtsarikaplan4) - app.GetGlobalTimeStamp()))) if int(self.newbtsarikaplan5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtsarikaplan5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtsarikaplan5) - app.GetGlobalTimeStamp()))) if int(self.newbtsarikaplan6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtsarikaplan6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtsarikaplan6) - app.GetGlobalTimeStamp()))) ################################# elif constInfo.bosstracking == 5: if int(self.newbtbuzkralice1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtbuzkralice1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtbuzkralice1) - app.GetGlobalTimeStamp()))) if int(self.newbtbuzkralice2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtbuzkralice2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtbuzkralice2) - app.GetGlobalTimeStamp()))) if int(self.newbtbuzkralice3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtbuzkralice3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtbuzkralice3) - app.GetGlobalTimeStamp()))) if int(self.newbtbuzkralice4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtbuzkralice4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtbuzkralice4) - app.GetGlobalTimeStamp()))) if int(self.newbtbuzkralice5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtbuzkralice5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtbuzkralice5) - app.GetGlobalTimeStamp()))) if int(self.newbtbuzkralice6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtbuzkralice6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtbuzkralice6) - app.GetGlobalTimeStamp()))) ################################# elif constInfo.bosstracking == 6: if int(self.newbtdokuzk1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtdokuzk1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtdokuzk1) - app.GetGlobalTimeStamp()))) if int(self.newbtdokuzk2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtdokuzk2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtdokuzk2) - app.GetGlobalTimeStamp()))) if int(self.newbtdokuzk3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtdokuzk3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtdokuzk3) - app.GetGlobalTimeStamp()))) if int(self.newbtdokuzk4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtdokuzk4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtdokuzk4) - app.GetGlobalTimeStamp()))) if int(self.newbtdokuzk5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtdokuzk5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtdokuzk5) - app.GetGlobalTimeStamp()))) if int(self.newbtdokuzk6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtdokuzk6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtdokuzk6) - app.GetGlobalTimeStamp()))) ################################# elif constInfo.bosstracking == 7: if int(self.newbtcolejder1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtcolejder1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtcolejder1) - app.GetGlobalTimeStamp()))) if int(self.newbtcolejder2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtcolejder2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtcolejder2) - app.GetGlobalTimeStamp()))) if int(self.newbtcolejder3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtcolejder3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtcolejder3) - app.GetGlobalTimeStamp()))) if int(self.newbtcolejder4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtcolejder4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtcolejder4) - app.GetGlobalTimeStamp()))) if int(self.newbtcolejder5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtcolejder5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtcolejder5) - app.GetGlobalTimeStamp()))) if int(self.newbtcolejder6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtcolejder6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtcolejder6) - app.GetGlobalTimeStamp()))) ################################# elif constInfo.bosstracking == 8: if int(self.newbtagac1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtagac1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtagac1) - app.GetGlobalTimeStamp()))) if int(self.newbtagac2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtagac2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtagac2) - app.GetGlobalTimeStamp()))) if int(self.newbtagac3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtagac3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtagac3) - app.GetGlobalTimeStamp()))) if int(self.newbtagac4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtagac4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtagac4) - app.GetGlobalTimeStamp()))) if int(self.newbtagac5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtagac5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtagac5) - app.GetGlobalTimeStamp()))) if int(self.newbtagac6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtagac6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtagac6) - app.GetGlobalTimeStamp()))) ################################# elif constInfo.bosstracking == 8: if int(self.newbtagac1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtagac1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtagac1) - app.GetGlobalTimeStamp()))) if int(self.newbtagac2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtagac2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtagac2) - app.GetGlobalTimeStamp()))) if int(self.newbtagac3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtagac3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtagac3) - app.GetGlobalTimeStamp()))) if int(self.newbtagac4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtagac4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtagac4) - app.GetGlobalTimeStamp()))) if int(self.newbtagac5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtagac5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtagac5) - app.GetGlobalTimeStamp()))) if int(self.newbtagac6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtagac6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtagac6) - app.GetGlobalTimeStamp()))) ################################# elif constInfo.bosstracking == 9: if int(self.newbtkomutan1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtkomutan1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtkomutan1) - app.GetGlobalTimeStamp()))) if int(self.newbtkomutan2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtkomutan2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtkomutan2) - app.GetGlobalTimeStamp()))) if int(self.newbtkomutan3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtkomutan3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtkomutan3) - app.GetGlobalTimeStamp()))) if int(self.newbtkomutan4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtkomutan4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtkomutan4) - app.GetGlobalTimeStamp()))) if int(self.newbtkomutan5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtkomutan5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtkomutan5) - app.GetGlobalTimeStamp()))) if int(self.newbtkomutan6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtkomutan6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtkomutan6) - app.GetGlobalTimeStamp()))) ################################# elif constInfo.bosstracking == 10: if int(self.newbtkaranlik1) == 0: self.Channel1Time.SetText("CH1: Yaþýyor") elif (int(self.newbtkaranlik1) - app.GetGlobalTimeStamp() < 0): self.Channel1Time.SetText("CH1: Yaþýyor") else: self.Channel1Time.SetText("CH1: " + str( FormatTimeBevis( int(self.newbtkaranlik1) - app.GetGlobalTimeStamp()))) if int(self.newbtkaranlik2) == 0: self.Channel2Time.SetText("CH2: Yaþýyor") elif (int(self.newbtkaranlik2) - app.GetGlobalTimeStamp() < 0): self.Channel2Time.SetText("CH2: Yaþýyor") else: self.Channel2Time.SetText("CH2: " + str( FormatTimeBevis( int(self.newbtkaranlik2) - app.GetGlobalTimeStamp()))) if int(self.newbtkaranlik3) == 0: self.Channel3Time.SetText("CH3: Yaþýyor") elif (int(self.newbtkaranlik3) - app.GetGlobalTimeStamp() < 0): self.Channel3Time.SetText("CH3: Yaþýyor") else: self.Channel3Time.SetText("CH3: " + str( FormatTimeBevis( int(self.newbtkaranlik3) - app.GetGlobalTimeStamp()))) if int(self.newbtkaranlik4) == 0: self.Channel4Time.SetText("CH4: Yaþýyor") elif (int(self.newbtkaranlik4) - app.GetGlobalTimeStamp() < 0): self.Channel4Time.SetText("CH4: Yaþýyor") else: self.Channel4Time.SetText("CH4: " + str( FormatTimeBevis( int(self.newbtkaranlik4) - app.GetGlobalTimeStamp()))) if int(self.newbtkaranlik5) == 0: self.Channel5Time.SetText("CH5: Yaþýyor") elif (int(self.newbtkaranlik5) - app.GetGlobalTimeStamp() < 0): self.Channel5Time.SetText("CH5: Yaþýyor") else: self.Channel5Time.SetText("CH5: " + str( FormatTimeBevis( int(self.newbtkaranlik5) - app.GetGlobalTimeStamp()))) if int(self.newbtkaranlik6) == 0: self.Channel6Time.SetText("CH6: Yaþýyor") elif (int(self.newbtkaranlik6) - app.GetGlobalTimeStamp() < 0): self.Channel6Time.SetText("CH6: Yaþýyor") else: self.Channel6Time.SetText("CH6: " + str( FormatTimeBevis( int(self.newbtkaranlik6) - app.GetGlobalTimeStamp())))
def SetDuration(self, duration): self.endTime = 0 if duration > 0: self.endTime = app.GetGlobalTimeStamp() + duration