SA-MP Forums Archive
Please help - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Please help (/showthread.php?tid=218600)



Please help - NewbBeginner - 30.01.2011

Код:
case CODE:
		{
		if(!response)
  		{
      		//Cancel
			return 1;
		}
		if(!strlen(inputtext))
		{
  			// Didn't insert anything
			return 1;
		}
		new
			CODE = strlen(inputtext),
			MYCODE = strlen(pInfo[playerid][pCode])
		;
		if(CODE != MYCODE)
		{
   			SendClientMessage(playerid, -1, "Wrong code");
		}
		else
		{
			SendClientMessage(playerid, -1, "Right code");
			}
		}
Even If I isert the right code, it says wrong code, Whats wrong.


Re: Please help - JaTochNietDan - 30.01.2011

Well, what's the value of the "pInfo[playerid][pCode]" variable and what are you writing into the text box?


Re: Please help - NewbBeginner - 30.01.2011

Im writing 123 into text box, because my CODE is 123, I did a command, /mycode, and it showed pinfo[playerid][pcode], so it is 123.


Re: Please help - NewbBeginner - 31.01.2011

Help please !


Re: Please help - Vince - 31.01.2011

Quote:
Originally Posted by NewbBeginner
Посмотреть сообщение
pawn Код:
case CODE:
new CODE = strlen(inputtext),
Rename that variable to something else.


Re: Please help - ricardo178 - 31.01.2011

And btw use [pawn] tags instead [code] ones... It help when we look at the script