How to make it say when a player teleports and where to?
#1

Hey,

How do i make it say when a player has teleported and where they have teleported to? For example "Sampiscool123 has teleported to the abondened airport! /aa to go there!"

Thank You
Reply
#2

Search for the zone script.
Reply
#3

SendClientMessageToAll(YOURCOLORHERE, %s has teleported to the abandoned airport! /aa to go there!,sendername);

I used that on my PowerX beta server I was planning to develope, worked well.

Post if you get errors.
Reply
#4

: error 017: undefined symbol "sendername"
Reply
#5

Quote:
Originally Posted by Sampiscool123
: error 017: undefined symbol "sendername"
Код:
GetPlayerName(playerid, sendername, sizeof(sendername));
SendClientMessageToAll(YOURCOLORHERE, "%s has teleported to the abandoned airport! /aa to go there!",sendername);
Try it now. It should work.
Reply
#6

You need to define the sendername:
pawn Код:
new
    sendername[MAX_PLAYER_NAME];
Reply
#7

Under your teleport command:
Код:
	new string[128];
	format(string,128,"%s has teleported to area (/command)",ReturnPlayerName(playerid));
	SendClientMessageToAll(COLOR_,string);
Somewhere in the gamemode/filterscript:
Код:
stock ReturnPlayerName(playerid) //By Alex "******" Cole
{
	new pname[MAX_PLAYER_NAME];
	pname="Invalid PlayerID";
	if(IsPlayerConnected(playerid))
	{
		GetPlayerName(playerid, pname, sizeof (pname));
	}
	return pname;
}
Easiest way imo.
Reply
#8

Thank You
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)