Jump to content
×
×
  • Create New...
  • 0

Qu'est ce que TWIX_YMIR


Jinzo

Question

Version des fichiers/ Type d'émulateur : Metin2

Domaine (Base de données, Client, Core...) : Client

Votre niveau (Débutant, Intermédiaire, Avancé..) : intermédiaire

 

Description du problème : Recherche d'informations sur le client TWIX_YMIR

Comment reproduire le problème ? : Aucune idée

Recherches et tests effectués : Divers forum et recherches sur la toile

1005 17:46:01297 :: Failed to load script file : twix_work/loginwindow/loginwindow.py
1005 17:46:01298 :: 
ui.py(line:5523) LoadScriptFile
system.py(line:192) execfile
system.py(line:163) Run
twix_work/loginwindow/loginwindow.py(line:453) <module>

LoadScriptFile!!!!!!!!!!!!!! - <type 'exceptions.AttributeError'>:'module' object has no attribute 'LOGIN_ACCOUNT_LOAD'

1005 17:46:01298 :: ============================================================================================================
1005 17:46:01298 :: Abort!!!!

1005 17:46:01299 :: 
introLogin.py(line:139) __LoadScript
ui.py(line:5540) LoadScriptFile
exception.py(line:36) Abort

LoginWindow.__LoadScript.LoadObject - <type 'exceptions.SystemExit'>:

1005 17:46:01299 :: ============================================================================================================
1005 17:46:01299 :: Abort!!!!

 

Screenshot du problème concerné :

 

En postant ma demande d'aide, j'affirme avoir lu et accepté le Règlement de Funky-Emulation.

 

Bonjour à toutes et à tous,

 

Cherchant sur le net quelques design intéressants à mettre sur mon client 2016, je suis tombé sur un client qui utilise la "version" TWIX_YMIR !

Ne savant pas de quoi il retourne je me suis vu farfouiller un peu partout, or mes recherches se sont vues infructueuses.

J'ai quand même constaté que le design se trouve à la racine du client dans un répertoire nommé TWIX_YMIR et remplace en quelque sorte le dossier YMIR_WORK , je dis bien en quelque sorte 😃 car TWIX utilise les resource d'YMIR c'est-à-dire les fichiers .py.

 

J'ai pu constater que TWIX avait un seul et unique fichier de lancement .py qui fonctionne sous cette forme : uiScriptLocale.LOGIN_ACCOUNT_LOAD or cette fonction renvoie un joli syserr.

 

J'aimerai avoir quelques précisions sur ce TWIX_YMIR !
 

Si les membres de la communauté pouvaient m'éclairer je leur en serai très reconnaissant, merci !

 

EDIT :

import app
import uiScriptLocale

