All pastes #609890 Raw Edit

onplayerconnect

public text v1 · immutable
·published 2007-07-09 03:46 UTC
rendered paste body
public OnPlayerConnect(playerid)
{
    curPlayerCamD[playerid][CMODE] = CMODE_A;
    curPlayerCamD[playerid][RATE]  = 2.0;

    

	new string[256];
///this says we are adding a string and gives it 256 letters/numbers
	new cname[MAX_PLAYER_NAME];
//This means we are getting a players name
	GetPlayerName(playerid, cname, sizeof(cname));
//This gets the players name and stores it in the variable cname
	format(string, sizeof(string), "Player %s Has Joined The Funnest Server Ever!.", cname);
//This formats a text string....the %s is the name which after the text is declared to be cname
	#if ADMINS_ONLY == false
	AllowPlayerTeleport(playerid, 1);
	#endif
	ircSay("#FSE", "Player Has Joined The Funnest Server Ever!.");
 	SendClientMessageToAll(COLOR_GREEN,string);
	GameTextForPlayer(playerid,"~g~Welcome to the Funnest Server EVER!",1000,0);
	return 1;
}