Hey,
habe neulich diesen Fehler:
0611 01:43:59681 :: Traceback (most recent call last):
0611 01:43:59681 :: File "uiMiniMap.py", line 463, in OnUpdate
0611 01:43:59682 :: AttributeError
0611 01:43:59682 :: :
0611 01:43:59682 :: 'int' object has no attribute 'IsIn'
0611 01:43:59682 ::
0611 01:43:59682 :: Traceback (most recent call last):
0611 01:43:59682 :: File "uiTaskBar.py", line 961, in OnUpdate
0611 01:43:59682 :: AttributeError
0611 01:43:59682 :: :
0611 01:43:59682 :: 'NoneType' object has no attribute 'IsIn'
0611 01:43:59682 ::
Der spamt ohne Ende in die syserr. Nach 1 Minute ca. 500kb.
def OnUpdate (uiminimap.py)
Code
- def OnUpdate(self):
- import time
- (x, y, z) = player.GetMainCharacterPosition()
- miniMap.Update(x, y)
- self.Time.SetText(time.strftime("%H:%M"))
- self.Time2.SetText(time.strftime("%d-%m-%Y"))
- # self.positionInfo.SetText("[" + time.strftime("%H:%M:%S") + " " + time.strftime("%Y-%m-%d") + "]")
- # self.online.SetText("[Liczba on-line: %s" % (str(constInfo.ONLINE)) + "]")
- if self.tooltipInfo:
- if TRUE == self.MiniMapWindow.IsIn():
- (mouseX, mouseY) = wndMgr.GetMousePosition()
- (bFind, sName, iPosX, iPosY, dwTextColor) = miniMap.GetInfo(mouseX, mouseY)
- if bFind == 0:
- self.tooltipInfo.Hide()
- elif not self.canSeeInfo:
- self.tooltipInfo.SetText("%s(%s)" % (sName, localeInfo.UI_POS_UNKNOWN))
- self.tooltipInfo.SetTooltipPosition(mouseX - 5, mouseY)
- self.tooltipInfo.SetTextColor(dwTextColor)
- self.tooltipInfo.Show()
- else:
- if localeInfo.IsARABIC() and sName[-1].isalnum():
- self.tooltipInfo.SetText("(%s)%d, %d" % (sName, iPosX, iPosY))
- else:
- self.tooltipInfo.SetText("%s(%d, %d)" % (sName, iPosX, iPosY))
- self.tooltipInfo.SetTooltipPosition(mouseX - 5, mouseY)
- self.tooltipInfo.SetTextColor(dwTextColor)
- self.tooltipInfo.Show()
- else:
- self.tooltipInfo.Hide()
- # AUTOBAN
- if self.imprisonmentDuration:
- self.__UpdateImprisonmentDurationText()
- # END_OF_AUTOBAN
- if True == self.MiniMapShowButton.IsIn():
- self.tooltipMiniMapOpen.Show()
- else:
- self.tooltipMiniMapOpen.Hide()
- if TRUE == self.MiniMapHideButton.IsIn():
- self.tooltipMiniMapClose.Show()
- else:
- self.tooltipMiniMapClose.Hide()
- if TRUE == self.ScaleUpButton.IsIn():
- self.tooltipScaleUp.Show()
- else:
- self.tooltipScaleUp.Hide()
- if TRUE == self.ScaleDownButton.IsIn():
- self.tooltipScaleDown.Show()
- else:
- self.tooltipScaleDown.Hide()
- if TRUE == self.AtlasShowButton.IsIn():
- self.tooltipAtlasOpen.Show()
- else:
- self.tooltipAtlasOpen.Hide()
def OnUpdate (uitaskbar.py)
Code
- def OnUpdate(self):
- self.text[0].SetText(str(player.GetStatus(player.HP)))
- self.text[1].SetText(str(player.GetStatus(player.SP)))
- curHP = player.GetStatus(player.HP)
- maxHP = player.GetStatus(player.MAX_HP)
- curSP = player.GetStatus(player.SP)
- maxSP = player.GetStatus(player.MAX_SP)
- recoveryHP = player.GetStatus(player.HP_RECOVERY)
- recoverySP = player.GetStatus(player.SP_RECOVERY)
- self.SetHp(curHP, recoveryHP, maxHP)
- self.SetMp(curSP, recoverySP, maxSP)
- if app.GetGlobalTime() - self.lastUpdateQuickSlot > 500:
- self.lastUpdateQuickSlot = app.GetGlobalTime()
- self.RefreshQuickSlot()
- if TRUE == self.expGauge.IsIn():
- self.tooltipEXP.Show()
- self.tooltipEXP.SetTop()
- else:
- self.tooltipEXP.Hide()
- if TRUE == self.img.IsIn():
- point, grade = player.GetAlignmentData()
- import colorInfo
- COLOR_DICT = { 0 : colorInfo.TITLE_RGB_GOOD_4,
- 1 : colorInfo.TITLE_RGB_GOOD_3,
- 2 : colorInfo.TITLE_RGB_GOOD_2,
- 3 : colorInfo.TITLE_RGB_GOOD_1,
- 4 : colorInfo.TITLE_RGB_NORMAL,
- 5 : colorInfo.TITLE_RGB_EVIL_1,
- 6 : colorInfo.TITLE_RGB_EVIL_2,
- 7 : colorInfo.TITLE_RGB_EVIL_3,
- 8 : colorInfo.TITLE_RGB_EVIL_4, }
- colorList = COLOR_DICT.get(grade, colorInfo.TITLE_RGB_NORMAL)
- gradeColor = ui.GenerateColor(colorList[0], colorList[1], colorList[2])
- self.toolTipAlignment.ClearToolTip()
- self.toolTipAlignment.AutoAppendTextLine(localeInfo.TITLE_NAME_LIST[grade], gradeColor)
- self.toolTipAlignment.AutoAppendTextLine(localeInfo.ALIGNMENT_NAME + str(point))
- self.toolTipAlignment.AlignHorizonalCenter()
- self.toolTipAlignment.ShowToolTip()
- else:
- self.toolTipAlignment.HideToolTip()
- if app.GetGlobalTime() - self.lastUpdateQuickSlot > 500:
- self.lastUpdateQuickSlot = app.GetGlobalTime()
- self.RefreshQuickSlot()