window = {
	"name" : "LoginWindow",
	"sytle" : ("movable",),

	"x" : 0, 
	"y" : 0,

	"width" : SCREEN_WIDTH,
	"height" : SCREEN_HEIGHT,

	"children" : 
	(
		# Background
		{
			"name" : "background", 
			"type" : "expanded_image",

			"x" : 0, 
			"y" : 0,

			"x_scale" : float(SCREEN_WIDTH) / 1366.0,
			"y_scale" : float(SCREEN_HEIGHT) / 768.0,

			"image" : "twix_work/loginwindow/background.tga",
		},

		# Board
		{
			"name" : "board_main",
			"type" : "window",
					
			"x" : 0, 
			"y" : 0,
					
			"width" : 352, 
			"height" : 290,
					
			"vertical_align" : "center",
			"horizontal_align" : "center",
					
			"children" :
			(
				{
					"name" : "board",
					"type" : "image",
							
					"x" : 0, 
					"y" : 0,
					
					"vertical_align" : "center",
					"horizontal_align" : "center",
							
					"image" : "twix_work/loginwindow/board.tga",
							
					"children" : 
					(
						{
							"name" : "id_slotbar",
							"type" : "image",
									
							"x" : 0, 
							"y" : -39,
									
							"horizontal_align" : "center",
							"vertical_align" : "center",
									
							"image" : "twix_work/loginwindow/slotbar.tga",
									
							"children" : 
							(
								{
									"name" : "id",
									"type" : "editline",
											
									"x" : 12, 
									"y" : 10,
											
									"width" : 200, 
									"height" : 16,
											
									"color" : 0xffccb3ad,
									"input_limit": 16,
								},
							),
						},
						{
							"name" : "pwd_slotbar",
							"type" : "image",
									
							"x" : 0, 
							"y" : 7,
							
							"horizontal_align" : "center",
							"vertical_align" : "center",
									
							"image" : "twix_work/loginwindow/slotbar.tga",
									
							"children" : 
							(
								{
									"name" : "pwd",
									"type" : "editline",
											
									"x" : 12, 
									"y" : 10,
											
									"width" : 200, 
									"height" : 16,
											
									"color" : 0xffccb3ad,
									"input_limit": 16,
									"secret_flag": 1,
								},
							),
						},
						{
							"name" : "login_button",
							"type" : "button",

							"x" : -2, 
							"y" : 83,

							"horizontal_align" : "center",
							"vertical_align" : "center",

							"default_image" : "twix_work/loginwindow/button_0.tga", 
							"over_image" : "twix_work/loginwindow/button_1.tga",
							"down_image" : "twix_work/loginwindow/button_2.tga",

							"children" : 
							(
								{
									"name" : "login_text",
									"type" : "text",
											
									"x" : 26, 
									"y" : 7,
											
									"text" : uiScriptLocale.LOGIN_CONNECT,
									"color" : 0xffe8b478,
								},
							),
						},
						{
							"name" : "buttonExpand",
							"type" : "button",

							"x" : 88,
							"y" : 244,

							"default_image": "twix_work/loginwindow/btn_belt_open_01_normal.tga",
							"over_image": "twix_work/loginwindow/btn_belt_open_02_hover.tga",
							"down_image": "twix_work/loginwindow/btn_belt_open_03_active.tga",
						},
					),
				},
			),
		},
		{
			"name" : "changechannel",
			"type" : "expanded_image",
			
			"x" : 0,
			"y" : 155,

			"image": "twix_work/loginwindow/channel/board.tga",
			
			"horizontal_align" : "center",
			"vertical_align" : "center",

			"children" :
			(
				{
					"name" : "ch1",
					"type" : "radio_button",
					
					"x" : -41, 
					"y" : -30,
					
					"horizontal_align" : "center",
					"vertical_align" : "center",
					
					"default_image" : "twix_work/loginwindow/channel/button_0.tga",
					"over_image" : "twix_work/loginwindow/channel/button_1.tga",
					"down_image" : "twix_work/loginwindow/channel/button_2.tga",
					
					"children" : 
					(
						{
							"name" : "ch1_text",
							"type" : "text",
									
							"x" : 18, 
							"y" : 6,
									
							"text" : "Csatorna 1",
							"color" : 0xffe8b478,
						},
					),
				},
				{
					"name" : "ch2",
					"type" : "radio_button",
					
					"x" : -41, 
					"y" : -3,
					
					"horizontal_align" : "center",
					"vertical_align" : "center",
					
					"default_image" : "twix_work/loginwindow/channel/button_0.tga",
					"over_image" : "twix_work/loginwindow/channel/button_1.tga",
					"down_image" : "twix_work/loginwindow/channel/button_2.tga",

					"children" : 
					(
						{
							"name" : "ch2_text",
							"type" : "text",
									
							"x" : 18, 
							"y" : 6,
									
							"text" : "Csatorna 2",
							"color" : 0xffe8b478,
						},
					),
				},
				{
					"name" : "ch3",
					"type" : "radio_button",
					
					"x" : -41, 
					"y" : 24,
					
					"horizontal_align" : "center",
					"vertical_align" : "center",
					
					"default_image" : "twix_work/loginwindow/channel/button_0.tga",
					"over_image" : "twix_work/loginwindow/channel/button_1.tga",
					"down_image" : "twix_work/loginwindow/channel/button_2.tga",
					
					"children" : 
					(
						{
							"name" : "ch3_text",
							"type" : "text",
									
							"x" : 18, 
							"y" : 6,
									
							"text" : "Csatorna 3",
							"color" : 0xffe8b478,
						},
					),
				},
				{
					"name" : "ch4",
					"type" : "radio_button",
					
					"x" : 41, 
					"y" : -30,
					
					"horizontal_align" : "center",
					"vertical_align" : "center",
					
					"default_image" : "twix_work/loginwindow/channel/button_0.tga",
					"over_image" : "twix_work/loginwindow/channel/button_1.tga",
					"down_image" : "twix_work/loginwindow/channel/button_2.tga",
					
					"children" : 
					(
						{
							"name" : "ch4_text",
							"type" : "text",
									
							"x" : 18, 
							"y" : 6,
									
							"text" : "Csatorna 4",
							"color" : 0xffe8b478,
						},
					),
				},
				{
					"name" : "ch5",
					"type" : "radio_button",
					
					"x" : 41, 
					"y" : -3,
					
					"horizontal_align" : "center",
					"vertical_align" : "center",
					
					"default_image" : "twix_work/loginwindow/channel/button_0.tga",
					"over_image" : "twix_work/loginwindow/channel/button_1.tga",
					"down_image" : "twix_work/loginwindow/channel/button_2.tga",
					
					"children" : 
					(
						{
							"name" : "ch5_text",
							"type" : "text",
									
							"x" : 18, 
							"y" : 6,
									
							"text" : "Csatorna 5",
							"color" : 0xffe8b478,
						},
					),
				},
				{
					"name" : "ch6",
					"type" : "radio_button",
					
					"x" : 41, 
					"y" : 24,
					
					"horizontal_align" : "center",
					"vertical_align" : "center",
					
					"default_image" : "twix_work/loginwindow/channel/button_0.tga",
					"over_image" : "twix_work/loginwindow/channel/button_1.tga",
					"down_image" : "twix_work/loginwindow/channel/button_2.tga",
					
					"children" : 
					(
						{
							"name" : "ch6_text",
							"type" : "text",
									
							"x" : 18, 
							"y" : 6,
									
							"text" : "Csatorna 6",
							"color" : 0xffe8b478,
						},
					),
				},
				{
					"name" : "buttonMinimize",
					"type" : "button",

					"x" : 0,
					"y" : 47,
					
					"horizontal_align" : "center",
					"vertical_align" : "center",

					"default_image": "twix_work/loginwindow/btn_belt_close_01_normal.tga",
					"over_image": "twix_work/loginwindow/btn_belt_close_02_hover.tga",
					"down_image": "twix_work/loginwindow/btn_belt_close_03_active.tga",
				},
			),
		},	
		{
			"name" : "dog",
			"type" : "button",
							
			"x" :0, 
			"y" : 300,
							
			"horizontal_align" : "center",
			"vertical_align" : "center",
							
			"default_image" : "twix_work/loginwindow/dog1.tga", 
			"over_image" : "twix_work/loginwindow/dog2.tga",
			"down_image" : "twix_work/loginwindow/dog2.tga",
		},
		{
			"name" : "account_board",
			"type" : "image",
			
			"x" : 290,
			"y" : 0,

			"horizontal_align" : "right",
			"vertical_align" : "center",

			"image" : "twix_work/loginwindow/account/board.tga",

			"children" :
			(
				{
					"name" : "account_0_image",
					"type" : "image",
					
					"x" : 28, 
					"y" : 24,
					
					"image" : "twix_work/loginwindow/slotbar.tga",
					
					"children" : 
					(
						{
							"name" : "account_0_text",
							"type" : "text",

							"x" : 0, 
							"y" : -1,

							"color" : 0xffccb3ad,
							"all_align" : True,
						},
					),
				},
				{
					"name" : "delete_button_0",
					"type" : "button",
					
					"x" : 260, 
					"y" : 27,
					
					"default_image" : "twix_work/loginwindow/account/delete_0.tga",
					"over_image" :  "twix_work/loginwindow/account/delete_1.tga",
					"down_image" : "twix_work/loginwindow/account/delete_2.tga",
				},
				{
					"name" : "save_button_0",
					"type" : "button",
					
					"x" : 260, 
					"y" : 27,
					
					"default_image" : "twix_work/loginwindow/account/save_0.tga",
					"over_image" :  "twix_work/loginwindow/account/save_1.tga",
					"down_image" : "twix_work/loginwindow/account/save_2.tga",
				},
				{
					"name" : "load_button_0",
					"type" : "button",
					
					"x" : 150, 
					"y" : 26,
					
					"default_image" : "twix_work/loginwindow/button_0.tga",
					"over_image" :  "twix_work/loginwindow/button_1.tga",
					"down_image" : "twix_work/loginwindow/button_2.tga",
					
					"children" : 
					(
						{
							"name" : "load_text",
							"type" : "text",

							"x" : 36, 
							"y" : 7,

							"text" : uiScriptLocale.LOGIN_ACCOUNT_LOAD,
							"color" : 0xffe8b478,
						},
					),
				},
				{
					"name" : "account_1_image",
					"type" : "image",
					"x" : 28, "y" : 74,
					"image" : "twix_work/loginwindow/slotbar.tga",
					"children" : 
					(
						{
							"name" : "account_1_text",
							"type" : "text",
							
							"x" : 0, 
							"y" : -1,
							
							"color" : 0xffccb3ad,
							"all_align" : True,
						},
					),
				},
				{
					"name" : "delete_button_1",
					"type" : "button",
					
					"x" : 260, 
					"y" : 77,
					
					"default_image" : "twix_work/loginwindow/account/delete_0.tga",
					"over_image" :  "twix_work/loginwindow/account/delete_1.tga",
					"down_image" : "twix_work/loginwindow/account/delete_2.tga",
				},
				{
					"name" : "save_button_1",
					"type" : "button",
					
					"x" : 260, 
					"y" : 77,
					
					"default_image" : "twix_work/loginwindow/account/save_0.tga",
					"over_image" :  "twix_work/loginwindow/account/save_1.tga",
					"down_image" : "twix_work/loginwindow/account/save_2.tga",
				},
				{
					"name" : "load_button_1",
					"type" : "button",
					
					"x" : 150, 
					"y" : 76,
					
					"default_image" : "twix_work/loginwindow/button_0.tga",
					"over_image" :  "twix_work/loginwindow/button_1.tga",
					"down_image" : "twix_work/loginwindow/button_2.tga",
					
					"children" : 
					(
						{
							"name" : "load_text",
							"type" : "text",

							"x" : 36, 
							"y" : 7,

							"text" : uiScriptLocale.LOGIN_ACCOUNT_LOAD,
							"color" : 0xffe8b478,
						},
					),
				},
				{
					"name" : "account_2_image",
					"type" : "image",
					"x" : 28, "y" : 124,
					"image" : "twix_work/loginwindow/slotbar.tga",
					"children" : 
					(
						{
							"name" : "account_2_text",
							"type" : "text",
							
							"x" : 0, 
							"y" : -1,
							
							"color" : 0xffccb3ad,
							"all_align" : True,
						},
					),
				},
				{
					"name" : "delete_button_2",
					"type" : "button",
					
					"x" : 260, 
					"y" : 126,
					
					"default_image" : "twix_work/loginwindow/account/delete_0.tga",
					"over_image" :  "twix_work/loginwindow/account/delete_1.tga",
					"down_image" : "twix_work/loginwindow/account/delete_2.tga",
				},
				{
					"name" : "save_button_2",
					"type" : "button",
					
					"x" : 260, 
					"y" : 126,
					
					"default_image" : "twix_work/loginwindow/account/save_0.tga",
					"over_image" :  "twix_work/loginwindow/account/save_1.tga",
					"down_image" : "twix_work/loginwindow/account/save_2.tga",
				},
				{
					"name" : "load_button_2",
					"type" : "button",
					
					"x" : 150, 
					"y" : 125,
					
					"default_image" : "twix_work/loginwindow/button_0.tga",
					"over_image" :  "twix_work/loginwindow/button_1.tga",
					"down_image" : "twix_work/loginwindow/button_2.tga",
					
					"children" : 
					(
						{
							"name" : "load_text",
							"type" : "text",

							"x" : 36, 
							"y" : 7,

							"text" : uiScriptLocale.LOGIN_ACCOUNT_LOAD,
							"color" : 0xffe8b478,
						},
					),
				},
				{
					"name" : "account_3_image",
					"type" : "image",
					"x" : 28, "y" : 174,
					"image" : "twix_work/loginwindow/slotbar.tga",
					"children" : 
					(
						{
							"name" : "account_3_text",
							"type" : "text",
							
							"x" : 0, 
							"y" : -1,
							
							"color" : 0xffccb3ad,
							"all_align" : True,
						},
					),
				},
				{
					"name" : "delete_button_3",
					"type" : "button",
					
					"x" : 260, 
					"y" : 177,
					
					"default_image" : "twix_work/loginwindow/account/delete_0.tga",
					"over_image" :  "twix_work/loginwindow/account/delete_1.tga",
					"down_image" : "twix_work/loginwindow/account/delete_2.tga",
				},
				{
					"name" : "save_button_3",
					"type" : "button",
					
					"x" : 260, 
					"y" : 177,
					
					"default_image" : "twix_work/loginwindow/account/save_0.tga",
					"over_image" :  "twix_work/loginwindow/account/save_1.tga",
					"down_image" : "twix_work/loginwindow/account/save_2.tga",
				},
				{
					"name" : "load_button_3",
					"type" : "button",
					
					"x" : 150, 
					"y" : 176,
					
					"default_image" : "twix_work/loginwindow/button_0.tga",
					"over_image" :  "twix_work/loginwindow/button_1.tga",
					"down_image" : "twix_work/loginwindow/button_2.tga",
					
					"children" : 
					(
						{
							"name" : "load_text",
							"type" : "text",

							"x" : 36, 
							"y" : 7,

							"text" : uiScriptLocale.LOGIN_ACCOUNT_LOAD,
							"color" : 0xffe8b478,
						},
					),
				},
			),
		},
		{
			"name" : "exit_button",
			"type" : "button",
				
			"x" : SCREEN_WIDTH - 110, 
			"y" : 10,
					
			"default_image" : "twix_work/loginwindow/button_0.tga",
			"over_image" :  "twix_work/loginwindow/button_1.tga",
			"down_image" : "twix_work/loginwindow/button_2.tga",

			"children" : 
			(
				{
					"name" : "exit_text",
					"type" : "text",

					"x" : 36, 
					"y" : 7,

					"text" : uiScriptLocale.LOGIN_EXIT,
					"color" : 0xffe8b478,
				},
			),
		},
	),
}

