Jump to content

Looking 4 a goot Py Tutorial (ui writing!)


Recommended Posts

Hey There,

 

i'm still looking for a good tutorial/guide to learn Python in combination with metin2 ui development.

I don't wanna use all in 1 file.

 

I will write a python file with the look of a window (uiscript) and a other file with the Codes/functions. (root).

 

I hope i'll unterstand me with my bad english ~.~ and can help me with a helpfull link

 

Thanks a lot.

 

Greatz Benhero

Link to comment
Share on other sites

  • Replies 5
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Okay.. now it works so far.. but i get a nother problem.

How to add a Tooltip (item Tooltip) to an image?

 

Here's my code:

if player.SLOT_TYPE_INVENTORY == attachedSlotType:
    if attachedSlotPos < (45 * 4 - 1):
        mouseModule.mouseController.DeattachObject()
        self.itemVnum = attachedSlotVNUM
        self.itemSlot = attachedSlotPos
        item.SelectItem(attachedSlotVNUM)
        self.transmitItemImage.Show()
        self.transmitItemImage.LoadImage(item.GetIconImageFileName())
        chat.AppendChat(chat.CHAT_TYPE_INFO, "Item wurde erfolgreich geladen!")
    else:
        chat.AppendChat(chat.CHAT_TYPE_INFO, "Du kannst nur Items aus deinem Inventar hinzufügen!")
else:
    chat.AppendChat(chat.CHAT_TYPE_INFO, "Du kannst nur Items aus deinem Inventar hinzufügen!")

I already have a MouseOver Funktion for the Image so that it will display a text when i Over the Image:

self.transmitItemImage.OnMouseOverIn = ui.__mem_func__(self.ShowTooltip)
def ShowTooltip(self):
	chat.AppendChat(chat.CHAT_TYPE_INFO, "Tooltip Anzeigen")

Greatz

Link to comment
Share on other sites

  • 2 months later...

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.