Jump to content

[HELP]Python #4


Recommended Posts

  • Active Member

Hi.. I can´t see item description :/ I got this error in sysser:

Spoiler

0125 23:20:43598 :: Nepovedlo se načíst seznam barev!
0125 23:20:43598 :: Traceback (most recent call last):

0125 23:20:43598 ::   File "ui.py", line 1493, in OnOverInItem

0125 23:20:43598 ::   File "ui.py", line 84, in __call__

0125 23:20:43598 ::   File "ui.py", line 75, in __call__

0125 23:20:43598 ::   File "uiInventory.py", line 968, in OverInItem

0125 23:20:43598 ::   File "uiInventory.py", line 1144, in ShowToolTip

0125 23:20:43598 ::   File "uiToolTip.py", line 545, in SetInventoryItem

0125 23:20:43598 ::   File "uiToolTip.py", line 1212, in AddItemData

0125 23:20:43598 ::   File "uiToolTip.py", line 844, in __AppendAttributeInformation

0125 23:20:43598 ::   File "uiToolTip.py", line 524, in AppendTextLine

0125 23:20:43598 ::   File "uiToolTip.py", line 207, in AppendTextLine

0125 23:20:43598 ::   File "uiToolTip.py", line 239, in ResizeToolTip

0125 23:20:43598 ::   File "ui.py", line 1912, in SetSize

0125 23:20:43598 :: TypeError
0125 23:20:43598 :: : 
0125 23:20:43598 :: an integer is required
0125 23:20:43598 :: 

uitooltip.py

http://pastebin.com/D2FtWLz6

Link to comment
Share on other sites

  • 3 years later...

Well, i've have the same error, so i don't open another topic, all i can say is that with the "original" binary from client i use the game works, but if I switch the same binary to work in python2.7 (and nothing else) i got this error.

and this is what happens in game

https://metin2.download/picture/TLJXu6Y5gOmAlRMcXZ53rh7Y09K33ByF/.gif

any help?

Edited by Metin2 Dev
Core X - External 2 Internal
Link to comment
Share on other sites

Ok i think i solved. I don't know if it is correct, help me to understand but:
This was the code before:

					affectColor = self.__GetAttributeColorMax(value, type)  <------------------
					self.AppendTextLine(affectString, affectColor)

	def __GetAttributeColor(self, index, value):
		if value > 0:
			if index >= 5:
				return self.SPECIAL_POSITIVE_COLOR2
			else:
				return self.SPECIAL_POSITIVE_COLOR
		elif value == 0:
			return self.NORMAL_COLOR
		else:
			return self.NEGATIVE_COLOR

	def __GetAttributeColorMax(self, value, index): <------------------------
		MAX_ATTR_VALUE = (
			[1,2000, "MAX_HP"],

and then i added 2 arguments (or idk how they names)
 

					affectColor = self.__GetAttributeColorMax(i, value, type) <------------------
					self.AppendTextLine(affectString, affectColor)

	def __GetAttributeColor(self, index, value):
		if value > 0:
			if index >= 5:
				return self.SPECIAL_POSITIVE_COLOR2
			else:
				return self.SPECIAL_POSITIVE_COLOR
		elif value == 0:
			return self.NORMAL_COLOR
		else:
			return self.NEGATIVE_COLOR

	def __GetAttributeColorMax(self, value, index, type): <------------------
		MAX_ATTR_VALUE = (
			[1,2000, "MAX_HP"],

P.s: i'm using Nevisor client 2k10

  • Love 1
Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



  • Similar Content

  • Activity

    1. 13

      Metin2 Closed Beta Content (2003-2004)

    2. 25

      [SRC] Metin2 on LINUX - The Old Metin2 Project

    3. 2

      United/Club/Midgard serverfiles?

    4. 13

      Metin2 Closed Beta Content (2003-2004)

    5. 13

      Metin2 Closed Beta Content (2003-2004)

    6. 0

      Football Ground

  • Recently Browsing

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.