SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 28/12/2013, 04:23 AM   #1
vn007322815
Little Clucker
 
Join Date: Sep 2013
Posts: 35
Reputation: 0
Cool error 017: undefined symbol "string"

Code:
C:\Documents and Settings\user\Desktop\server samp\gamemodes\testserver.pwn(32) : error 017: undefined symbol "string"
C:\Documents and Settings\user\Desktop\server samp\gamemodes\testserver.pwn(32) : error 017: undefined symbol "string"
C:\Documents and Settings\user\Desktop\server samp\gamemodes\testserver.pwn(32) : error 029: invalid expression, assumed zero
C:\Documents and Settings\user\Desktop\server samp\gamemodes\testserver.pwn(32) : fatal error 107: too many error messages on one line
Code:
YCMD:tutorial(playerid, params[], help)
{
	if(IsPlayerConnected(playerid))
	{
		if (gPlayerLogged[playerid] != 0)
		{
		    if(IsOnTutorial[playerid] == 0)
		    {
			    if(PlayerInfo[playerid][pTutDone] == 20) { SendClientMessage(playerid, COLOR_GREY, "You have Already Finished your tutorial!"); return 1; }
       			else if(PlayerInfo[playerid][pTutDone] == 0) { SetPlayerCheckpoint(playerid, 1618.4030,-2329.7612,13.5469, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 1) { SetPlayerCheckpoint(playerid, 1689.5321,-2239.2610,-2.71079, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
      			else if(PlayerInfo[playerid][pTutDone] == 2) { SetPlayerCheckpoint(playerid, 1480.3043,-1739.3135,13.5469, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
	        	else if(PlayerInfo[playerid][pTutDone] == 3) { SetPlayerCheckpoint(playerid, 1547.4700,-1675.7671,14.0981, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 4) { SetPlayerCheckpoint(playerid, 1463.3116,-1023.6773,23.8331, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 5) { SetPlayerCheckpoint(playerid, 1364.3809,-1279.9447,13.5469, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 6) { SetPlayerCheckpoint(playerid, 1178.4044,-1323.0798,14.1184, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 7) { SetPlayerCheckpoint(playerid, 2229.1575,-1727.0540,13.5469, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 8) { SetPlayerCheckpoint(playerid, 2243.9365,-1660.2887,15.2879, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 9) { SetPlayerCheckpoint(playerid, 483.6973,-1489.8641,20.0528, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 10) { SetPlayerCheckpoint(playerid, 555.0895,-1261.9196,17.2422, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 11) { SetPlayerCheckpoint(playerid, 1510.0883,-1430.9789,13.5469, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 12) { SetPlayerCheckpoint(playerid, 2048.8523,-1900.5702,13.5538, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 13) { SetPlayerCheckpoint(playerid, 1524.1573,-1674.2922,13.5469, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        else if(PlayerInfo[playerid][pTutDone] == 14) { SetPlayerCheckpoint(playerid, 1463.3116,-1023.6773,23.8331, 2); GameTextForPlayer(playerid, "~w~Head to the ~r~Checkpoint", 6000, 3); }
		        IsOnTutorial[playerid] = 1;
		        new Float:X,Float:Y,Float:Z;
				PlayerPlaySound(playerid, 1057, X,Y,Z);
				new d,m,y;
				new h,mi,s;
				getdate(y,m,d);
				gettime(h,mi,s);
				format(string, sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s has Typed '/tutorial'",d,m,y,h,mi,s,sendername);
				CommandLog(string);
			}
			else
			{
   				SendClientMessage(playerid, COLOR_GREY, "You are already on the tutorial, Type /canceltutorial to Cancel it!");
			    return 1;
			}
		}
		else
		{
  			SendClientMessage(playerid, COLOR_GREY, "You are not Logged in!");
	    	return 1;
		}
	}
	return 1;
}
pls help me fix
vn007322815 is offline   Reply With Quote
Old 28/12/2013, 04:32 AM   #2
Copfan5
Little Clucker
 
Join Date: Dec 2012
Posts: 42
Reputation: 1
Default Re: error 017: undefined symbol "string"

Which line is line 32?
Copfan5 is offline   Reply With Quote
Old 28/12/2013, 04:39 AM   #3
ghost556
Big Clucker
 
ghost556's Avatar
 
Join Date: Jun 2012
Location: Sydney, Australia
Posts: 109
Reputation: 8
Default Respuesta: error 017: undefined symbol "string"

Code:
 new string[128];
Try adding that to your script, you just may need to change the "128" to an appropriate number.
__________________

Moderator Bradley_Ryan
Roleplay Characters: Khyle_Thomas/Bradley_Ryan
ghost556 is offline   Reply With Quote
Old 28/12/2013, 05:15 AM   #4
vn007322815
Little Clucker
 
Join Date: Sep 2013
Posts: 35
Reputation: 0
Default Re: error 017: undefined symbol "string"

Quote:
Originally Posted by Copfan5 View Post
Which line is line 32?
line 32

Code:
format(string, sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s has Typed '/tutorial'",d,m,y,h,mi,s,sendername);
can you help me fix it?
vn007322815 is offline   Reply With Quote
Old 28/12/2013, 05:18 AM   #5
Riddick94
Banned
 
Join Date: Mar 2010
Location: Poland
Posts: 1,767
Reputation: 223
Default Re: error 017: undefined symbol "string"



Sorry, but I had to do it. I don't know how many times people will come to this forum with same problem over and over again. Did you actually tried to put:

Code:
error 017
To your web search tool? So, easy and way faster to get your problem solved. Trust me.
Riddick94 is offline   Reply With Quote
Old 28/12/2013, 07:35 AM   #6
vn007322815
Little Clucker
 
Join Date: Sep 2013
Posts: 35
Reputation: 0
Default Re: error 017: undefined symbol "string"

thank u so much for every body . i fixed
vn007322815 is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
error 017: undefined symbol "string" MoNsTeR_EnErGy Scripting Help 4 10/09/2012 10:17 AM
Error 017: undefined symbol "string" MrSnapp Scripting Help 5 24/08/2012 11:19 AM
5 Dialog errors - Input line too long, undefined symbol "t","is" and "only" Deal-or-die Scripting Help 6 01/05/2012 12:08 PM


All times are GMT. The time now is 04:11 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.