Dans le fichier ci-dessus vous pouvez voir :  uiScriptLocale.LOGIN_ACCOUNT_LOAD,

 

Ce qui correspond à mon syserr :

1005 17:46:01297 :: Failed to load script file : twix_work/loginwindow/loginwindow.py
1005 17:46:01298 :: 
ui.py(line:5523) LoadScriptFile
system.py(line:192) execfile
system.py(line:163) Run
twix_work/loginwindow/loginwindow.py(line:453) <module>

LoadScriptFile!!!!!!!!!!!!!! - <type 'exceptions.AttributeError'>:'module' object has no attribute 'LOGIN_ACCOUNT_LOAD'

1005 17:46:01298 :: ============================================================================================================
1005 17:46:01298 :: Abort!!!!

1005 17:46:01299 :: 
introLogin.py(line:139) __LoadScript
ui.py(line:5540) LoadScriptFile
exception.py(line:36) Abort

LoginWindow.__LoadScript.LoadObject - <type 'exceptions.SystemExit'>:

1005 17:46:01299 :: ============================================================================================================
1005 17:46:01299 :: Abort!!!!

Une idée concernant mon souci ?
 

J'ai placé le dossier TWIX_WORK dans le pack ETC comme ceci :

d:/twix_work/loginwindow/
ETC
d:/twix_work/characterwindow/
ETC
d:/twix_work/selectempirewindow/
ETC

Merci de votre aide !

Link to comment

Recommended Posts

  • 0

Hey, à vu de nez ça ressemble à un système complètement personnalisé, sans tutoriel d'installation ça va être difficile de le reproduire :/

 

Pour ton erreur de Locale, je pense que c'est un problème de texte de traduction qui n'existe pas. 

  • J'adore 1
Link to comment
  • 0

Non je n'arrive a rien , c'est bien domage car il s'agit du design "illumina" que je trouve tres joli .

lorsque j'arrive a éliminer une erreur une autre survient , je n'en peux plus 😃

 

Je voudrais bien partager un design fonctionnel , de plus Illumina ne ce trouve pas sur Funky-emu ..

 

Illumina    lien hs

Edited by Jinzo
Link to comment
  • 0

Apres quelques recherches et modifications je suis parvenu a lancé la page de connexion , hors je me heurte a ce problème :

self.CheckAccount()




def CheckAccount(self):
		for i in xrange(4):
			if get_reg("id_%d" % i):
				self.accountData[i][1].SetText(str(get_reg("id_%d" % i)))
				self.accountData[i][0][1].Hide()
				self.accountData[i][0][0].Show()
			else:
				self.accountData[i][1].SetText(uiScriptLocale.LOGIN_ACCOUNT_EMPTY)
				self.accountData[i][0][1].Show()
				self.accountData[i][0][0].Hide()

Il semblerai que cette fonction , vérifie si les identifiant entrés correspondent a un compte , comportant des personnages .

le soucis c'est que je ne détermine pas ou ce trouve la valeur par défaut sur le fichier original intrologin.py afin de pouvoir modifier le .py de l'interface.

 

EDIT :

 

En supprimant le code ci-dessus j'arrive a la page de connexion , mais voila après avoir rentré mes id de connexion , je me vois arrivé sur un echec de connexion :

def SetChannel(self, ch):
		for key, button in self.channelButton.items():
			button.SetUp()
			
		self.channelButton[ch].Down()

		self.stream.SetConnectInfo(g_ip, self.ChannelPort(ch, 0), g_ip, self.ChannelPort("LOGIN"))
		net.SetMarkServer(g_ip, self.ChannelPort("LOGO"))
		app.SetGuildMarkPath("10.tga")
		app.SetGuildSymbolPath("10")
		net.SetServerInfo(self.ChannelPort(ch, 2))
		
	def ChannelPort(self, ch, value=0):
		channel = {

			0	:	13001,
			1	:	37001,
			2	:	37002,
			3	:	37003,
			4	:	37004,
			5	:	37005}
		
		if ch == "LOGIN":
			return 11002
		elif ch == "LOGO":
			return channel[0]
		elif value == 2:
			return "TWIX Work, Channel %s" % (ch+1)
		else:
			return channel[ch]

Je ne comprend pas ....

Edited by Jinzo
Link to comment
  • 0

Problème de connexion résolu, j'avais mal rempli le champs : g_ip = "192.168.56.101"

 

Je poursuis les tests

 

Peut on m'expliquer ce code , j'ai l'impression qu'il s'agit d'une table BDD que je ne possède pas .

REG_PATH = r"SOFTWARE\TWIX Work"

def set_reg(name, value):
	try:
		_winreg.CreateKey(_winreg.HKEY_CURRENT_USER, REG_PATH)
		registry_key = _winreg.OpenKey(_winreg.HKEY_CURRENT_USER, REG_PATH, 0, _winreg.KEY_WRITE)
		_winreg.SetValueEx(registry_key, name, 0, _winreg.REG_SZ, value)
		_winreg.CloseKey(registry_key)
		return True
	except WindowsError:
		return False

def get_reg(name):
	try:
		registry_key = _winreg.OpenKey(_winreg.HKEY_CURRENT_USER, REG_PATH, 0, _winreg.KEY_READ)
		value, regtype = _winreg.QueryValueEx(registry_key, name)
		_winreg.CloseKey(registry_key)
		return str(value)
	except WindowsError:
		return None

 

Edited by Jinzo
Link to comment
  • 0
  • Développeur
il y a 56 minutes, Jinzo a dit :

Problème de connexion résolu, j'avais mal rempli le champs : g_ip = "192.168.56.101"

 

Je poursuis les tests

 

Peut on m'expliquer ce code , j'ai l'impression qu'il s'agit d'une table BDD que je ne possède pas .

REG_PATH = r"SOFTWARE\TWIX Work"

def set_reg(name, value):
	try:
		_winreg.CreateKey(_winreg.HKEY_CURRENT_USER, REG_PATH)
		registry_key = _winreg.OpenKey(_winreg.HKEY_CURRENT_USER, REG_PATH, 0, _winreg.KEY_WRITE)
		_winreg.SetValueEx(registry_key, name, 0, _winreg.REG_SZ, value)
		_winreg.CloseKey(registry_key)
		return True
	except WindowsError:
		return False

