SA-MP Forums Archive
warning 211: possibly unintended assignment - 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 211: possibly unintended assignment (/showthread.php?tid=546075)



warning 211: possibly unintended assignment - Stoyanov - 12.11.2014

Код:
if(InDM[killerid] = 1)
		{
		GivePlayerMoney(killerid, 400);
		new sscore = GetPlayerScore(killerid);
  		SetPlayerScore(killerid, sscore+1);
  		}
I've marked the line with warning.


Re: warning 211: possibly unintended assignment - M4D - 12.11.2014

you have to put ==

pawn Код:
if(InDM[killerid] == 1)
{
    GivePlayerMoney(killerid, 400);
    new sscore = GetPlayerScore(killerid);
    SetPlayerScore(killerid, sscore+1);
 }



Re: warning 211: possibly unintended assignment - Stoyanov - 12.11.2014

Ohh. yep. Thanks