Raised This Month: $ Target: $400
 0% 

string functions


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
vl4dik
New Member
Join Date: Dec 2007
Old 12-10-2007 , 13:46   string functions
Reply With Quote #1

hi, what i need to include and what functions can i use for string comparsion,
can somebody post a snipet for:
"for every player, if in his nick somewhere is `XYZ` do this"
vl4dik is offline
M249-M4A1
I <3 Mac
Join Date: May 2005
Location: Not interested
Old 12-10-2007 , 15:25   Re: string functions
Reply With Quote #2

PHP Code:
public cmdCheckNames(id) {
    new 
players[32], name[32], totalplayers
    get_players
(playerstotalplayers)
    
    for (new 
0totalplayersi++) {
        
get_user_name(players[i], name31)
        
        if (
containi(name"`XYZ`") != -1)
            
console_print(id"[AMXX] Player name '%s' contains `XYZ`"name)
        
    }

__________________
M249-M4A1 is offline
Reply


Thread Tools
Display Modes

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 11:00.


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