def get_reg(name):
	try:
		registry_key = _winreg.OpenKey(_winreg.HKEY_CURRENT_USER, REG_PATH, 0, _winreg.KEY_READ)
		value, regtype = _winreg.QueryValueEx(registry_key, name)
		_winreg.CloseKey(registry_key)
		return str(value)
	except WindowsError:
		return None

 

 

Non il insère juste le PATH "SOFTWARE\TWIX Work" dans ton registre. J'vois pas trop l'intérêt, mais si ton truc utilise le PATH alors tu devrais le laisser.

M'est avis que ça ne présage rien de bon.

  • J'adore 1
Link to comment
  • 0

Ok donc a mon avis il utilise ca pour garder en memoire les perso que tu peux connecter !

Et il te les remet via ceci :

def CheckAccount(self):
		for i in xrange(4):
			if get_reg("id_%d" % i):
				self.accountData[i][1].SetText(str(get_reg("id_%d" % i)))
				self.accountData[i][0][1].Hide()
				self.accountData[i][0][0].Show()
			else:
				self.accountData[i][1].SetText(uiScriptLocale.LOGIN_ACCOUNT_EMPTY)
				self.accountData[i][0][1].Show()
				self.accountData[i][0][0].Hide()
				
	def DeleteAccount(self, key):
		if get_reg("id_%d" % key):
			set_reg("id_%d" % key, "")
			set_reg("pwd_%d" % key, "")
			self.PopupNotifyMessage(uiScriptLocale.LOGIN_ACCOUNT_DELETE)
		else:
			self.PopupNotifyMessage(uiScriptLocale.LOGIN_ACCOUNT_D_S)
			
		#self.CheckAccount()
		
	def LoadAccount(self, key):
		if get_reg("id_%d" % key):
			self.idEditLine.SetText(str(get_reg("id_%d" % key)))
			self.pwdEditLine.SetText(str(get_reg("pwd_%d" % key)))
			self.pwdEditLine.SetFocus()
		else:
			self.PopupNotifyMessage(uiScriptLocale.LOGIN_ACCOUNT_N_S)
			
	def SaveAccount(self, key):
		if get_reg("id_%d" % key):
			self.PopupNotifyMessage(uiScriptLocale.LOGIN_ACCOUNT_N_S_D)
			return
		
		if self.idEditLine.GetText() == "" or self.pwdEditLine.GetText() == "":
			self.PopupNotifyMessage(uiScriptLocale.LOGIN_ACCOUNT_SAVE)
			return
		
		set_reg("id_%d" % key, self.idEditLine.GetText())
		set_reg("pwd_%d" % key, self.pwdEditLine.GetText())
		self.PopupNotifyMessage(uiScriptLocale.LOGIN_ACCOUNT_SAVED)

 

Link to comment
  • 0

Je viens au nouvelles comme vous le constaterez j'ai bien évoluer :

[spolier]

181013032423551032.png

 

181013033312352266.png

 

181013032142991741.png

 

181013032356832732.png

 

181013032628767988.png

 

181013032647718193.png

 

181013032932721906.png

 

181013032905579247.png

 

181013033026926344.png

 

181013033142460425.png

 

181013033222215742.png

[/spolier]

Mais voila a chaque fois que je veux changer de perso , déconnecter ou même fermer le jeu voici :

[spolier]

181013032123101887.png

[/spolier]

1013 14:50:58648 :: CEffectManager::RegisterEffect - LoadScript(D:/ymir work/pc/fekete.mse) Error
1013 14:50:58648 :: CInstanceBase::RegisterEffect(eEftType=268, c_szEftAttachBone=Bip01, c_szEftName=D:/ymir work/pc/fekete.mse, isCache=0) - Error
1013 14:59:37363 :: Traceback (most recent call last):

1013 14:59:37363 ::   File "uiTaskBar.py", line 968, in OnUpdate

1013 14:59:37363 ::   File "uiTaskBar.py", line 712, in SetMp

1013 14:59:37363 :: IndexError
1013 14:59:37395 :: : 
1013 14:59:37395 :: list index out of range
1013 14:59:37395 ::

Mon uiTaskBar.py

 

705		def SetMp(self, _actual, _recovery, _max):
706				max_show = 76 -int(76.0 * float(_actual)/ float(_max))
707				max_rec =  76 -int(76.0 * float(_recovery)/ float(_max))
708				for i in xrange(0,77):
709					self.MpFull[i].Hide()
710					self.MpRefresh[i].Hide()
711				self.MpRefresh[max_rec].Show()
712				self.MpFull[max_show].Show()



957		def OnUpdate(self):
958				self.text[0].SetText(str(player.GetStatus(player.HP)))
959				self.text[1].SetText(str(player.GetStatus(player.SP)))
960				
961				curHP = player.GetStatus(player.HP)
962				maxHP = player.GetStatus(player.MAX_HP)
963				curSP = player.GetStatus(player.SP)
964				maxSP = player.GetStatus(player.MAX_SP)
965				recoveryHP = player.GetStatus(player.HP_RECOVERY)
966				recoverySP = player.GetStatus(player.SP_RECOVERY)
967				self.SetHp(curHP, recoveryHP, maxHP)
968				self.SetMp(curSP, recoverySP, maxSP)

 

Edited by Jinzo
Link to comment
  • 0
  • Développeur

Y'a une des deux listes MpFull ou MpRefresh qui ne possèdent pas tous les éléments que tu cherches à accéder.

Si ta liste possède 50 éléments et que tu veux accéder au 57ème, il va planter et te renvoyer l'erreur que tu as eue.

 

Pour résumer: c'est quoi MpFull et MpRefresh ?

  • J'adore 1
Link to comment
  • 0
self.MpFull = []
		for i in xrange(0,77):
			part = ExpandedImageBox()
			part.AddFlag("not_pick")
			s = str(i)
			if(i < 10):
				s = "0"+s
			part.LoadImage("d:/ymir work/interface/taskbar/gauge_mp/gauge_mp_fill_"+ s+".tga")
			part.SetParent(self.TaskBarLeft.GetChild("Window1"))
			part.SetPosition(30, 95)
			part.Show()
			self.MpFull.append(part)
            
            
            
self.MpRefresh = []
		for i in xrange(0,77):
			part = ExpandedImageBox()
			part.AddFlag("not_pick")
			s = str(i)
			if(i < 10):
				s = "0"+s
			part.LoadImage("d:/ymir work/interface/taskbar/gauge_mp/gauge_mp_fill_"+ s+".tga")
			part.SetParent(self.TaskBarLeft.GetChild("Window1"))
			part.SetPosition(30, 95)
			part.SetAlpha(0.3)
			part.Hide()
			self.MpRefresh.append(part)

C'est tous ce que je possède en info ....

Link to comment
  • 0
  • Développeur

C'est ce que je recherchais, mais on ne dirait pas vraiment qu'il y a un problème avec ces deux listes.

 

Comme l'indique ton syserr, c'est la ligne 712 qui fait planter, m'est avis que ta variable max_show ne soit pas tout à fait correcte.

Peut-être que dans le cas où tu aurais plus d'HPs que de HP max (disons 50206 HP sur 25103 au total), ton max_show vaudrait -76... Ce qui

cause un out of range exception.

 

En fait, ce qu'ils (par ils j'entends les créateurs du design) n'ont pas pensé, c'est qu'on pouvait pour X raison avoir plus d'HP que d'HP Max
(avec une commande GM par exemple ;) ). Du coup dans ce cas précis (ou en cas de bug), le client cherche à accéder à la case -76...
Qui n'existe pas, en fait. Et accéder à une case qui n'existe pas crée un "list index out of range".

 

Change la fonction comme qui suit:

def SetMp(self, _actual, _recovery, _max):
	max_show = 76 -int(76.0 * float(_actual)/ float(_max))
	max_rec =  76 -int(76.0 * float(_recovery)/ float(_max))
	
	## Si max_show ou max_rec n'est pas compris entre 0 et 76
	## On corrige le dépassement pour éviter tout out of range
	max_show = 76 if max_show > 76 else max_show
	max_show = 0 if max_show < 0 else max_show
	max_rec = 76 if max_rec > 76 else max_rec
	max_rec = 0 if max_rec < 0 else max_rec
	
	for i in xrange(0,77):
		self.MpFull[i].Hide()
		self.MpRefresh[i].Hide()
	self.MpRefresh[max_rec].Show()
	self.MpFull[max_show].Show()

 

