House command help
#3

Little correct for you. You need set up targetid withhiss/her name who houses you want teleport.
pawn Код:
dcmd_house(playerid, params[])
{
    #pragma unused params
    new file[128];
        new giveplayerid, giveplayer[MAX_PLAYER_NAME], sendername[MAX_PLAYER_NAME];
        GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
        if(sscanf(params,"u",giveplayerid)) return SendClientMessage(playerid, COLOR_RED,"/house playerid/name");
    new Float:HouseX, Float:HouseY, Float:HouseZ;
    if(sscanf(params, "s", pname)) return SendClientMessage(playerid, COLOR_ORANGE, "/house <Name>");
    format(file, sizeof(file), "/xadmin/Users/%s.ini", pname);
    if(!dini_Exists(file))return SendClientMessage(playerid, COLOR_RED,"That Player doesn't have a house");
    HouseX = dini_Float(file, "HouseX");
    HouseY = dini_Float(file, "HouseY");
    HouseZ = dini_Float(file, "HouseZ");
    SetPlayerPos(playerid,HouseX,HouseY,HouseZ);
    return 1;
}
Reply


Messages In This Thread
House command help - by Tommeh - 13.08.2014, 02:07
Re: House command help - by Tommeh - 13.08.2014, 07:48
Re: House command help - by MacT - 13.08.2014, 08:12
Re: House command help - by Tommeh - 13.08.2014, 08:31
Re: House command help - by MacT - 13.08.2014, 08:40
Re: House command help - by Tommeh - 13.08.2014, 08:46
Re: House command help - by Don_Cage - 13.08.2014, 11:45
Re: House command help - by Tommeh - 13.08.2014, 19:09

Forum Jump:


Users browsing this thread: 2 Guest(s)