Jump to content

Recommended Posts

Hey, I've been adding effect on slot when picking up items

sysser looks like this so im not even sure what's wrong since nothing was added in game.py

spacer.png

Edited by Metin2 Dev
Core X - External 2 Internal

The problem is not in game.py. Also in InterFaceModule.py.

game.py sends a function to InterfaceModule

There is HighlightSlot inside this function.

Syserr tells you

Answer: What does HighlightSlot do? You used this here. But I don't understand why he says you used it. Please explain to InterFaceModule.py what HighlightSlot does.

  • Contributor

@BadGrecee don't worry about it, he probably fucked up some tabs(as usual) or pasted that function outside of InventoryWindow(the benefits of not bothering to even learn the basics of Python).

@Tuckii please search "def HighlightSlot" in uiInventory.py, then fix the damn tabs/spaces. 

 

If you really don't have that function(which I doubt), then here, extend "class InventoryWindow(ui.ScriptWindow):" with these methods:

	if app.WJ_ENABLE_PICKUP_ITEM_EFFECT:
		def HighlightSlot(self, slot):
			if slot>player.INVENTORY_PAGE_SIZE*player.INVENTORY_PAGE_COUNT:
				return
			
			if not slot in self.listHighlightedSlot:
				self.listHighlightedSlot.append (slot)

		def DelHighlightSlot(self, inventorylocalslot):
			if inventorylocalslot in self.listHighlightedSlot:
				if inventorylocalslot >= player.INVENTORY_PAGE_SIZE:
					self.wndItem.DeactivateSlot(inventorylocalslot-player.INVENTORY_PAGE_SIZE)
				else:
					self.wndItem.DeactivateSlot(inventorylocalslot)

				self.listHighlightedSlot.remove(inventorylocalslot)

 

  • Metin2 Dev 1

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • 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.