C:\Users\Jay\Desktop\FRP\gamemodes\ECRP.pwn(4642) : error 006: must be assigned to an array C:\Users\Jay\Desktop\FRP\gamemodes\ECRP.pwn(40447) : error 047: array sizes do not match, or destination array is too small Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 2 Errors.
CMD:admintitle(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] >= 1338)
{
new giveplayerid, tmp[MAX_PLAYER_NAME];
if(!sscanf(params, "us[20]", giveplayerid, tmp))
{
if(IsPlayerConnected(giveplayerid))
{
new string[200];
MySQLCheckConnection();
new giveplayer[MAX_PLAYER_NAME];
giveplayer = PlayerInfo[giveplayerid][pAdminTitle];
new sendername[MAX_PLAYER_NAME];
sendername = PlayerName(playerid);
new escstr[MAX_PLAYER_NAME];
mysql_real_escape_string(tmp, escstr);
//Update the stats time!
format(string, sizeof(string),"UPDATE `userinf` SET `AdminTitle`='%s' WHERE `id`=%d ;", escstr, PlayerInfo[giveplayerid][pSQLID]);
format(string, sizeof(string), "System: %s has changed your AdminTitle to %s.", sendername, tmp);
SendClientMessage(giveplayerid, COLOR_ORANGE, string);
format(string, sizeof(string),"System: %s has changed %s's Admin Title to %s.", sendername, giveplayer, tmp);
ABroadCast(COLOR_YELLOW, string,1);
}
else
{
SendClientMessage(playerid, COLOR_LIGHTRED, " Invalid player!");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_WHITE, "USAGE: /AdminTitle [playerid/PartOfName] [Title]");
SendClientMessage(playerid, COLOR_BRIGHTRED, "WARNING, Case sensitive");
}
}
return 1;
}
giveplayer = PlayerInfo[giveplayerid][pAdminTitle];
strcat(giveplayer, PlayerInfo[giveplayerid][pAdminTitle]);
sendername = PlayerName(playerid);
strcat(sendername, PlayerName(playerid));
|
You can't assign strings like that.
pawn Код:
pawn Код:
pawn Код:
pawn Код:
|
PlayerInfo[playerid][pAdminTitle] = "%s";
C:\Users\Jay\Desktop\FRP\gamemodes\ECRP.pwn(4643) : error 006: must be assigned to an array Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 1 Error.
|
Get your own god damn script! Don't use my fucking script... God damn't. He is using my script, which I gaving no-one rights to use... btw, Anthony Heins here.
|