[Ajuda] array small - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: Non-English (
https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (
https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (
https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] array small (
/showthread.php?tid=411427)
array small -
Cristhian - 28.01.2013
pawn Код:
new arquivo[128], msg[30];
format(arquivo, sizeof(arquivo), "ORG Arquivos/Org%d.cfg",GetPlayerOrg(playerid));
for(new i = 0; i < 24; i++)
{
if(strcmp(InfoOrg[i][Lider], PlayerName(playerid), true) == 0)
{
split(PlayerInfo[playerid][pLastLogin],Info,'/');
format(msg, sizeof(msg), "%d/%d/%d аs %d:%d:%d",strval(Info[0]),strval(Info[1]),strval(Info[2]),strval(Info[3]),strval(Info[4]),strval(Info[5]));
InfoOrg[i][LastLogin] = msg;//erro aqui
dini_Set(arquivo, "LastLogin", InfoOrg[i][LastLogin]);
}
}
Код:
C:\Documents and Settings\Cristhian\Desktop\Server Samp\Server Samp\gamemodes\Final.pwn(14695) : error 047: array sizes do not match, or destination array is too small
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
1 Error.
Re: array small -
mau.tito - 28.01.2013
Tenta setar ele com um format acho que й assim !
pawn Код:
new arquivo[128], msg[30];
format(arquivo, sizeof(arquivo), "ORG Arquivos/Org%d.cfg",GetPlayerOrg(playerid));
for(new i = 0; i < 24; i++)
{
if(strcmp(InfoOrg[i][Lider], PlayerName(playerid), true) == 0)
{
split(PlayerInfo[playerid][pLastLogin],Info,'/');
format(msg, InfoOrg[i][LastLogin], "%d/%d/%d аs %d:%d:%d",strval(Info[0]),strval(Info[1]),strval(Info[2]),strval(Info[3]),strval(Info[4]),strval(Info[5]));
dini_Set(arquivo, "LastLogin", InfoOrg[i][LastLogin]);
}
}
Re: array small -
steki. - 28.01.2013
new a[30], b[30];
Para que o assignment, ou atribuiзгo ocorra, й necessбrio que ambas variaveis sejam iguais por estrutura.
Respuesta: array small -
Rodrigo_Avenged - 28.01.2013
Stewie , olha PM .. rs