Why doesn't this work
#1

OKAY im really new here, I used to be a decent scripter like 3 years ago but then i stopped and now im back and cant remember anything, somone help me out with these basics:

Код:
public OnPlayerConnect(playerid)
{
	if GetPlayerName(playerid,"mrcoolballs")(
	SendClientMessage(playerid,0xAA3333AA,"яour to cool for school")else(
	SendClientMessage(playerid,0xAA3333AA,"yah you aint cool like mrcoolballs");

	return 1;
}
}
why doesn't it work?!?!?!?!
Reply
#2

lol its a failed code

Код:
public OnPlayerConnect(playerid)
{
   new name[MAX_PLAYER_NAME];
   GetPlayerName(playerid, name, MAX_PLAYER_NAME);
   if(!strfind(name, "mrcoolballs", true))
   {
      SendClientMessage(playerid,0xAA3333AA,"яour to cool for school")
   }
else
{
SendClientMessage(playerid,0xAA3333AA,"yah you aint cool like mrcoolballs");
}

  return 1;
}
Reply
#3

Код:
public OnPlayerConnect(playerid)
{
	new PlayerName[24]; 
        GetPlayerName(playerid, PlayerName, sizeof(PlayerName)); 
        if(!strcmp(PlayerName,"mrcoolballs",true))
        {
	    SendClientMessage(playerid,0xAA3333AA,"яour to cool for school");
        }	
        
        return 1;
}
i think that you mean.
Reply
#4

sorry if im wrong but wouldnt that send me the message yah you aint cool like mrcoolballs if my name was mrcoolballs,your forgetting the ! before strfind
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)