SA-MP Forums

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

Thread Tools Display Modes
Old 10/04/2010, 01:35 PM   #1
Big Clucker
Join Date: Aug 2009
Posts: 105
Reputation: 1
Default Problem with /goto command

Hey there. I have a little problem with this command

dcmd_goto(playerid, id[])
	new pname[MAX_PLAYER_NAME], file[256], string[256], alvl[256];
	GetPlayerName(playerid, pname, sizeof(pname));
	format(file, sizeof(string), "\\Users\\%s.ini", pname);
	if(!logged[playerid]) SendClientMessage(playerid, COLOR_RED, "You are not logged in!");
		alvl = dini_Get(file, "level");
	  		SendClientMessage(playerid, COLOR_RED, "You have teleported to the ID");
				SetPlayerPos(playerid, id);
			  SendClientMessage(playerid, COLOR_RED, "You are not allowed to use this command!");
			return 1;
	else SendClientMessage(playerid, COLOR_RED, "That player is not connected!");
	return 1;
I added this on top

new id[MAX_PLAYERS];
And I get these errors

gamemodes\registerorlogin.pwn(155) : warning 219: local variable "id" shadows a variable at a preceding level
gamemodes\registerorlogin.pwn(161) : error 035: argument type mismatch (argument 1)
gamemodes\registerorlogin.pwn(164) : error 033: array must be indexed (variable "-unknown-")
gamemodes\registerorlogin.pwn(169) : error 035: argument type mismatch (argument 2)
gamemodes\registerorlogin.pwn(175) : error 002: only a single statement (or expression) can follow each "case"
gamemodes\registerorlogin.pwn(175) : warning 215: expression has no effect
gamemodes\registerorlogin.pwn(157) : warning 204: symbol is assigned a value that is never used: "string"
gamemodes\registerorlogin.pwn(157 -- 178) : error 010: invalid function or declaration
gamemodes\registerorlogin.pwn(157 -- 179) : error 010: invalid function or declaration
gamemodes\registerorlogin.pwn(157 -- 179) : fatal error 107: too many error messages on one line
Could you help?
sobolanux is offline  

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
/goto and /bring cmd's problem billiout Help Archive 7 21/05/2010 10:50 AM
Plz help /goto problem zalyy Help Archive 22 03/05/2010 03:00 PM
How to make a /gethere «id» and /goto «id» command? Rubennnnn Help Archive 12 02/12/2009 05:42 AM
/getgun & /armour & /goto command WanabePC Help Archive 3 22/04/2009 06:49 PM

All times are GMT. The time now is 09:18 PM.

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