if (strcmp("/Setvip", cmdtext, true, 10) == 0)
{
dini_Set("VipAccounts/%s.txt","vip","1");
SendClientMessage(playerid, COLOR_A, "установлено значение 1");
return 1;
}
if(strcmp(cmd, "/setvip", true) == 0)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_A, "ошибка: /setvip [ид] [кол-во]");
return 1;
}
giveplayeridd = strval(tmp);
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_A, "ошибка: /setvip [ид] [кол-во]");
return 1;
}
if (IsPlayerConnected(giveplayeridd))
{
new VipAccount[256];
format(VipAccount,256,"VipAccounts/%s.txt", PlayerName(playerid));
new proverka;
proverka=dini_Get(VipAccount,"vip");
if(proverka == 1) dini_IntSet(VipAccount, "vip",0);
if(proverka == 0) dini_IntSet(VipAccount, "vip",1);
}
else
{
format(string, sizeof(string), "%d неактивный игрок.", giveplayeridd);
SendClientMessage(playerid, COLOR_A, string);
}
return 1;
}
|
error 006: must be assigned to an array |
new proverka;
proverka=dini_Get(VipAccount,"vip");
new proverka;
proverka=dini_Int(VipAccount,"vip");