Edited by Kameyu
  • J'adore 1
Link to comment
  • 0

crash avant , comme je l'avait indiquer dans mon message comportant les screans 😃

 

EDIT:

 

Il semblerai que le soucis soit résolu, j'ai modifier le mode de compatibilité du lanceur , je suis passer de Windows 8.1 a Windows 8 , je ne voit pas trop la différence , mais vu que je n'ai toucher a rien d'autre ....

 

J'ai encore 2 ou 3 petit truc a corriger niveau des traduction et placement d'information, je pense que le sujet peu être placer en résolu , dans le pire des cas je ré-ouvrirai le topic , merci encore a toutes celle et tout ceux qui mon aiguillé  .

 

EDIT de mon EDIT :

 

Voici ce que je trouve dans mon Syserr :

1015 10:37:32031 :: Traceback (most recent call last):

1015 10:37:32031 ::   File "uiCharacter.py", line 1964, in OnUpdate

1015 10:37:32032 ::   File "ui.py", line 121, in __call__

1015 10:37:32032 ::   File "ui.py", line 103, in __call__

1015 10:37:32032 ::   File "uiCharacter.py", line 888, in Refreshing

1015 10:37:32032 ::   File "ui.py", line 5464, in GetChild

1015 10:37:32033 :: KeyError
1015 10:37:32033 :: : 
1015 10:37:32033 :: 'PercentExp'
1015 10:37:32033 :: 

Ce que je ne comprend pas , c'est que j'ai bien la fonction affichée IG :

 

181015114056186537.png

 

Voici les informations relative de mon fichier ui.py :

 

class ScriptWindow(Window):
	def __init__(self, layer = "UI"):
		Window.__init__(self, layer)
		self.Children = []
		self.ElementDictionary = {}
	def __del__(self):
		Window.__del__(self)

	def ClearDictionary(self):
		self.Children = []
		self.ElementDictionary = {}
	def InsertChild(self, name, child):
		self.ElementDictionary[name] = child

	def IsChild(self, name):
		return self.ElementDictionary.has_key(name)
	def GetChild(self, name):
		return self.ElementDictionary[name]

	def GetChild2(self, name):
		return self.ElementDictionary.get(name, None)

Et voici les informations de mon fichier characterewindow.ps :

 

 

import uiScriptLocale

QUEST_ICON_BACKGROUND = 'd:/ymir work/ui/game/quest/slot_base.sub'

SMALL_VALUE_FILE = "d:/ymir work/ui/public/Parameter_Slot_00.sub"
MIDDLE_VALUE_FILE = "d:/ymir work/ui/public/Parameter_Slot_01.sub"
LARGE_VALUE_FILE = "d:/ymir work/ui/public/Parameter_Slot_03.sub"
ICON_SLOT_FILE = "d:/ymir work/ui/public/Slot_Base.sub"
FACE_SLOT_FILE = "d:/ymir work/ui/game/windows/box_face.sub"
ROOT_PATH = "d:/ymir work/ui/game/windows/"

LOCALE_PATH = uiScriptLocale.WINDOWS_PATH

