dcmd_goto
#1

how would i add it so when you goto somebody on this command it teleports you to the interior their in aswell

because if somebodys in a interior and another person is in interior 0 and teleports to them it gets rly bugged

thanks


Код:
dcmd_goto(playerid,params[]){
    if(PInfo[playerid][Level] < 1) return SendClientMessage(playerid,red,"Your Not Allowed To Use This Command!");
    new id,string[128];
    if (sscanf(params,"u",id)) return SendClientMessage(playerid,LIGHTBLUE,"Usage: /goto [playerid]");
    if(!IsPlayerConnected(id)) return SendClientMessage(playerid,GREEN,"Player not connected");
    
    new Float:x,Float:y,Float:z;
    GetPlayerPos(id,x,y,z);
    if (IsPlayerInAnyVehicle(playerid)) {
        SetVehiclePos(GetPlayerVehicleID(playerid),x+3,y,z);
    } else {
	SetPlayerPos(playerid,x+3,y,z);
	}
    new pName[32];
    GetPlayerName(id,pName,32);
    format(string,sizeof string,"||You have teleported to %s||",pName);
    SendClientMessage(playerid,YELLOW,string);
    return 1;
}
Reply


Messages In This Thread
dcmd_goto - by hadzx - 28.03.2011, 19:55
Re: dcmd_goto - by xir - 28.03.2011, 20:15
Re: dcmd_goto - by hadzx - 28.03.2011, 20:20

Forum Jump:


Users browsing this thread: 2 Guest(s)