Jump to content

Problem with switch system


Recommended Posts

We tested a 34k client and work...

But on a 40k client experiencing problems.

 

Syserr:

 

0804 01:02:41318 ::   File "ui.py", line 1029, in CallEvent


0804 01:02:41319 ::   File "ui.py", line 87, in __call__


0804 01:02:41319 ::   File "ui.py", line 69, in __call__


0804 01:02:41319 ::   File "uiInventory.py", line 256, in Alaska_switch


0804 01:02:41319 ::   File "system.py", line 130, in __pack_import


0804 01:02:41320 ::   File "system.py", line 110, in _process_result


0804 01:02:41320 ::   File "uiswitch.py", line 24, in <module>


0804 01:02:41320 ::   File "uiswitch.py", line 163, in Switcher


0804 01:02:41320 :: NameError
0804 01:02:41321 :: : 
0804 01:02:41321 :: name 'locale' is not defined
0804 01:02:41321 :: 

I change import locale with import localeInfo but the problem still persists.

 

  • Metin2 Dev 1
Link to comment
Share on other sites

You have this error somewhere else, not in the uiswitch.py. Where do you call it?

 

FULL ERROR

 

0804 02:09:53497 ::   File "ui.py", line 1029, in CallEvent
 
0804 02:09:53497 ::   File "ui.py", line 87, in __call__
 
0804 02:09:53498 ::   File "ui.py", line 69, in __call__
 
0804 02:09:53498 ::   File "uiInventory.py", line 257, in Alaska_switch
 
0804 02:09:53498 :: AttributeError
0804 02:09:53498 :: : 
0804 02:09:53498 :: 'module' object has no attribute 'Switcher'
0804 02:09:53498 :: 
Link to comment
Share on other sites

0804 02:20:56378 :: Failed to load script file : localeInfo/ro/ui/morphe/system/binari2.py
0804 02:20:56378 :: error  : No file or directory
0804 02:20:56380 :: 
ui.py(line:2778) LoadScriptFile
system.py(line:192) execfile
system.py(line:161) Run
system.py(line:176) __LoadTextFile__
system.py(line:61) __init__


LoadScriptFile1 - <type 'exceptions.IOError'>:No file or directory


0804 02:20:56380 :: ============================================================================================================
0804 02:20:56380 :: Abort!!!!




0804 02:20:56381 :: 
uiswitch.py(line:52) __LoadWindow
ui.py(line:2784) LoadScriptFile
exception.py(line:36) Abort


CostumeWindow.LoadWindow.LoadObject - <type 'exceptions.SystemExit'>:


0804 02:20:56381 :: ============================================================================================================
0804 02:20:56381 :: Abort!!!!
Link to comment
Share on other sites

It works perfectly, but when I press the button that changes occur in syserr 

 

0804 02:25:38234 :: Traceback (most recent call last):


0804 02:25:38234 ::   File "uiswitch.py", line 159, in OnUpdate


0804 02:25:38235 ::   File "uiswitch.py", line 139, in refresh


0804 02:25:38235 :: TypeError
0804 02:25:38235 :: : 
0804 02:25:38235 :: an integer is required
0804 02:25:38235 :: 

0804_022911.jpg

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

Hey try this:

def refresh(self,dstSlotPos,srcSlotPos):
		attrSlot = []	
		for i in xrange(player.ATTRIBUTE_SLOT_MAX_NUM):
			itematrr = player.GetItemAttribute(dstSlotPos, i)
			attrSlot.append(itematrr)
		for i in xrange(5):		
			self.bonusslot[i].SetText("")
			
		for i in xrange(player.ATTRIBUTE_SLOT_MAX_NUM-2):
			type = attrSlot[i][0]
			value = attrSlot[i][1]
			affectString = self.__GetAffectString(type, value)
			if int(value) < 0:				
				self.bonusslot[i].SetPackedFontColor(self.NEGATIVE_COLOR)
			else:
				self.bonusslot[i].SetPackedFontColor(self.POSITIVE_COLOR)
			self.bonusslot[i].SetText(affectString)
		
		itemIndex = player.GetItemIndex(srcSlotPos)
		itemCount = player.GetItemCount(srcSlotPos)
		self.switchslot.ClearSlot(1)
		self.switchslot.SetItemSlot(1, itemIndex, itemCount)
			

Try to replace this function with the one you have.

 

Kind Regards,

Frozen

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



×
×
  • 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.