window = {
	"name" : "CharacterWindow",
	"style" : ("movable", "float",),

	"x" : 224,
	"y" : (SCREEN_HEIGHT - 37 - 461) / 2,

	"width" : 340,
	"height" : 393,

	"children" :
	(
		{
			"name" : "board",
			"type" : "board2",
			"style" : ("attach",),

			"x" : 0,
			"y" : 0,

			"width" : 340,
			"height" : 393,

			"children" :
			(
				{
					"name":"TabButtonsBoard",
					"type":"new_board",
					"x" : 285,
					"y" : 35,
					"width" : 45,
					"height" : 350,
					"children" :
					(
						## RadioButton
						{
							"name" : "Tab_Button_01",
							"type" : "button",

							"x" : 8,
							"y" : 9,

							"default_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",
							"over_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",
							"down_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",

							"children":
							(
								{"name" : "Button1_Name","type":"text","text":"|cfff8d090"+uiScriptLocale.CHARACTER_MAIN,"x":35,"y":8,},
							)
						},
						{
							"name" : "Tab_Button_02",
							"type" : "button",

							"x" : 8,
							"y" : 40,

							"default_image":"d:/ymir work/interface/expand_system/chrbutton_small_n.tga",
							"over_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",
							"down_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",

							"children":
							(
								{"name" : "Button2_Name","type":"text","text":uiScriptLocale.CHARACTER_STATS,"x":35,"y":8,},
							)
						},
						{
							"name" : "Tab_Button_03",
							"type" : "button",

							"x" : 8,
							"y" : 71,

							"default_image":"d:/ymir work/interface/expand_system/chrbutton_small_n.tga",
							"over_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",
							"down_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",

							"children":
							(
								{"name" : "Button3_Name","type":"text","text":uiScriptLocale.CHARACTER_BONUS,"x":35,"y":8,},
							)
						},
						{
							"name" : "Tab_Button_04",
							"type" : "button",
							"x" : 8,
							"y" : 102,
							"default_image":"d:/ymir work/interface/expand_system/chrbutton_small_n.tga",
							"over_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",
							"down_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",
							"children":
							(
								{"name" : "Button4_Name","type":"text","text":uiScriptLocale.CHARACTER_SKILL,"x":35,"y":8,},
							)
						},
						{
							"name" : "Tab_Button_05",
							"type" : "button",
							"x" : 8,
							"y" : 133,
							"default_image":"d:/ymir work/interface/expand_system/chrbutton_small_n.tga",
							"over_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",
							"down_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",
							"children":
							(
								{"name" : "Button5_Name","type":"text","text":uiScriptLocale.CHARACTER_ACTION,"x":35,"y":8,},
							),
						},
						{
							"name" : "Tab_Button_06",
							"type" : "button",
							"x" : 8,
							"y" : 133+31,
							"default_image":"d:/ymir work/interface/expand_system/chrbutton_small_n.tga",
							"over_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",
							"down_image":"d:/ymir work/interface/expand_system/chrbutton_small_a.tga",
							"children":
							(
								{"name" : "Button6_Name","type":"text","text":uiScriptLocale.CHARACTER_QUEST,"x":35,"y":8,},
							),
						},
					),
				},
				{
					"name" : "Skill_TitleBar","type" : "titlebar","style" : ("attach",),"x" : 8,"y" : 5,"width" : 325,"color" : "red",

				},
				{
					"name" : "Emoticon_TitleBar","type" : "titlebar","style" : ("attach",),"x" : 8,"y" : 5,"width" : 325,"color" : "red",

				},
				{
					"name" : "Quest_TitleBar","type" : "titlebar","style" : ("attach",),"x" : 8,"y" : 5,"width" : 325,"color" : "red",

				},
				{
					"name":"Stats_TitleBar","type":"titlebar","style":("attach",),"x":8,"y":5,"width":325,"color":"red",

				},
				{
					"name":"Character_TitleBar","type":"titlebar","style":("attach",),"x":8,"y":5,"width":325,"color":"red",

				},
				{
					"name":"Bonus_TitleBar","type":"titlebar","style":("attach",),"x":8,"y":5,"width":325,"color":"red",

				},
				{"name":"TitleName", "type":"text", "x":0,"y":12-192, "text":uiScriptLocale.CHARACTER_MAIN, "all_align":"center" },
				{"name":"Expand", "type":"button", "x":325-70,"y":10, "default_image":"d:/ymir work/interface/expand_system/expand_n.tga", "over_image":"d:/ymir work/interface/expand_system/expand_h.tga", "down_image":"d:/ymir work/interface/expand_system/expand_a.tga","tooltip_text":"Kinyit",},
				{"name":"Minimize", "type":"button", "x":325-70,"y":10, "default_image":"d:/ymir work/interface/expand_system/minimize_n.tga", "over_image":"d:/ymir work/interface/expand_system/minimize_h.tga", "down_image":"d:/ymir work/interface/expand_system/minimize_a.tga","tooltip_text":"Bezár",},

				{
					"name" : "TopBoard",
					"type" : "new_board",

					"x" : 10,
					"y" : 35,

					"width" : 275,
					"height" : 75,

					"children":
					(
						{
							"name":"ChrIconSlot",
							"type":"expanded_image",
							"x":-28,
							"y":-46,
							"image":"d:/ymir work/interface/character/character_slot.tga",
							"children":
							(
								{"name":"ChrIcon","type":"expanded_image","x":3,"y":-16,"image":"d:/ymir work/interface/faces/icon_mwarrior.tga","x_scale":0.9,"y_scale":0.9,},
							)
						},

						{
							"name" : "NameSlot",
							"type" : "image",
							"x" : 66,
							"y" : 12,
							"image" : "d:/ymir work/interface/chenare/chenar1.tga",

							"children" :
							(
								{"name" : "NazwaGracza","type":"text","text":"|cffa07970Char Name","x":0,"y":0,"all_align" : "center",},
							),
						},


						{
							"name" : "GuildSlot",
							"type" : "image",
							"x" : 166,
							"y" : 12,
							"image" : "d:/ymir work/interface/chenare/chenar1.tga",

							"children" :
							(
								{"name" : "NazwaGildii","type":"text","text":"|cffa07970Guild Name","x":0,"y":0,"all_align" : "center",},
							),
						},

						{
							"name":"LevelSlot",
							"type":"image",
							"x":25,
							"y":5,
							"image":"d:/ymir work/interface/character/level_round.tga",
							"children":
							(
								{"name":"LevelText","type":"text","text":"|cfff8d09099","x":0,"y":-1,"all_align":"center",},
							),
						},

						{
							"name":"PercentExp",
							"type":"text",
							
							"text":"100.00%", 
							"color" : 0xfff8d090, 
							
							"x":25,
							"y":40,
						},

						{
							"name":"PlayerExp",
							"type":"text",
							
							"text":"EXP:",
							"color" : 0xffa08784,
							
							"x":75,
							"y":40,
						},
						{
							"name":"NextLvlExp",
							"type":"text",
							
							"text":"0",
							"color" : 0xffa08784,
							
							"x":160,
							"y":40,
						},

						{
							"name":"ExpImgEmpty",
							"type":"image",
							"x":15,
							"y":50,
							"image":"d:/ymir work/interface/character/exp_gauge_empty.tga",
						},

						{
							"name":"ExpImgFull",
							"type":"expanded_image",
							"x":15,
							"y":50,
							"image":"d:/ymir work/interface/character/exp_gauge_full.tga",
						},

					),
				},


				## Page Area
				{
					"name" : "Character_Page",
					"type" : "window",
					"style" : ("attach",),

					"x" : 10,
					"y" : 110,

					"width" : 280,
					"height" : 280,

					"children" :
					(
						{
							"name":"CharWindow1",
							"type":"new_board",
							"width" : 275,
							"height":100,
							"x":0,
							"y":0,
							"children":
							(
								{"name":"Header1Text","type":"text","text":uiScriptLocale.CHARACTER_STATUS,"color" : 0xfff8d090,"x":2,"y":-32,"all_align":"center",},
								{
									"name":"HeaderWnd1",
									"type":"image",
									"x":35,
									"y":5,
									"image":"d:/ymir work/interface/horizontal_bar/center.tga",
									"all_align":"center",
								},
								{"name":"TextHP","type":"text","text":uiScriptLocale.CHARACTER_HP,  "color" : 0xffa08784,"x":50,"y":45,},
								{
									"name":"BgHP",
									"type":"expanded_image",
									"x":140,
									"y":43,
									"image":"d:/ymir work/interface/chenare/chenar1.tga",
									"x_scale":1.0,
									"y_scale":0.8,
									"children":
									(
										{
											"name":"PlayerHpText",
											"type":"text",
											"text":"|cffa079709999/9999",
											"x":0,
											"y":0,
											"all_align":"center",
										},
									),
								},
								{"name":"TextPE","type":"text","text":uiScriptLocale.CHARACTER_SP,  "color" : 0xffa08784,"x":50,"y":70,},
								{
									"name":"BgPE",
									"type":"expanded_image",
									"x":140,
									"y":70,
									"image":"d:/ymir work/interface/chenare/chenar1.tga",
									"x_scale":1.0,
									"y_scale":0.8,
									"children":
									(
										{
											"name":"PlayerPeText",
											"type":"text",
											"text":"|cffa079709999/9999",
											"x":0,
											"y":0,
											"all_align":"center",
										},
									),
								},
							),
						},

						{
							"name":"CharWindow2",
							"type":"new_board",
							"width":275,
							"height":175,
							"x":0,
							"y":100,
							"children":
							(
								{"name":"StatusPoints","type":"text","text":"|cffa08784"+uiScriptLocale.CHARACTER_PSTATUS+"[|cfff8d09010|cffa08784]","x":0,"y":-65,"all_align":"center",},
								{"name":"WitText","type":"text","text":uiScriptLocale.CHARACTER_VIT, "color" : 0xffa08784,"x":50,"y":50,},
								{"name":"IntText","type":"text","text":uiScriptLocale.CHARACTER_INT, "color" : 0xffa08784,"x":50,"y":75,},
								{"name":"StrText","type":"text","text":uiScriptLocale.CHARACTER_STR, "color" : 0xffa08784,"x":50,"y":100,},
								{"name":"ZreText","type":"text","text":uiScriptLocale.CHARACTER_DEX, "color" : 0xffa08784,"x":50,"y":125,},


								{
									"name":"WitalnoscBg",
									"type":"expanded_image",
									"x":160,
									"y":48,
									"image":"d:/ymir work/interface/chenare/chenar1_small_s.tga",
									"x_scale":1.0,
									"y_scale":0.8,
									"children":
									(
										{"name":"WitPointsText","type":"text","text":"|cffa07970125","x":0,"y":0,"all_align":"center",},
									),
								},
								{
									"name":"InteligencjaBg",
									"type":"expanded_image",
									"x":160,
									"y":73,
									"image":"d:/ymir work/interface/chenare/chenar1_small_s.tga",
									"x_scale":1.0,
									"y_scale":0.8,
									"children":
									(
										{"name":"IntPointsText","type":"text","text":"|cffa07970125","x":0,"y":0,"all_align":"center",},
									),
								},
								{
									"name":"SilaBg",
									"type":"expanded_image",
									"x":160,
									"y":98,
									"image":"d:/ymir work/interface/chenare/chenar1_small_s.tga",
									"x_scale":1.0,
									"y_scale":0.8,
									"children":
									(
										{"name":"StrPointsText","type":"text","text":"|cffa07970125","x":0,"y":0,"all_align":"center",},
									),
								},
								{
									"name":"ZrecznoscBg",
									"type":"expanded_image",
									"x":160,
									"y":123,
									"image":"d:/ymir work/interface/chenare/chenar1_small_s.tga",
									"x_scale":1.0,
									"y_scale":0.8,
									"children":
									(
										{"name":"ZrePointsText","type":"text","text":"|cffa07970125","x":0,"y":0,"all_align":"center",},
									),
								},


								{ "name":"HTH_Plus", "type" : "button", "x":217, "y":48+2, "default_image" : "d:/ymir work/interface/character/buttons/plus_01_normal.tga", "over_image" : "d:/ymir work/interface/character/buttons/plus_02_hover.tga", "down_image" : "d:/ymir work/interface/character/buttons/plus_03_active.tga", },
								{ "name":"INT_Plus", "type" : "button", "x" : 217, "y":73+2, "default_image" : "d:/ymir work/interface/character/buttons/plus_01_normal.tga", "over_image" : "d:/ymir work/interface/character/buttons/plus_02_hover.tga", "down_image" : "d:/ymir work/interface/character/buttons/plus_03_active.tga", },
								{ "name":"STR_Plus", "type" : "button", "x" : 217, "y":98+2, "default_image" : "d:/ymir work/interface/character/buttons/plus_01_normal.tga", "over_image" : "d:/ymir work/interface/character/buttons/plus_02_hover.tga", "down_image" : "d:/ymir work/interface/character/buttons/plus_03_active.tga", },
								{ "name":"DEX_Plus", "type" : "button", "x" : 217, "y":123+2, "default_image" : "d:/ymir work/interface/character/buttons/plus_01_normal.tga", "over_image" : "d:/ymir work/interface/character/buttons/plus_02_hover.tga", "down_image" : "d:/ymir work/interface/character/buttons/plus_03_active.tga", },


								{ "name":"HTH_Minus", "type" : "button", "x":160, "y":48, "default_image" : "d:/ymir work/interface/expand_system/minus_n.tga", "over_image" : "d:/ymir work/interface/expand_system/minus_h.tga", "down_image" : "d:/ymir work/interface/expand_system/minus_a.tga", },
								{ "name":"INT_Minus", "type" : "button", "x":160, "y":73, "default_image" : "d:/ymir work/interface/expand_system/minus_n.tga", "over_image" : "d:/ymir work/interface/expand_system/minus_h.tga", "down_image" : "d:/ymir work/interface/expand_system/minus_a.tga", },
								{ "name":"STR_Minus", "type" : "button", "x":160, "y":98, "default_image" : "d:/ymir work/interface/expand_system/minus_n.tga", "over_image" : "d:/ymir work/interface/expand_system/minus_h.tga", "down_image" : "d:/ymir work/interface/expand_system/minus_a.tga", },
								{ "name":"DEX_Minus", "type" : "button", "x":160, "y":123, "default_image" : "d:/ymir work/interface/expand_system/minus_n.tga", "over_image" : "d:/ymir work/interface/expand_system/minus_h.tga", "down_image" : "d:/ymir work/interface/expand_system/minus_a.tga", },
							),
						},

					),
				},
				{
					"name" : "Stats_Page",
					"type" : "window",
					"style" : ("attach",),

					"x" : 10,
					"y" : 110,

					"width" : 280,
					"height" : 280,

					"children" :
					(
						{
							"name" : "StatusBoard",
							"type" : "new_board",

							"x" : 0,
							"y" : 0,

							"width" : 275,
							"height" : 275,

							"children":
							(
								{"name":"Header1Text","type":"text","text":uiScriptLocale.CHARACTER_STATS,"color" : 0xfff8d090,"x":2,"y":-120,"all_align":"center",},

								{
									"name":"HeaderWnd1",
									"type":"image",
									"x":35,
									"y":5,
									"image":"d:/ymir work/interface/horizontal_bar/center.tga",
									"all_align":"center",

								},

							),
						},
					),
				},
				{
					"name" : "Bonus_Page",
					"type" : "window",
					"style" : ("attach",),

					"x" : 10,
					"y" : 110,

					"width" : 280,
					"height" : 280,

					"children" :
					(
						{
							"name" : "BonusBoard",
							"type" : "window",

							"x" : 0,
							"y" : 0,

							"width" : 275,
							"height" : 275,
						},
					),
				},
				{
					"name" : "Skill_Page",
					"type" : "window",
					"style" : ("attach",),

					"x" : 10,
					"y" : 110,

					"width" : 290,
					"height" : 270,

					"children" :
					(
						{
							"name":"SkillBoard",
							"type":"new_board",
							"x":0,
							"y":0,
							"width":275,
							"height":275,
							"children":
							(
								{"name":"HeaderText","type":"text","text": uiScriptLocale.SKILL_ABILITIS, "color" : 0xFFFFE3AD,"x":0,"y":-125,"all_align":"center",},

								{
									"name":"HeaderWnd1",
									"type":"image",
									"x":35,
									"y":0,
									"image":"d:/ymir work/interface/horizontal_bar/center.tga",
									"all_align":"center",


								},
								{
									"name":"BoardSkill",
									"type":"image",
									"x":5,
									"y":40+5,
									"image": "d:/ymir work/interface/character/skill.tga",
									"all_align":"center",

								},

								{
									"name":"SupportBoard",
									"type":"image",
									"x":15,
									"y":190,
									"image": "d:/ymir work/interface/character/support_skills.tga",
									"all_align":"center",

								},

								## Group Button
								{
									"name" : "Skill_Group_Button_1",
									"type" : "radio_button",

									"x" : 40,
									"y" : 29,


									"tooltip_text" : "Capacités",
									"text_color" : 0xFFFFE3AD,

									"default_image" : "d:/ymir work/interface/expand_system/minimize_n.tga",
									"over_image" : "d:/ymir work/interface/expand_system/minimize_h.tga",
									"down_image" : "d:/ymir work/interface/expand_system/minimize_a.tga",

								},

								{
									"name" : "Skill_Group_Button_2",
									"type" : "radio_button",

									"x" : 220,
									"y" : 29,

									"tooltip_text" : "Compétences cheval",
									"text_color" : 0xFFFFE3AD,

									"default_image" : "d:/ymir work/interface/expand_system/expand_n.tga",
									"over_image" : "d:/ymir work/interface/expand_system/expand_h.tga",
									"down_image" : "d:/ymir work/interface/expand_system/expand_a.tga",
								},

								{
									"name" : "Active_Skill_Group_Name",
									"type" : "text",

									"x" : 65,
									"y" : -102,
									"text" : "Active",

									"vertical_align" : "center",
									"text_vertical_align" : "center",
									"color" : 0xFFFFE3AD,
								},
								{ "name":"Active_Skill_Point_Value", "type":"text", "x":25, "y":30, "text":"99", "r":1.0, "g":1.0, "b":1.0, "a":1.0, "text_horizontal_align":"center", "horizontal_align":"center" },
								#{ "name":"Skill_Board", "type":"image", "x":13, "y":38, "image":"d:/ymir work/ui/game/windows/skill_board.sub", },

								## Active Slot
								{
									"name" : "Skill_Active_Slot",
									"type" : "slot",

									"x" : 0 + 13,
									"y" : 0 + 15 + 38 + 5,

									"width" : 250,
									"height" : 223,
									"image" : "slot.tga",

									"slot" :	(
													{"index": 1, "x": 0, "y":  -4, "width":32, "height":32},
													{"index":21, "x":41, "y":  -5, "width":32, "height":32},
													{"index":41, "x":82, "y":  -5, "width":32, "height":32},

													{"index": 3, "x": 0, "y": 37, "width":32, "height":32},
													{"index":23, "x":41, "y": 37, "width":32, "height":32},
													{"index":43, "x":82, "y": 36, "width":32, "height":32},

													{"index": 5, "x": 0, "y": 78, "width":32, "height":32},
													{"index":25, "x":41, "y": 78, "width":32, "height":32},
													{"index":45, "x":82, "y": 78, "width":32, "height":32},

													{"index": 7, "x": 0, "y":112, "width":32, "height":32},
													{"index":27, "x":41, "y":112, "width":32, "height":32},
													{"index":47, "x":41, "y":112, "width":32, "height":32},

													####

													{"index": 2, "x":113+21, "y":  -4, "width":32, "height":32},
													{"index":22, "x":150+25, "y":  -5, "width":32, "height":32},
													{"index":42, "x":187+29, "y":  -5, "width":32, "height":32},

													{"index": 4, "x":113+21, "y": 37, "width":32, "height":32},
													{"index":24, "x":150+25, "y": 37, "width":32, "height":32},
													{"index":44, "x":187+29, "y": 36, "width":32, "height":32},

													{"index": 6, "x":113+21, "y": 78, "width":32, "height":32},
													{"index":26, "x":150+25, "y": 78, "width":32, "height":32},
													{"index":46, "x":187+29, "y": 78, "width":32, "height":32},

													{"index": 8, "x":113, "y":112, "width":32, "height":32},
													{"index":28, "x":150, "y":112, "width":32, "height":32},
													{"index":48, "x":187, "y":112, "width":32, "height":32},
												),
								},
								{"name":"Header1Text", "type":"text", "text":uiScriptLocale.SKILL_SUPPORT, "color" : 0xFFFFE3AD, "x":0,"y":40,"all_align":"center",},
								{
									"name":"HeaderWnd1",
									"type":"image",
									"x":35,
									"y":163,
									"image":"d:/ymir work/interface/horizontal_bar/center.tga",
									"all_align":"center",

								},

								## ETC Slot
								{
									"name" : "Skill_ETC_Slot",
									"type" : "grid_table",
									"x" : 20,
									"y" : 194,
									"start_index" : 101,
									"x_count" : 6,
									"y_count" : 2,
									"x_step" : 31,
									"y_step" : 37,
									"x_blank" : 10,
									"y_blank" : 4,
									# "image" : ICON_SLOT_FILE,
								},
							),
						},
					),
				},
				{
					"name" : "Emoticon_Page",
					"type" : "window",
					"style" : ("attach",),

					"x" : 10,
					"y" : 110,

					"width":280,
					"height":280,

					"children" :
					(
						{
							"name":"EmoticonBoard",
							"type":"new_board",
							"x":0,
							"y":0,
							"width":275,
							"height":275,
							"children":
							(
								{"name":"Header1Text","type":"text","text":uiScriptLocale.CHARACTER_NORMAL_ACTION,"color" : 0xFFFFE3AD,"x":0,"y":-121,"all_align":"center",},

								{
									"name":"HeaderWnd1",
									"type":"image",
									"x":35,
									"y":5,
									"image":"d:/ymir work/interface/horizontal_bar/center.tga",
									"all_align":"center",

								},
								{
									"name":"EmotionBoard",
									"type":"image",
									"x":5,
									"y":35,
									"image":"d:/ymir work/interface/emotions/emotion_board.tga",
									"all_align":"center",

								},
								{
									"name":"EmotionBoard2",
									"type":"image",
									"x":15,
									"y":185,
									"image":"d:/ymir work/interface/emotions/emotion_board2.tga",
									"all_align":"center",

								},
								## Basis Action Slot
								{
									"name" : "SoloEmotionSlot",
									"type" : "grid_table",
									"x" : 18,
									"y" : 43,
									"horizontal_align" : "center",
									"start_index" : 1,
									"x_count" : 6,
									"y_count" : 3,
									"x_step" : 31,
									"y_step" : 37,
									"x_blank" : 10,
									"y_blank" : 4,
									"image" : "d:/ymir work/interface/slot/slot.tga",
								},

								{"name":"Header3Text","type":"text","text":uiScriptLocale.EMOTION_TITLE_2,"color" : 0xFFFFE3AD,"x":0,"y":30,"all_align":"center",},

								{
									"name":"HeaderWnd2",
									"type":"image",
									"x":35,
									"y":155,
									"image":"d:/ymir work/interface/horizontal_bar/center.tga",
									"all_align":"center",

								},

								## Reaction Slot
								{
									"name" : "DualEmotionSlot",
									"type" : "grid_table",
									"x" : 20,
									"y" : 189,
									"start_index" : 51,
									"x_count" : 6,
									"y_count" : 1,
									"x_step" : 31,
									"y_step" : 37,
									"x_blank" : 10,
									"y_blank" : 4,
									"image" : "slot.tga",
								},
							),
						},
					),
				},
				{
					"name" : "Quest_Page",
					"type" : "window",
					"style" : ("attach",),

					"x" : 10,
					"y" : 110,

					"width" : 290,
					"height" : 304,

					"children" :
					(
						{
							"name":"QuestBoard",
							"type":"new_board",
							"x":0,
							"y":0,
							"width":275,
							"height":275,
							"children":
							(
								{"name":"Header1Text","type":"text","text":"|cfff8d09eQuête","x":0,"y":-123,"all_align":"center",},

								{
									"name":"HeaderWnd1",
									"type":"image",
									"x":35,
									"y":5,
									"image":"d:/ymir work/interface/horizontal_bar/center.tga",
									"all_align":"center",

								},
								{
									"name" : "Quest_Slot",
									"type" : "grid_table",
									"x" : 18,
									"y" : 50,
									"start_index" : 0,
									"x_count" : 1,
									"y_count" : 4,
									"x_step" : 27,
									"y_step" : 27,
									"y_blank" : 22,
									# "image" : QUEST_ICON_BACKGROUND,
								},

								{
									"name" : "Quest_ScrollBar",
									"type" : "new_scrollbar",

									"x" : 35,
									"y" : 52,
									"size" : 190,
									"horizontal_align" : "right",
								},

								{ "name" : "Quest_Name_00", "type" : "text", "text" : "?????", "color" : 0xff81663a, "x" : 67, "y" : 50 },
								{ "name" : "Quest_LastTime_00", "type" : "text", "text" : "?? ?? ???", "color" : 0xff5c5351, "x" : 70, "y" : 66 },
								{ "name" : "Quest_LastCount_00", "type" : "text", "text" : "?? ?? ???", "color" : 0xff5c5351, "x" : 70, "y" : 82 },

								{ "name" : "Quest_Name_01", "type" : "text", "text" : "?????", "color" : 0xff81663a, "x" : 67, "y" : 50+50 },
								{ "name" : "Quest_LastTime_01", "type" : "text", "text" : "?? ?? ???", "color" : 0xff5c5351, "x" : 70, "y" : 66+50 },
								{ "name" : "Quest_LastCount_01", "type" : "text", "text" : "?? ?? ???", "color" : 0xff5c5351, "x" : 70, "y" : 82+50 },

								{ "name" : "Quest_Name_02", "type" : "text", "text" : "?????", "color" : 0xff81663a, "x" : 67, "y" : 50+50*2 },
								{ "name" : "Quest_LastTime_02", "type" : "text", "text" : "?? ?? ???", "color" : 0xff5c5351, "x" : 70, "y" : 66+50*2 },
								{ "name" : "Quest_LastCount_02", "type" : "text", "text" : "?? ?? ???", "color" : 0xff5c5351, "x" : 70, "y" : 82+50*2 },

								{ "name" : "Quest_Name_03", "type" : "text", "text" : "?????", "color" : 0xff81663a, "x" : 67, "y" : 50+50*3 },
								{ "name" : "Quest_LastTime_03", "type" : "text", "text" : "?? ?? ???", "color" : 0xff5c5351, "x" : 70, "y" : 66+50*3 },
								{ "name" : "Quest_LastCount_03", "type" : "text", "text" : "?? ?? ???", "color" : 0xff5c5351, "x" : 70, "y" : 82+50*3 },
								
								{ "name" : "Quest_Name_04", "type" : "text", "text" : "?????", "color" : 0xff81663a, "x" : 67, "y" : 50+50*4 },
								{ "name" : "Quest_LastTime_04", "type" : "text", "text" : "?? ?? ???", "color" : 0xff5c5351, "x" : 70, "y" : 66+50*4 },
								{ "name" : "Quest_LastCount_04", "type" : "text", "text" : "?? ?? ???", "color" : 0xff5c5351, "x" : 70, "y" : 82+50*4 },

							),
						},
					),
				},
			),
		},
	),
}

