Cow. Need help please. - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Cow. Need help please. (
/showthread.php?tid=341143)
Cow. Need help please. -
Edin Black - 09.05.2012
Hello. I need help.
pawn Код:
if(strcmp(cmd, "/cow", true) == 0)
{
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_DGOLD, "KORISTENJE: /cow [ID/DioImena]");
return 1;
}
giveplayerid = ReturnUser(tmp);
if (PlayerInfo[playerid][pAdmin] >= 4)
{
if(IsPlayerConnected(giveplayerid))
{
if(giveplayerid != INVALID_PLAYER_ID)
{
AttachObjectToPlayer(cow[playerid], playerid, 0.0, 0.0, 4.0, 0.0, 0.0, 0.0);
return 1;
}
}//not connected
}
else
{
format(string, sizeof(string), "ERROR: Igrac %s nije aktivan igrac. Pokusajte kasnje opet.", giveplayerid);
SendClientMessage(playerid, COLOR_GRAD1, string);
}
}
return 1;
}
It doesnґt work, whoґs the problem.
Re: Cow. Need help please. -
Edin Black - 09.05.2012
Can anyone help me? Please, itґs important.
Re: Cow. Need help please. -
HDFord - 09.05.2012
Why did you not use the code i sent you. I know it is in zcmd/sscanf but that is easyer to script and that code worked.
Re: Cow. Need help please. -
Edin Black - 10.05.2012
The code didnґt work.
help me. strcmp
Re: Cow. Need help please. -
Maacknx - 10.05.2012
Hi, i no have good english but, post the error, i try help you.
Re: Cow. Need help please. -
Maacknx - 10.05.2012
try
Код:
if(IsPlayerConnected(playerid))
{
>> tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_DGOLD, "KORISTENJE: /cow [ID/DioImena]");
return 1;
}
to
Код:
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_DGOLD, "KORISTENJE: /cow [ID/DioImena]");
return 1;
}
probable identation error
Re: Cow. Need help please. -
Edin Black - 10.05.2012
It also didnґt work.
Re: Cow. Need help please. -
Maacknx - 10.05.2012
ok, post the error that appears when compiling
Re: Cow. Need help please. -
davve95 - 10.05.2012
Any error messages or just won't work?...
Re: Cow. Need help please. -
Edin Black - 10.05.2012
no errors.
it just didnґt work