Skripta koju koristim:Jedan moj [cenzura]
Detaljan opis problema:PA stavio sam cmd /jail sve to i dobio eror
Dio skripte:
Neke slike/video za lakse dobivanje pomoci(neobavezno):
CitatC:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(8434) : warning 217: loose indentation
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(10111) : warning 217: loose indentation
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(10219) : warning 217: loose indentation
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(10247) : warning 217: loose indentation
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(10295) : warning 217: loose indentation
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(10325) : warning 217: loose indentation
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(10360) : warning 217: loose indentation
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(11877) : warning 202: number of arguments does not match definition
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(11877) : warning 202: number of arguments does not match definition
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(11877) : warning 202: number of arguments does not match definition
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(11877) : warning 202: number of arguments does not match definition
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(16767) : warning 217: loose indentation
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(16808) : error 001: expected token: "-string end-", but found "-identifier-"
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(16808) : error 017: undefined symbol "COL_RED"
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(16808) : warning 215: expression has no effect
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(16808) : error 001: expected token: ";", but found "-identifier-"
C:\Documents and Settings\ws\Desktop\Gamez\gm\pumarpg\pumarpg\gamemodes\DREAMWORLD.pwn(16808) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
4 Errors.
postaj po pravilima foruma http://balkan-samp.com/forum/index.php?topic=11453.0 i onda ce ti neko pomoci
kod boja gore na pocetku scripte dodaj
#define COL_RED "{FF0000}"
mislim da za to sluzi to COL_RED ...
i tu isto dodaj
#pragma tabsize 0
da resis ove Loose indentation warninge... a daj ovaj red 11877 da vidim sta tu izaziva warning...
Citat: dock poslato Mart 08, 2012, 18:44:39 POSLE PODNE
kod boja gore na pocetku scripte dodaj
#define COL_RED "{FF0000}"
mislim da za to sluzi to COL_RED ...
i tu isto dodaj
#pragma tabsize 0
da resis ove Loose indentation warninge... a daj ovaj red 11877 da vidim sta tu izaziva warning...
e brate ja dodao to sve i pa isti errore
Daj mi da vidim tu komandu sto si dodao...
Citat: dock poslato Mart 08, 2012, 18:54:48 POSLE PODNE
Daj mi da vidim tu komandu sto si dodao...
Citatif(strcmp(cmd, "/jail", true) == 0)
{
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /jail [playerid/PartOfName] [time(minutes)] [reason]");
return 1;
}
new playa;
new money;
playa = ReturnUser(tmp);
tmp = strtok(cmdtext, idx);
money = strval(tmp);
if (PlayerInfo[playerid][pAdmin] >= 1 )
{
if(IsPlayerConnected(playa))
{
if(playa != INVALID_PLAYER_ID)
{
GetPlayerName(playa, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
new length = strlen(cmdtext);
while ((idx < length) && (cmdtext[idx] <= ' '))
{
idx++;
}
new offset = idx;
new result[128];
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
{
result[idx - offset] = cmdtext[idx];
idx++;
}
result[idx - offset] = EOS;
if(!strlen(result))
{
SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /jail [playerid/PartOfName] [time(minutes)] [reason]");
return 1;
}
format(string, sizeof(string), "* ("COL_RED"Puma RPG Macedonia{FFFFFF}!) Go zatvorivte "COL_RED"%s.", giveplayer);
SendClientMessage(playerid, COLOR_WHITE, string);
format(string, sizeof(string), "* ("COLOR_RED"Puma RPG Macedonia{FFFFFF}!) "COL_RED"%s {FFFFFF}Ve zatvori vo zatvor | Razlog: "COL_RED"%s", sendername, (result));
SendClientMessage(playa, COLOR_WHITE, string);
SafeResetPlayerWeapons(playa);
WantedPoints[playa] = 0;
PlayerInfo[playa][pJailed] = 1;
PlayerInfo[playa][pJailTime] = money*60;
SetPlayerInterior(playa, 0);
PlayerInfo[playa][pInt] = 0;
new rand = random(sizeof(gRandomJailSpawns));
SetPlayerPos(playa, gRandomJailSpawns[rand][0], gRandomJailSpawns[rand][1], gRandomJailSpawns[rand][2]);
format(string, sizeof(string), "Zatvoren si "COL_RED"%d {FFFFFF}minuti. Jamcevina: "COL_RED"Nedostupna", money);
SendClientMessage(playa, COLOR_WHITE, string);
format(string, 256, "AdmCmd: %s e zatvoren %d minuti od Admin %s Pricina: %s", giveplayer,money, sendername, result);
BroadCast(COLOR_LIGHTRED,string);
format(string, sizeof(string), "AdmCmd: %s e zatvoren %d minuti od Admin %s Pricina: %s", giveplayer,money, sendername, result);
printf("%s",string);
}
}
}
else
{
SendClientMessage(playerid, COLOR_RED, " Ne si admin pa da ja koristis komandata!");
}
}
return 1;
}
a kada obrises komandu radi normalno?
pomocccccccccccccccccc plss :(
proaj obrisat tu svoju i dodaj ovu }
if(strcmp(cmd, "/jail", true) == 0)
{
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /jail [playerid/PartOfName] [time(minutes)] [reason]");
return 1;
}
new playa;
new money;
playa = ReturnUser(tmp);
tmp = strtok(cmdtext, idx);
money = strval(tmp);
if (PlayerInfo[playerid][pAdmin] >= 1 || PlayerInfo[playerid][pGameSage] >= 1)
{
if(IsPlayerConnected(playa))
{
if(playa != INVALID_PLAYER_ID)
{
GetPlayerName(playa, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
new length = strlen(cmdtext);
while ((idx < length) && (cmdtext[idx] <= ' '))
{
idx++;
}
new offset = idx;
new result[128];
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
{
result[idx - offset] = cmdtext[idx];
idx++;
}
result[idx - offset] = EOS;
if(!strlen(result))
{
SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /jail [playerid/PartOfName] [time(minutes)] [reason]");
return 1;
}
format(string, sizeof(string), "* ("COL_RED"C.Life{FFFFFF}!) Zatvorio si "COL_RED"%s.", giveplayer);
SendClientMessage(playerid, WHITE, string);
format(string, sizeof(string), "* ("COL_RED"C.Life{FFFFFF}!) "COL_RED"%s {FFFFFF}vas je zatvorio u zatvor | Razlog: "COL_RED"%s", sendername, (result));
SendClientMessage(playa, WHITE, string);
SafeResetPlayerWeapons(playa);
WantedPoints[playa] = 0;
PlayerInfo[playa][pJailed] = 1;
PlayerInfo[playa][pJailTime] = money*60;
SetPlayerInterior(playa, 0);
PlayerInfo[playa][pInt] = 0;
new rand = random(sizeof(gRandomJailSpawns));
SetPlayerPos(playa, gRandomJailSpawns[rand][0], gRandomJailSpawns[rand][1], gRandomJailSpawns[rand][2]);
format(string, sizeof(string), "Zatvorn si na "COL_RED"%d {FFFFFF}minuta. Jamcevina: "COL_RED"Nedostupna", money);
SendClientMessage(playa, COLOR_WHITE, string);
format(string, 256, "("COL_RED"C.Life{FFFFFF}!) "COL_RED"%s {FFFFFF}je zatvoren od "COL_RED"%s | {FFFFFF}Razlog: "COL_RED"%s", giveplayer, sendername, (result));
ABroadCast(WHITE,string,1);
format(string, sizeof(string), "Jail | %s,Admin %s [Razlog: %s]", giveplayer, sendername, (result));
printf("%s",string);
}
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " you are not authorized to use that command!");
}
}
return 1;
}