Pourquoi avoir une erreur de GetChild ?

Edited by Jinzo
Link to comment
  • 0
  • Développeur
Le 14/10/2018 à 10:51, Jinzo a dit :

Pourquoi avoir une erreur de GetChild ?

 

 

Il faut toujours vérifier que le Child existe avant de l'appeler/l'utiliser...

Edited by Kameyu
  • J'adore 1
Link to comment
  • 0
  • Développeur

La fonction IsChild te permettra d'évaluer si l'objet a bien été créé, si c'est pas le cas il renverra false. Si c'est le cas c'est

que ton objet n'existe pas (encore) mais que ton client essaie d'y accéder, ce qui cause l'erreur "KeyError".

 

En gros, tu dois faire un truc dans le genre:

if self.IsChild("PercentExp") == True:
  ##suite du code

 

  • J'adore 1
Link to comment
  • 0

ok donc en gros , je devrais obtenir ceci donc :

if self.IsChild("PercentExp") == True:
			self.GetChild("PercentExp").SetText("%s %.2f%%" % ("", float(curPoint) / max(1, float(maxPoint)) * 100))

Merci beaucoup pour les informations , mon syserr est a présent vide hors mis une texture manquante , mais rien que je ne puisse régler seul

Je termine de traduire et je partagerai le client "Illumina" , merci a toi .

 

Je préfère laisser encore un peu le sujet ouvert si cela ne te dérange pas . Merci

Edited by Jinzo
Link to comment
Guest
This topic is now closed to further replies.


  • Flux d'Activité

    1. 3

      Éditeur Item 2.43 à 2.53

    2. 0

      Grand Fantasia sur serveur Aura Kingdom

    3. 1

      Emulateur 2.43 X4

    4. 3

      Core Download - Journal des modifications

  • Recently Browsing

    • No registered users viewing this page.

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.