Raised This Month: $ Target: $400
 0% 

Win Messages Changer


Post New Thread Reply   
 
Thread Tools Display Modes
quark
Veteran Member
Join Date: Oct 2011
Location: Your mind.
Old 07-16-2013 , 13:03   Re: Win Messages Changer
Reply With Quote #21

noone comment my joke
__________________

Check out My Plugins:
qServerInfo ; ASKTAG
quark is offline
Jhob94
AMX Mod X Donor
Join Date: Jul 2012
Old 07-16-2013 , 13:12   Re: Win Messages Changer
Reply With Quote #22

Quote:
Originally Posted by Mauricio Frb View Post
Look you only need to create a new function like Send_Message() when you use it 3 times ou more. Remove this public and put in Messages_Audio.
Its the same to have in messages_audio or as it is. I just make like that for dont be together and be better to read

EDIT: (Off-Topic)
Quote:
Originally Posted by quark View Post
noone comment my joke
Your joke or your spam?
__________________

Last edited by Jhob94; 07-16-2013 at 13:13.
Jhob94 is offline
quark
Veteran Member
Join Date: Oct 2011
Location: Your mind.
Old 07-16-2013 , 15:34   Re: Win Messages Changer
Reply With Quote #23

Quote:
Originally Posted by Jhob94 View Post
Your joke or your spam?
That's what i said
__________________

Check out My Plugins:
qServerInfo ; ASKTAG
quark is offline
Jhob94
AMX Mod X Donor
Join Date: Jul 2012
Old 07-16-2013 , 15:59   Re: Win Messages Changer
Reply With Quote #24

You feeling happy for spaming as a noob?
Your join date is Oct 2011 but it looks like people that joined 2days ago have an better behavior then you...
__________________
Jhob94 is offline
quark
Veteran Member
Join Date: Oct 2011
Location: Your mind.
Old 07-16-2013 , 16:26   Re: Win Messages Changer
Reply With Quote #25

__________________

Check out My Plugins:
qServerInfo ; ASKTAG
quark is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 07-16-2013 , 16:30   Re: Win Messages Changer
Reply With Quote #26

Have you used some code from me ?
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Jhob94
AMX Mod X Donor
Join Date: Jul 2012
Old 07-16-2013 , 16:35   Re: Win Messages Changer
Reply With Quote #27

No?
__________________
Jhob94 is offline
guipatinador
SourceMod Donner Party
Join Date: Oct 2009
Location: Poortugal
Old 07-16-2013 , 16:49   Re: Win Messages Changer
Reply With Quote #28

From Furien plugin !
guipatinador is offline
Jhob94
AMX Mod X Donor
Join Date: Jul 2012
Old 07-16-2013 , 16:51   Re: Win Messages Changer
Reply With Quote #29

Quote:
Originally Posted by guipatinador View Post
From Furien plugin !
hum nope?
PHP Code:
T_WON false // Turning It False
        
CT_WON false // Turning It False
        
        
new Audio[14]
        
get_msg_arg_string(2Audiocharsmax(Audio)) // For check next if terro or ct
        
        
if(equal(AudioT_SOUND)) // T
            
T_WON true
        
        
else if(equal(AudioCT_SOUND)) // CT
            
CT_WON true
        
        
else
            return 
// I dont want to check others cases, only if CT or T

        
if(get_msg_block(Text_Msg) == BLOCK_NOT)
            
set_msg_block(Text_MsgBLOCK_ONCE// Block game message
        
        
Send_Message()    // Send Messages 
hum your furien plugin is like that too?
__________________
Jhob94 is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 07-16-2013 , 16:52   Re: Win Messages Changer
Reply With Quote #30

Quote:
Originally Posted by ConnorMcLeod View Post
Have you used some code from me ?
Quote:
Originally Posted by Jhob94 View Post
No?
Quote:
Originally Posted by guipatinador View Post
From Furien plugin !
ROFL, indeed.

PHP Code:
        new szSound[14]
        
get_msg_arg_string(2szSoundcharsmax(szSound))
        if( 
equal(szSound"%!MRAD_ctwin") ) 
Same array size, weird ?
May be you could explain why you have chosen 14 as array size then ?

PHP Code:
        if( get_msg_block(g_iTextMsg) == BLOCK_NOT )
        {
            
set_msg_block(g_iTextMsgBLOCK_ONCE)
        } 
Same method.

Anyway, i don't care, i asked, you said no, that's fine.


About code :

PHP Code:
#define T_SOUND "%!MRAD_terwin" // Dont Change It In Any Case Or Plugin Wont Work
#define CT_SOUND "%!MRAD_ctwin" // Dont Change It In Any Case Or Plugin Wont Work 
This doesn't need to be a define, you can put it directly in code, i mean, there is no bad effect to put it as define, but there is no benefits.


PHP Code:
new bool:T_WONbool:CT_WON 
You don't need those variables, just pass it as argument to Send_Message() function.
->
PHP Code:
Send_Message(TEAM_CT
Also, Send_Message() function should be private, and since it is only used at one place, it should be integrated to Messages_Audio() function, both functions are not big, and Send_Message is not called in a sbu block, so it wouldn't alter readability.

You may also use a Trie instead of using twice equal, you would retrieve Winning Team as Cell Result :
PHP Code:
    g_tWinMessage TrieCreate();
    
TrieSetCell(g_tWinMessage"%!MRAD_terwin"1);
    
TrieSetCell(g_tWinMessage"%!MRAD_ctwin"2); 
PHP Code:
new Audio[14]
        
get_msg_arg_string(2Audiocharsmax(Audio))
        if( 
TrieGetCell(g_tWinMessageAudioWinningTeam) )
        {
            
Send_Message(WinningTeam// pass 1 or 2, 1 for Ts, 2 for CTs
            
if(get_msg_block(Text_Msg) == BLOCK_NOT)
                
set_msg_block(Text_MsgBLOCK_ONCE)
            return 
PLUGIN_HANDLED
        

__________________
- tired and retired -

- my plugins -

Last edited by ConnorMcLeod; 07-16-2013 at 17:04.
ConnorMcLeod is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 22:41.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode