Jump to content
Mali61

python Fantasy Loading Gage Name

Recommended Posts

Spoiler

 

Find in locale/xx/ui/loadingwindow.py:

				{
					"name" : "FullGage",
					"type" : "expanded_image",

					"x" : 40,
					"y" : 25,

					"image" : uiScriptLocale.LOCALE_UISCRIPT_PATH + "loading/gauge_full.dds",
				},

Add this;

				{
                                      "name" : "LoadingName_Text",
                                      "type" : "text",

                                      "x" : 190,
                                      "y" : -8,

                                      "text" : "", 
                                      "vertical_align" : "center",                    
                                },

Add in constInfo.py;

loadingname = ""

Find in root/introloading.py:

			self.loadingGage=self.GetChild("FullGage")

Add this;

			self.loadingName_txt=self.GetChild("LoadingName_Text")

Find:

	def __SetProgress(self, p):

Change like this;

	def GetChName(self, p):
		import constInfo
		text = constInfo.loadingname
		uzunluk = len(text)
		asd = uzunluk*p/100
		return text[0:asd]
	
	def __SetProgress(self, p):
		if self.loadingGage:
			self.loadingGage.SetPercentage(2+98*p/100, 100)
			name = self.GetChName(2+98*p/100)
			self.loadingName_txt.SetText(name)

Last one if you use the official pack introselect(unpacked 2015 & 2018 packs), use this:

Spoiler

Find in new_introselect.py:


			playTime = net.GetAccountCharacterSlotDataInteger(chrSlot, net.ACCOUNT_CHARACTER_SLOT_PLAYTIME)

Add this;


			constInfo.loadingname = net.GetAccountCharacterSlotDataString(chrSlot, net.ACCOUNT_CHARACTER_SLOT_NAME)

 

If you use the fake official introselect or old introselet, use this:

Spoiler

Find in introselect.py:


				player.SetPlayTime(playTime)

Add this;


				constInfo.loadingname = net.GetAccountCharacterSlotDataString(self.slot, net.ACCOUNT_CHARACTER_SLOT_NAME)

 

2852191.jpg

  • Love 3
  • Haha 1

Share this post


Link to post
32 minutes ago, Mali61 said:

	def GetChName(self, p):
		import constInfo
		text = constInfo.loadingname
		uzunluk = len(text)
		asd = uzunluk*p/100
		return text[0:asd]

 

# import constInfo - at the beginning of the file
def GetChName(percentage):
	name = constInfo.loadingname
	return name[:(len(name) * percentage) / 100]

And please stop to use turkish name for variables when you share something, looks very creepy..

  • Love 1

Share this post


Link to post

Why are you doing this? universal software language is english so it is so clear and simple. I am really sorry that you are sharing something and it is nice. Do not humiliate yourself by stubbing on this subject many times.You can use "google translate" for variables. Thanks for sharing.

Share this post


Link to post
13 minutes ago, Tasho said:

# import constInfo - at the beginning of the file
def GetChName(percentage):
	name = constInfo.loadingname
	return name[:(len(name) * percentage) / 100]

And please stop to use turkish name for variables when you share something, looks very creepy..

return name[:(len(name) * percentage) / 100]

Bro please stop this I know this easy way but i want to show every way and turkish variables, everyone can change the names. I m turkish and this is my choice :)

  • Love 1

Share this post


Link to post
12 minutes ago, Mali61 said:

return name[:(len(name) * percentage) / 100]

Bro please stop this I know this easy way but i want to show every way and turkish variables, everyone can change the names. I m turkish and this is my choice :)

But if you want someone to use it do english variables.

Share this post


Link to post
On 2/4/2018 at 3:16 AM, Mali61 said:

return name[:(len(name) * percentage) / 100]

Bro please stop this I know this easy way but i want to show every way and turkish variables, everyone can change the names. I m turkish and this is my choice :)

Thanks for sharing, I was looking for this for loading letters with loading bar and I agree with you.

Share this post


Link to post

anyone can write in any language they want. This does not concern anyone. English can be a universal language. Universal codes do not have to be written in English.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

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