SA-MP Forums Archive
errors - 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: errors (/showthread.php?tid=422680)



errors - Gold_Master - 14.03.2013

(1050) : warning 202: number of arguments does not match definition
(89) : error 001: expected token: "-string end-", but found "-identifier-"
(89) : error 001: expected token: "-string end-", but found "-identifier-"
(89) : warning 215: expression has no effect
(89) : error 001: expected token: ";", but found "-integer value-"
(89) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


4 Errors.

format(string,sizeof(string),"{458B00}Na Prodazba! \n{0x0033FF}Adresa: {FFFFFF}%d \n"PLAVA"Cena:{FFFFFF}$%d\n"ZUTA"Level:{FFFFFF}% d \n"PLAVA"Opis:{FFFFFF}%s",StanInfo[s][sWorld], StanInfo[s][sCena],StanInfo[s][sLevel], StanInfo[s][sOpis]);

helpp!


Re: errors - Gold_Master - 15.03.2013

refresh!


Re: errors - P3DRO - 15.03.2013

is the format(...); the code at line 89? if so you cant use "{458B00}Na Prodazba! \n{0x0033FF}Adresa: {FFFFFF}%d \n"PLAVA"Cena: either use 'PLAVA'Cena: or \"PLAVA\"Cena

PS: i think it is \", but in case im mistaken just use the ', " is "reserved"


Re: errors - Konstantinos - 15.03.2013

Example of usage:
pawn Код:
#define WHITE "{FFFFFF}"
#define BLACK "{000000}"

// somewhere
format( string, 128, "This is a text with "WHITE"color or "#BLACK"color!" );



Re: errors - Gold_Master - 15.03.2013

i donґt under stand :/


Re: errors - Konstantinos - 16.03.2013

How did you define "PLAVA" and "ZUTA"?


Re: errors - Gold_Master - 16.03.2013

#define PLAVA 0x2641FEAA
#define ZUTA 0xDABB3EAA


Re: errors - mineralo - 16.03.2013

pawn Код:
#define PLAVA "2641FEAA"
#define ZUTA "DABB3EAA"



Re: errors - Konstantinos - 17.03.2013

Quote:
Originally Posted by Gold_Master
Посмотреть сообщение
#define PLAVA 0x2641FEAA
#define ZUTA 0xDABB3EAA
That's why. It's an incorrect way when you're using it like that.
It should be:

pawn Код:
#define PLAVA "{2641FE}"
#define ZUTA "{DABB3E}"
And note that you can't use it like this:
pawn Код:
SendClientMessage( playerid, PLAVA, string );
In case you want to use it like this just change to:
pawn Код:
#define PLAVA_ 0x2641FEAA
#define ZUTA_ 0xDABB3EAA
and then
pawn Код:
SendClientMessage( playerid, PLAVA_, string );