Need little help with SendClientMessage.
#1

I tried many times but it won't come out.
What i want to do, is that when player name isn't Steven_Hayen, then he/she can't teleport. And server send text to him (ex. You don't have permissions! or something like that)

Teleport code is here.

pawn Код:
if (strcmp(cmdtext, "/telealla", true)==0)
    {
    GetPlayerName(playerid,pName,64);
    if(!strcmp(pName,"Steven_Hayen",true)) // Change Name_Name to your name.
    {
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
    {
    SetPlayerInterior(playerid, 0);
    LinkVehicleToInterior(GetPlayerVehicleID(playerid), 0);
    SetVehiclePos(GetPlayerVehicleID(playerid), 260.1984,-1230.9200,58.5478);
    SetVehicleZAngle(GetPlayerVehicleID(playerid), 180.945861);
    return 1;
    }
    else
    {
    SetPlayerInterior(playerid, 0);
    SetPlayerPos(playerid, 260.1984,-1230.9200,58.5478);
    SetPlayerFacingAngle(playerid, 180.945861);
    return 1;
    }
    }
    }
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 3 Guest(s)