Započeo Contixo
•5. Jul 2012.[Pomoć] 5 errora - textdrawsi
1,339
pregleda
13
postova
Made Man
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
385
Postovi:
93
Teme:
Pridružio se:Sep. 2011
5. Jul 2012.
Skripta koju koristim: GF edit
Detaljan opis problema: Ubacio sam /statse u textdrawse pomoću ovog tutorijala http://balkan-samp.com/forum/index.php?topic=41876.0 ali izbacuje mi errore.
Dio skripte:
Evo linije:
1099--
Preimenovao sam sve u Stats2 pošto imam već statse druge.
Ostale linije:
-1553
Neke slike/video za lakse dobivanje pomoci(neobavezno): /
Detaljan opis problema: Ubacio sam /statse u textdrawse pomoću ovog tutorijala http://balkan-samp.com/forum/index.php?topic=41876.0 ali izbacuje mi errore.
Dio skripte:
(1099) : error 010: invalid function or declaration
(1553) : error 010: invalid function or declaration
(1554) : error 010: invalid function or declaration
(1557) : error 010: invalid function or declaration
(1560) : error 010: invalid function or declaration
Evo linije:
1099--
Stats2Text = TextDrawCreate(260.000000, 150.000000,"Racun");//1
TextDrawAlignment(Stats2Text,0);
TextDrawBackgroundColor(Stats2Text,255);
TextDrawFont(Stats2Text,1);
TextDrawLetterSize(Stats2Text,0.259999,0.600000);
TextDrawColor(Stats2Text,-1);
TextDrawSetOutline(Stats2Text,1);
TextDrawSetProportional(Stats2Text,1);
TextDrawSetShadow(Stats2Text,1);Preimenovao sam sve u Stats2 pošto imam već statse druge.
Ostale linije:
-1553
if (strcmp(cmd, "/account", true) == 0)
{ if(Pokrenuti == 0)
{
Stats2(playerid,playerid);
Pokrenuti = 1;
}
}
return 1;
}Neke slike/video za lakse dobivanje pomoci(neobavezno): /
Enforcer
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
332
Postovi:
27
Teme:
Pridružio se:Feb. 2012
5. Jul 2012.
probaj ovako:
if (strcmp(cmd, "/account", true) == 0)
{
if(Pokrenuti == 0)
{
Stats2(playerid,playerid);
Pokrenuti = 1;
}
}
return 1;
}Godfather
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
240 / 250 XP
Početnik(0)
1,519
Postovi:
30
Teme:
Pridružio se:Jun 2010
5. Jul 2012.
Ovu liniju:
Zamijeni ovom:
A za ostalo, postaj Stats2() funkciju.
Stats2Text = TextDrawCreate(260.000000, 150.000000,"Racun");//1Zamijeni ovom:
Stats2Text = TextDrawCreate(260.000000, 150.000000,"Racun");//1A za ostalo, postaj Stats2() funkciju.
Made Man
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
385
Postovi:
93
Teme:
Pridružio se:Sep. 2011
5. Jul 2012.
Nema public Stats2, pratio sam tutorijal ovaj - http://balkan-samp.com/forum/index.php?topic=41876.0
Made Man
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
385
Postovi:
93
Teme:
Pridružio se:Sep. 2011
5. Jul 2012.
Uradio sam sve sada i prikazuje mi sada error manje.
Evo linija:
(18740) : fatal error 107: too many error messages on one line
(18740) : error 012: invalid function call, not a valid address
(18740) : error 001: expected token: ";", but found ")"
(18740) : error 029: invalid expression, assumed zero
Evo linija:
if (strcmp(cmd, "/documents", true) == 0)
{
if(GetPlayerState(playerid) != 2)
{
if(Pokrenuti == 0)
{
Documents(playerid,playerid); (18740 - LINIJA)
Pokrenuti = 1;
}else{SCM(playerid, -1, " Nemozete gledati statse tijekom vožnje !");}
}
return 1;
}Made Man
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
385
Postovi:
93
Teme:
Pridružio se:Sep. 2011
5. Jul 2012.
stock Documents(playerid, player)
{
format(string,sizeof(string),"Ime i prezime : %s~n~~n~Novac: %d$~n~",GetName(playerid),GetPlayerMoney(playerid),);
TextDrawSetString(Documents, string); //
ShowDocuments(playerid, player);//ovo ću objasniti u idućem koraku (korak 4 )
return 1;
}Made Man
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
385
Postovi:
93
Teme:
Pridružio se:Sep. 2011
5. Jul 2012.
(4980) : error 028: invalid subscript (not an array or too many subscripts): "PlayerDB"
(4980) : warning 215: expression has no effect
(4980) : error 001: expected token: ";", but found "]"
(4980) : error 029: invalid expression, assumed zero
(4980) : fatal error 107: too many error messages on one line
Linija:
PlayerDB = dini_Int(FileDB,"Ubojstva");Evo ne izbacuje mi vise tu errore ali sada izbaci jos ova 4 na jednoj liniji.
Made Man
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
385
Postovi:
93
Teme:
Pridružio se:Sep. 2011
6. Jul 2012.
if (strcmp("/account", cmdtext, true) == 0)
{
if(PlayerInfo == true)
{
PlayerInfo = false;
TextDrawShowForPlayer(playerid, PlayerStats);
TextDrawShowForPlayer(playerid, Textdraw99);
}
new FileDB;
new Name;
GetPlayerName(playerid, Name , sizeof(Name));
format(FileDB,sizeof(FileDB) , PlayerInfo_DB ,Name);
if(!dini_Exists(FileDB)) {
dini_Create(FileDB);
dini_Set(FileDB, "Ime" ,Name);
dini_IntSet(FileDB, "Ubojstva" ,0);
dini_IntSet(FileDB, "Smrti" ,0);
}
PlayerInfo = dini_Int(FileDB,"Ubojstva");
PlayerInfo = dini_Int(FileDB,"Deaths");
PlayerInfo = dini_Int(FileDB,"Level");
PlayerInfo = dini_Int(FileDB,"Respekti");
return 1;
}To je ta komanda kada ukucam /account prikaže mi Ubojstva, Smrti, Level i Respekte.
Btw. da vas pitam kada nesto pobrisem i kada kompajlam nema errora udjem IG i radi sve kako treba, ali kada ubacim kako treba da bude skripta onda izbacuje error playerid i to na liniji gdje su Ubojstva, Smrti, Level, Respekti linija:
public StatsInfromation() {
new str;
for(new i=0;i {
if (IsPlayerConnected(i))
{
format(str, sizeof(str), "Ubojstva: ~w~%d ~n~Smrti: ~w~%d ~n~Level: ~w~%d ~n~Respekti: ~w~%d/%d" , PlayerInfo, PlayerInfo, PlayerInfo, PlayerInfo);
TextDrawSetString(PlayerStats,str);
}
}
return 1;
}Mozete li mi reci jos sto ne radi level i respekti kada sam sve lijepo definisao i uradio kako treba ? izbacuj playerid error.
Morate biti prijavljeni da biste odgovorili na ovu temu.
Prijava