String problem - 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: String problem (
/showthread.php?tid=347890)
String problem -
SkL_MD - 03.06.2012
I have a problem with strings ..
I added a FS GM and I have some errors:
Код:
(2025) : error 052: multi-dimensional arrays must be fully initialized
Код:
new Float:ZoneLocations[MAX_ZONES][9] = {
{1980.431, -1464.736, 2261.841, -1342.356}, //crips
{2330.292, -1748.974, 2524.237, -1626.594}, //bloods
{1672.401, -2167.434, 1961.417, -2013.472}, // surenos
{2105.925, -1306.826, 2250.432, -994.9549}, //nortenos
{-2062.492, 1225.256, -1923.435, 1292.32},// groovegang
{-2738.462, 791.31, -2599.405, 882.0442}, // ballasgang
{-2139.745, -64.74727, -1907.984, 337.6391}, // nodmzone
{1025.919, -2124.009, 1375.78, -1966.099}, // Lcnzone
{938.454, -1587.116, 1086.765, -1318.672} // Triadszone
};
Код:
(4744) : error 017: undefined symbol "str"
Код:
// send the message
GetPlayerName(killerid, string, sizeof(string));
SendClientMessageToAll(COLOR_RED," ");
format(string, sizeof(string), "*** GangZone Message: %s a intrat in echipa %s si apara un teritoriul celor din %s", str,GangInfo[ gTeam[killerid] ][GangName], GangInfo[ gTeam[playerid] ][GangName] ); //asta-i linia
SendClientMessageToAll(GetPlayerColor(killerid), string);
SendClientMessageToAll(COLOR_RED," ");
Код:
(4762) : error 017: undefined symbol "GetPlayaderColor"
Код:
GangZone_CurrentColour[ zone ] = GetPlayaderColor(killerid);
Код:
(4784) : error 017: undefined symbol "str"
(4784) : error 017: undefined symbol "str"
(4784) : error 029: invalid expression, assumed zero
(4784) : fatal error 107: too many error messages on one line
Код:
GetPlayerName(killerid, str, sizeof(str)); //ata-i linia
format(string, sizeof(string)," ");
format(string, sizeof(string), "%s contra %s a inceput razboiul contra %s ", str,GangInfo[ gTeam[killerid] ][GangName], GangInfo[ gTeam[playerid] ][GangName] );
SendClientMessageToAll(GetPlayerColor(killerid), str);
SendClientMessageToAll(COLOR_RED," ");
GangZoneFlashForAll(zone, GetPlayerColor(killerid) );
Who knows please help me and nice to me.
Re: String problem -
leonardo1434 - 03.06.2012
About the other commands, i don't know how is made to fix it.
pawn Код:
new str[256] // string...
GetPlayerColor(playerid); // right one..