Jump to content

Recommended Posts

  • Active+ Member

Hi guys,

I need to do function for hide time when quest is open, but i don't know how to implement it to this code. Can somebody help me?

 

Spoiler

open game.py and put import time on top of this file

Find: self.__ProcessPreservedServerCommand();

and under it:


self.timeLine = ui.TextLine()
self.timeLine.SetFontName(locale.UI_DEF_FONT_LARGE )
self.timeLine.SetFontColor(10, 10, 0)
self.timeLine.SetPosition((wndMgr.GetScreenWidth() - 130) / 2, 155)

 

Find: self.ViewDistance.SetPosition(0, 0) ; 

and under it:


self.timeLine.SetWindowHorizontalAlignCenter()
self.timeLine.SetHorizontalAlignCenter()
self.timeLine.SetFeather()
self.timeLine.SetOutline()
self.timeLine.Show()

 

Find:  app.UpdateGame();

and under it:


localtime = localtime = time.strftime("%d %m %Y %H:%M")
self.timeLine.SetText(localtime)
self.timeLine.Show()

 

Thank for your asnwers!

Kind Regards ReFresh

I'll be always helpful!  😉

Link to comment
https://metin2.dev/topic/12259-hide-time-function-with-this-code/
Share on other sites

  • 2 weeks later...
  • Active+ Member
5 hours ago, VegaS said:

 

(For the rest, please use your brain -> game.py)


	def	OpenQuestWindow(self, skin, idx):

		if skin:
			self.timeLine.Hide()

"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""

And actual hide check for quest is in interfaceModule.py from here:


wnds = self.__HideWindows()

 

 

 

Thank you for asnwer, but still doesn't work. 

I'll be always helpful!  😉

  • Active+ Member
5 hours ago, VegaS said:

 

(For the rest, please use your brain -> game.py)


	def	OpenQuestWindow(self, skin, idx):

		if skin:
			self.timeLine.Hide()

"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""

And actual hide check for quest is in interfaceModule.py from here:


wnds = self.__HideWindows()

 

 

 

Thank you for asnwer, but still does'nt work. 

I'll be always helpful!  😉

  • 4 months later...
  • Honorable Member
7 hours ago, ReFresh said:

Code by VegaS works but badly.

Wow, not only you asked the ready work without even trying to learn, but you're also now saying it doesn't work? Plus without even giving the reason you're saying that? This kind of people gets on my nerves. 5+ Months and you don't even try to learn something out of what "you work" on.

  • Love 1

 

"Nothing's free in this life.

Ignorant people have an obligation to make up for their ignorance by paying those who help them.

Either you got the brains or cash, if you lack both you're useless."

Syreldar

  • Active+ Member
4 hours ago, Syreldar said:

Wow, not only you asked the ready work without even trying to learn, but you're also now saying it doesn't work? Plus without even giving the reason you're saying that? This kind of people gets on my nerves. 5+ Months and you don't even try to learn something out of what "you work" on.

Eh... man I'm not a professional programer. I know something little with python but that's all. I tried to learn python but I don't know how to learn this programming language alone. And reason? I thought about it but it's too hard to describe it because my English isn't good. But I can try to describe it. Reason: When I open some quest, time will hide and then after few seconds time will be shown again and quest is still opened. And if you don't understand me what's my problem I can do a video with that.

Sincerely,

ReFresh

I'll be always helpful!  😉

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.