aka cmd help
#1

PHP код:
CMD:aka(playeridparams[]) {
    new 
id;
    if(
PlayerInfo[playerid][AdminLevel] >= 2) {
        if(
sscanf(params"d"id)) return SendClientMessage(playeridCOLOR_RED"USAGE: /aka <id>");
        if(!
IsPlayerConnected(id)) return SendClientMessage(playeridCOLOR_RED"ERROR: Player is not connected.");
        if(
id MAX_PLAYERS || id || !IsPlayerConnected(id)) return SendClientMessage(playeridCOLOR_RED"ERROR: Invalid Player ID");
        new 
ip[50], PlayerName[MAX_PLAYER_NAME];
        
GetPlayerIp(idip50);
        
GetPlayerName(idPlayerNamesizeof(PlayerName));
        
sizeof(String) = dini_Get("ip.history.txt"ip);
        if(
strlen(string) < || (!strcmp(PlayerNameszStringtrue)) )
        {
            
format(szStringsizeof(szString),"ERROR: There are no A.K.A's for %s (IP:%s)"PlayerNameip);
            
SendClientMessage(playeridCOLOR_REDszString);
        }
        else {
        new 
index;
        
index strfind(szStringPlayerNametrue);
        new 
itmp1[256],itmp2[256];
        
strmid(itmp1szString0, (index)?index-2:index);
        
strmid(itmp2szString,(index)?index+strlen(PlayerName):index+strlen(PlayerName)+2,strlen(szString));
        
format(szStringsizeof(szString),"--- %s is AKA ---"PlayerName);
        
SendClientMessage(playeridCOLOR_YELLOWszString);
        
format(szStringsizeof(szString),"* A.K.A: %s %s (IP:%s)"itmp1itmp2ip);
        
SendClientMessage(playeridCOLOR_YELLOWszString);
        }
    }
    else {
        return 
0;
    }
    return 
1;


PHP код:
ERRORS:-C:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27192) : error 017undefined symbol "String"
C:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27192) : error 029invalid expressionassumed zero
C
:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27194) : error 017undefined symbol "string"
C:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27196) : error 017undefined symbol "szString"
C:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27196) : error 017undefined symbol "szString"
C:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27196) : error 029invalid expressionassumed zero
C
:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27196) : fatal error 107too many error messages on one line
Compilation aborted
.Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase
7 Errors

AS i m trying to edit this code in my nAdmin because my nAdmin system doesnt have this aka system.. i take it from somewhere but its showing error
Reply
#2

pawn Код:
new String[128], string[128], szString[128];
place it under new id;


Off topic: L L xD your avatar is f*cking funny xD
Reply
#3

Yes Its Working ...
But its showing This Error :-




C:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27193) : error 022: must be lvalue (non-constant)
C:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27185) : warning 204: symbol is assigned a value that is never used: "String"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


1 Error.
Reply
#4

which is line 27193?
and use this:-
pawn Код:
new string[128], szString[128], String;
Reply
#5

Quote:
Originally Posted by PrinXe
Посмотреть сообщение
Yes Its Working ...
But its showing This Error :-




C:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27193) : error 022: must be lvalue (non-constant)
C:\Users\vishal\Desktop\New folder (22)\High Speed Drivers\gamemodes\GG.pwn(27185) : warning 204: symbol is assigned a value that is never used: "String"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


1 Error.
my bad xD

maybe it's actually like this
pawn Код:
new String, string[128], szString[128];
Reply
#6

These are the error lines:-
27193:-sizeof(String) = dini_Get("ip.history.txt", ip);
27185:-new String, string[128], szString[128];

These both lines have error!!!
Reply
#7

plz help!!
Reply
#8

read my previous post
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)