Jump to content

Recommended Posts

I've installed auto potions, they work, PV and PM regenerates, but I can't see how much % are left in them.

Sorry for my bad english.

 

Photo: 0426_020516.jpg

 

 

syserr: 

0426 01:34:24605 :: Traceback (most recent call last):

0426 01:34:24605 ::   File "ui.py", line 1391, in OnOverInItem

0426 01:34:24605 ::   File "ui.py", line 87, in __call__

0426 01:34:24605 ::   File "ui.py", line 78, in __call__

0426 01:34:24605 ::   File "uiInventory.py", line 588, in OverInItem

0426 01:34:24605 ::   File "uiInventory.py", line 756, in __ShowToolTip

0426 01:34:24606 ::   File "uiToolTip.py", line 526, in SetInventoryItem

0426 01:34:24606 ::   File "uiToolTip.py", line 1083, in AddItemData

0426 01:34:24606 :: TypeError
0426 01:34:24606 :: : 
0426 01:34:24606 :: not all arguments converted during string formatting
0426 01:34:24606 ::

 

uitooltip.py
            ## ŔÚµżą°ľŕ
            elif constInfo.IS_AUTO_POTION(itemVnum):
                if 0 != metinSlot:
                    ## 0: Č°ĽşČ­, 1: »çżë·®, 2: ĂŃ·®
                    isActivated = int(metinSlot[0])
                    usedAmount = float(metinSlot[1])
                    totalAmount = float(metinSlot[2])
                    
                    if 0 == totalAmount:
                        totalAmount = 1
                    
                    self.AppendSpace(5)

                    if 0 != isActivated:
                        self.AppendTextLine("(%s)" % (localeInfo.TOOLTIP_AUTO_POTION_USING), self.SPECIAL_POSITIVE_COLOR)
                        self.AppendSpace(5)
                        
                    1083 LINE -> self.AppendTextLine(localeInfo.TOOLTIP_AUTO_POTION_REST % (100.0 - ((usedAmount / totalAmount) * 100.0)), self.POSITIVE_COLOR)

 

Thank you in advance!

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

28 minutes ago, Kyo said:

try 

self.AppendTextLine(str(localeInfo.TOOLTIP_AUTO_POTION_REST % (100.0 - ((usedAmount / totalAmount) * 100.0))), self.POSITIVE_COLOR)


self.AppendTextLine(str(localeInfo.TOOLTIP_AUTO_POTION_REST % (100.0 - ((usedAmount / totalAmount) * 100.0))), self.POSITIVE_COLOR)

 

 

 

Nothing has changed, unfortunately. Thanks for the reply.

 

29 minutes ago, Kyo said:

try 

self.AppendTextLine(str(localeInfo.TOOLTIP_AUTO_POTION_REST % (100.0 - ((usedAmount / totalAmount) * 100.0))), self.POSITIVE_COLOR)


self.AppendTextLine(str(localeInfo.TOOLTIP_AUTO_POTION_REST % (100.0 - ((usedAmount / totalAmount) * 100.0))), self.POSITIVE_COLOR)

 

 

I solved it like this:

self.AppendTextLine(localeInfo.TOOLTIP_AUTO_POTION_REST + "%d" % (100.00 - ((usedAmount/totalAmount) * 100.00)), self.POSITIVE_COLOR)

 

spacer.png

 

Do you or anybody know to make it like on official servers? Like 99,99.

Thanks.

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

8 hours ago, CristianDragan said:

 

Nothing has changed, unfortunately. Thanks for the reply.

 

I solved it like this:

self.AppendTextLine(localeInfo.TOOLTIP_AUTO_POTION_REST + "%d" % (100.00 - ((usedAmount/totalAmount) * 100.00)), self.POSITIVE_COLOR)

 

spacer.png

 

Do you or anybody know to make it like on official servers? Like 99,99.

Thanks.


Change

%d

to 

%.2f%%

 

Edited by Metin2 Dev
Core X - External 2 Internal
  • Love 1

I completely abandoned working on the files for this game. I do not respond to private messages.

.png

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.