Register for your free account! | Forgot your password?

Go Back   elitepvpers > Popular Games > Metin2 > Metin2 Private Server
You last visited: Today at 07:57

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Button only for some players ?

Discussion on Button only for some players ? within the Metin2 Private Server forum part of the Metin2 category.

Reply
 
Old   #1
 
WyppyOne's Avatar
 
elite*gold: 120
Join Date: Jul 2012
Posts: 219
Received Thanks: 6
Button only for some players ?

Hi , i have inventory viewer but , i can make it to appear only at players who names are "[..]..." ? Like [MOD] ,[VIP],[GM] etc ... if your name start with
[" that button appear
thread :
-------------------
sorry for my english...i hope you understand
WyppyOne is offline  
Old 08/02/2013, 09:17   #2
 
elite*gold: 5
Join Date: Mar 2013
Posts: 1,986
Received Thanks: 2,254
Quote:
Open up uitarget.py
At line 287 we find:

PHP Code:
 def ShowDefaultButton(self):

        
self.isShowButton TRUE
        self
.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_WHISPER])
        
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EXCHANGE])
        
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_FIGHT])
        
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EMOTION_ALLOW])
        for 
button in self.showingButtonList:
            
button.Show() 
Above all those "self.showingButtonList.append" we'll add:
PHP Code:
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_VIEW_EQUIPMENT]) 
We replace it with(untested!):

PHP Code:
def ShowDefaultButton(self):

        
import player
        name 
player.GetName()
        
self.isShowButton TRUE
        self
.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_WHISPER])
        
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EXCHANGE])
        
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_FIGHT])
        
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EMOTION_ALLOW])

        if 
name.find("[")!=-or name.find("]")!=-1:
            
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_VIEW_EQUIPMENT])

        for 
button in self.showingButtonList:
            
button.Show() 
I Hope it works
xGr33n is offline  
Thanks
2 Users
Old 08/02/2013, 16:01   #3
 
WyppyOne's Avatar
 
elite*gold: 120
Join Date: Jul 2012
Posts: 219
Received Thanks: 6
thx ... but doens't work
WyppyOne is offline  
Old 08/02/2013, 22:13   #4
 
elite*gold: 5
Join Date: Mar 2013
Posts: 1,986
Received Thanks: 2,254
Syserr.txt? or can all see it?
xGr33n is offline  
Old 08/02/2013, 23:08   #5
 
WyppyOne's Avatar
 
elite*gold: 120
Join Date: Jul 2012
Posts: 219
Received Thanks: 6
Code:
def ShowDefaultButton(self):

		self.isShowButton = TRUE
		self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_WHISPER])
		self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EXCHANGE])
		self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_FIGHT])
		self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EMOTION_ALLOW])
		if name.find("[")!=-1 or name.find("]")!=-1: 
            self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_VIEW_EQUIPMENT])
		for button in self.showingButtonList:
			button.Show()
sysser :


Code:
0803 00:03:30730 :: 
networkModule.py(line:194) SetSelectCharacterPhase
system.py(line:130) __pack_import
system.py(line:110) _process_result
introSelect.py(line:26) ?
system.py(line:130) __pack_import

networkModule.SetSelectCharacterPhase - exceptions.IndentationError:unindent does not match any outer indentation level (line 295)

0803 00:03:30731 :: ============================================================================================================
0803 00:03:30731 :: Abort!!!!
WyppyOne is offline  
Old 08/03/2013, 11:12   #6
 
elite*gold: 5
Join Date: Mar 2013
Posts: 1,986
Received Thanks: 2,254
The function you used is Wrong! copy mine!!! Or upload your uitarget.py and i Make it
xGr33n is offline  
Old 08/03/2013, 11:37   #7
 
[uLow]Beni's Avatar
 
elite*gold: 0
Join Date: May 2011
Posts: 1,781
Received Thanks: 618
Quote:
Originally Posted by xGr33n View Post
We replace it with(untested!):

PHP Code:
def ShowDefaultButton(self):

        
import player
        name 
