Jump to content

Schyck

Inactive Member
  • Posts

    7
  • Joined

  • Last visited

  • Feedback

    0%

Posts posted by Schyck

  1. AZYRAH

    Our goal is to keep the original essence of the game, for this we made the official systems almost identical, with some modifications and new systems to make the gameplay easier and enjoy the advantages of playing on a private server. We invite you to join our community!

    The beta phase took place until 13.01.2022. Since 14.01.2022 the server is live.

    Website: https://azyrah.net/

    Register: https://azyrah.net/register/

    Discordhttps://discord.com/invite/hVq7RUA4fJ

    Presentation: https://azyrah.net/presentation

     

    .png
    .png
    .png
    .png
    .gif
    .gif
    .png
    .png
    .png
    .png
    .png
    .png
    .png
    .png

    • Metin2 Dev 1
    • Love 4
  2. Spoiler
    10 minutes ago, HaiosMotan said:

    first thing

    you need to change

    self.wndChatSettingOption = ChatSettingWindow(self)

    to 

    self.wndChatSettingOption = ChatSettingWindow()

    but after you done this all,the system doesn't work as intended,because you just deleted the RefreshChatWindow()

    so,if you un-check an option and save,the chat will not refresh => the messages you want to dissapear,don't dissapear

     

    Yes, I forgot to put that part in the post I made. But what I put was the solution for the problem you were having. What you comment now can be easily solved if you use your reasoning a little.

    Here we go:

    # Just delete all related with "RefreshChatWindow" (except define, obviously), and change this define like this:
    	def OnUpdate(self):
    		if self.boardState == chatm2g.BOARD_STATE_EDIT:
    			if app.ENABLE_CHATTING_WINDOW_RENEWAL:
    				self.RefreshChatWindow()
    			chatm2g.Update(self.chatID)
    		elif self.boardState == chatm2g.BOARD_STATE_VIEW:
    			if systemSetting.IsViewChat():
    				if app.ENABLE_CHATTING_WINDOW_RENEWAL:
    					self.RefreshChatWindow()
    				chatm2g.Update(self.chatID)
    
    # That's all!

     

    • Metin2 Dev 1
    • Love 4
  3. You guys are looking for the solution by looking at the wrong problem. The syserr may tell you something related to GetGlobalPosition, but that's not really the problem. The solution is easier than it sounds:

    #--1
    #In the def __init__ from the class ChatSettingWindow:
    #Replace this:
    		def __init__(self, parent):
    #With this:
    		def __init__(self):
    
    #In the same define, search and delete:
    			self.parent = parent
    
    #--2
    #In this define
    		def __OnClickSave(self):
    #Delete this:
    			if self.parent:
    				self.parent.RefreshChatWindow()
    
    #--3
    #In this define
    		def __QuestionPopupAccept(self):
    #Delete this:
    			if self.parent:
    				self.parent.RefreshChatWindow()
    
    # --4
    #Replace this:
    self.wndChatSettingOption = ChatSettingWindow(self)
    #With this:
    self.wndChatSettingOption = ChatSettingWindow()

    Try again, and the "OnRender" after teleport will works good. ?

    • Metin2 Dev 1
    • Love 2
  4. #3
    			def __LoadInformation(self, race):
    				self.yPos = 7
    				self.children = []
    				self.race = race
    				self.stoneImg = None
    				self.stoneVnum = None
    				self.nextStoneIconChange = 0
    
    				self.__LoadInformation_Default(race)
    				self.__LoadInformation_Race(race)
    				self.__LoadInformation_Resists(race)
    				self.__LoadInformation_Drops(race)
    
    #4
    			def __LoadInformation_Drops(self, race):
    				self.AppendSeperator()
    
    				if race in MONSTER_INFO_DATA:
    					if len(MONSTER_INFO_DATA[race]["items"]) == 0:
    						if self.itemScrollBar.IsShow():
    							self.AppendTextLine(localeInfo.TARGET_INFO_NO_DEBUG)
    						else:
    							self.AppendTextLine(localeInfo.TARGET_INFO_NO_ITEM_TEXT)
    					else:
    						itemListBox = ui.ListBoxExNew(32 + 5, self.MAX_ITEM_COUNT)
    						itemListBox.SetSize(self.GetWidth() - 15 * 2 - ui.ScrollBar.SCROLLBAR_WIDTH, (32 + 5) * self.MAX_ITEM_COUNT)
    						height = 0
    						for curItem in MONSTER_INFO_DATA[race]["items"]:
    							if curItem.has_key("vnum_list"):
    								height += self.AppendItem(itemListBox, curItem["vnum_list"], curItem["count"], curItem["rarity"])
    							else:
    								height += self.AppendItem(itemListBox, curItem["vnum"], curItem["count"], curItem["rarity"])
    						
    						if height < itemListBox.GetHeight():
    							itemListBox.SetSize(itemListBox.GetWidth(), height)
    						self.AppendWindow(itemListBox, 15)
    						itemListBox.SetBasePos(0)
    
    						if len(MONSTER_INFO_DATA[race]["items"]) > itemListBox.GetViewItemCount():
    							itemScrollBar = ui.ScrollBar()
    							itemScrollBar.SetParent(self)
    							itemScrollBar.SetPosition(itemListBox.GetRight(), itemListBox.GetTop())
    							itemScrollBar.SetScrollBarSize(32 * self.MAX_ITEM_COUNT + 5 * (self.MAX_ITEM_COUNT - 1))
    							itemScrollBar.SetMiddleBarSize(float(self.MAX_ITEM_COUNT) / float(height / (32 + 5)))
    							itemScrollBar.Show()
    							itemListBox.SetScrollBar(itemScrollBar)
    							self.itemScrollBar = itemScrollBar
    				else:
    					self.AppendTextLine(localeInfo.TARGET_INFO_NO_ITEM_TEXT)

     

  5. # In the InfoBoard class: (uiTarget.py)
    # 1
    			def __init__(self):
    				ui.ThinBoard.__init__(self)
    
    				self.HideCorners(self.LT)
    				self.HideCorners(self.RT)
    				self.HideLine(self.T)
    
    				self.race = 0
    				self.hasItems = False
    
    				self.itemTooltip = uiToolTip.ItemToolTip()
    				self.itemTooltip.HideToolTip()
    
    				self.stoneImg = None
    				self.stoneVnum = None
    				self.lastStoneVnum = 0
    				self.nextStoneIconChange = 0
    
    				self.itemScrollBar = None # Add this line
    
    				self.SetSize(self.BOARD_WIDTH, 0)
    
    # 2
    			def Close(self):
    				self.itemTooltip.HideToolTip()
    				self.itemScrollBar = None # Add this line
    				self.Hide()

     

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