[Help]I need a special teleport(SOLVED) Subject Close
#12

Quote:
Originally Posted by ~ ????????? ~
pawn Code:
public OnPlayerSpawn(playerid)
{
    new name[24];
    GetPlayerName(playerid, name, 24);
    if(strcmp(name, "xXEdyXx") == 0)
    {
        SetPlayerPos(playerid,1574.1846,2839.3669,10.8203);
    }
    return 1;
}

the code i posted worked with him :



Quote:
Originally Posted by edycool
Quote:
Originally Posted by [AC
Etch ]
sorry , try this :
Code:
     new name[MAX_PLAYER_NAME];
	GetPlayerName(playerid, name, MAX_PLAYER_NAME);
	
     if(strcmp(name, "xXEdyXx") == 0)
	{
		SetPlayerPos(playerid,1574.1846,2839.3669,10.8203);
	}
The player is teleport to location 5 to 5 seconds
My Code
On Top
Code:
new name[MAX_PLAYER_NAME];
On OnPlayerSpawn(playerid)
Code:
public OnPlayerSpawn(playerid)
{
new playerid;
if(strcmp(name, "xXEdyXx") == 0)
{
SetPlayerPos(playerid,1574.1846,2839.3669,10.8203);
}
return 1;
}
Simple, I don't know why some people have posted a code like this without the GetPlayerName thing assigning the variable 'name' to the playerids name

Hope it works
________
Video Review
Reply


Messages In This Thread
[Help]I need a special teleport(SOLVED) Subject Close - by edycool - 05.03.2010, 11:45
Re: [Help]I need a special teleport - by aircombat - 05.03.2010, 11:54
Re: [Help]I need a special teleport - by edycool - 05.03.2010, 12:01
Re: [Help]I need a special teleport - by aircombat - 05.03.2010, 12:01
Re: [Help]I need a special teleport - by edycool - 05.03.2010, 12:04
Re: [Help]I need a special teleport - by qwt - 05.03.2010, 12:06
Re: [Help]I need a special teleport(unsolved) - by edycool - 05.03.2010, 12:08
Re: [Help]I need a special teleport(SOLVED) Or Not - by edycool - 05.03.2010, 12:15
Re: [Help]I need a special teleport(SOLVED) Or Not - by aircombat - 05.03.2010, 12:17
Re: [Help]I need a special teleport(SOLVED) Or Not - by edycool - 05.03.2010, 12:19
Re: [Help]I need a special teleport(SOLVED) Subject Close - by aircombat - 05.03.2010, 12:24
Re: [Help]I need a special teleport(SOLVED) Subject Close - by aircombat - 05.03.2010, 15:19

Forum Jump:


Users browsing this thread: 2 Guest(s)