player.GetName()
        
self.isShowButton TRUE
        self
.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_WHISPER])
        
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EXCHANGE])
        
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_FIGHT])
        
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EMOTION_ALLOW])

        if 
"[" in name:
            
self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_VIEW_EQUIPMENT])

        for 
button in self.showingButtonList:
            
button.Show() 
I Hope it works
Is easier to understand i thing
[uLow]Beni is offline  
Thanks
1 User
Old 08/03/2013, 15:29   #8
 
WyppyOne's Avatar
 
elite*gold: 120
Join Date: Jul 2012
Posts: 219
Received Thanks: 6
with :
Code:
	def ShowDefaultButton(self):

		self.isShowButton = TRUE
		self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_WHISPER])
		self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EXCHANGE])
		self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_FIGHT])
		self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EMOTION_ALLOW])
		
		if name.find("[")!=-1 or name.find("]")!=-1: 
            self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_VIEW_EQUIPMENT])
			
		for button in self.showingButtonList:
			button.Show()
sysser :

Code:
0803 16:21:12853 :: 
networkModule.py(line:194) SetSelectCharacterPhase
system.py(line:130) __pack_import
system.py(line:110) _process_result
introSelect.py(line:26) ?
system.py(line:130) __pack_import

networkModule.SetSelectCharacterPhase - exceptions.IndentationError:unindent does not match any outer indentation level (line 296)

0803 16:21:12853 :: ============================================================================================================
0803 16:21:12853 :: Abort!!!!
---------------------------------------------------------------------
with :

Code:
def ShowDefaultButton(self): 

        import player 
        name = player.GetName() 
        self.isShowButton = TRUE 
        self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_WHISPER]) 
        self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EXCHANGE]) 
        self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_FIGHT]) 
        self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_EMOTION_ALLOW]) 

        if "[" in name: 
            self.showingButtonList.append(self.buttonDict[locale.TARGET_BUTTON_VIEW_EQUIPMENT]) 

        for button in self.showingButtonList: 
            button.Show()
sysser :

Code:
0803 16:24:20471 :: CMapOutdoor::Load - LoadMonsterAreaInfo ERROR
0803 16:24:47931 :: CreateFromMemoryFile: Cannot create texture
0803 16:24:48082 :: Traceback (most recent call last):

0803 16:24:48082 ::   File "networkModule.py", line 233, in SetGamePhase

0803 16:24:48082 ::   File "game.py", line 105, in __init__

0803 16:24:48082 ::   File "uiTarget.py", line 99, in __init__

0803 16:24:48082 :: AttributeError
0803 16:24:48082 :: : 
0803 16:24:48082 :: 'TargetBoard' object has no attribute 'OnWhisper'
0803 16:24:48082 ::
img :


my uitarget.py ( if you wanna make it for me ) :
WyppyOne is offline  
Old 08/03/2013, 16:08   #9
 
elite*gold: 5
Join Date: Mar 2013
Posts: 1,986
Received Thanks: 2,254
Test it:
xGr33n is offline  
Thanks
1 User
Old 08/03/2013, 16:57   #10
 
WyppyOne's Avatar
 
elite*gold: 120
Join Date: Jul 2012
Posts: 219
Received Thanks: 6
thx it works , the button appear just at gm etc
WyppyOne is offline  
Reply


Similar Threads Similar Threads
Item-Shop Lager Button Zum Normalen lager button machen? DE
01/12/2011 - Metin2 - 6 Replies
Moin, seid heute gib es ja im inventar den IS button wo man mit sein lager öffnen kann,könnte man den auch zu einem Normalen lager Button Machen?
WarRock statt KOREANISCHE BUTTON --> Englische BUTTON
02/26/2010 - WarRock - 6 Replies
Bin mir nicht sicher ob es diesen Thread schon gibt aber hab bis jetzt nichts gesehen hier. Funktionen Für WarRock Korea Koreanische Schriften (Button) weg und englische Schriften (Button) hin Anleitung



All times are GMT +2. The time now is 07:57.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.