Pawno Error
#5

remove:
PHP код:
stock ReturnUser(text[])
{
    new 
pos 0;
    new 
userid RETURN_USER_FAILURE;
        
    while(
text[pos] < 0x21) { // Strip out leading spaces
        
if(text[pos] == 0) return RETURN_USER_FAILURE// No passed text
        
pos++;
    }
        
    if(
isNumeric(text[pos])) { // Check whole passed string
        
userid strval(text[pos]);
        if(
userid >=&& userid MAX_PLAYERS)
        {
            if(
IsPlayerConnected(userid)) return userid;
            return 
RETURN_USER_FAILURE;
        }
    }
    
    
// They entered [part of] a name or the id search failed (check names just incase)
    
new len strlen(text[pos]);
    new 
count 0;
    new 
name[MAX_PLAYER_NAME+1];
    
    for(new 
0MAX_PLAYERSi++)
    {
        if(
IsPlayerConnected(i))
        {
            
GetPlayerName(inamesizeof(name));
            if(
strcmp(nametext[pos], truelen) == 0// Check segment of name
            
{
                if(
len == strlen(name)) { // Exact match
                    
return i;
                }
                else { 
// Partial match
                    
count++;
                    
userid i;
                }
            }
        }
    }
    
    if(!
count) return RETURN_USER_FAILURE;
    if(
count 1) return RETURN_USER_MULTIPLE;
    
    return 
userid;

or try to found it in your gm and remove it from there
Reply


Messages In This Thread
Pawno Error - by Axel712 - 06.09.2015, 20:14
Re: Pawno Error - by Crystallize - 06.09.2015, 20:15
Re: Pawno Error - by Bingo - 06.09.2015, 20:15
Re: Pawno Error - by Axel712 - 06.09.2015, 20:22
Re: Pawno Error - by jlalt - 06.09.2015, 20:38
Re: Pawno Error - by Axel712 - 06.09.2015, 20:41

Forum Jump:


Users browsing this thread: 1 Guest(s)