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



Warning 203 - Rissam - 13.12.2014

Quote:

SetPlayerToTeamColor(playerid)
{
if(gTeam[playerid] == TEAM_TERRORISTS)
{
SetPlayerColor(playerid,TEAM_COLOR_TERRORISTS);
}
else if(gTeam[playerid] == TEAM_COUNTERTERRORISTS)
{
SetPlayerColor(playerid,TEAM_COLOR_COUNTERTERRORIS TS);
}
return 1;
}

It says
Quote:

warning 203: symbol is never used: "SetPlayerToTeamColor"

Please help


Re: Warning 203 - ConnorHunter - 13.12.2014

Show us where you define SetPlayerToTeamColor


Re: Warning 203 - Ox1gEN - 13.12.2014

I believe this occurs by two flaws.
1. You have created a stock function which you do not use.
2. You have created a variable which you do not use.


Note, if you create a variable and attach it to something, even though it looked like you used it, you didn't because you just defined what that variable is.


Re: Warning 203 - Rissam - 13.12.2014

Quote:
Originally Posted by ConnorHunter
Посмотреть сообщение
Show us where you define SetPlayerToTeamColor
I haven't and tell me how to define?


Re: Warning 203 - MythicalMarauder - 13.12.2014

You have already defined it;
pawn Код:
SetPlayerToTeamColor(playerid)
{
if(gTeam[playerid] == TEAM_TERRORISTS)
{
SetPlayerColor(playerid,TEAM_COLOR_TERRORISTS);
}
else if(gTeam[playerid] == TEAM_COUNTERTERRORISTS)
{
SetPlayerColor(playerid,TEAM_COLOR_COUNTERTERRORIS TS);
}
return 1;
}
Now go under OnPlayerSpawn(playerid) or anywhere, use it like this:

pawn Код:
SetPlayerToTeamColor(playerid);
You have defined it, but you did not use it, that's why PAWN has warned you.


Re: Warning 203 - Rissam - 14.12.2014

Now no warning or error but in running the server it says:

Quote:

[00:45:11] Script[gamemodes/RGTDM.amx]: Run time error 19: "File or function is not found

"

please help


Re: Warning 203 - JeaSon - 14.12.2014

use nativechecker then post logs here


Re: Warning 203 - Rissam - 14.12.2014

Quote:
Originally Posted by Namer
Посмотреть сообщение
use nativechecker then post logs here
yeah I found the mistake I removed streamer from plugins lines in server.cfg and by the way thanks to all of u for helping me.