[HELP]dcmd_gotohouse -
pitchooo - 11.02.2015
Hello,
use Garhouse FS how can I do the command /gotohouse can use it all
Код:
dcmd_gotohouse(playerid, params[])
{
new h, file[HOUSEFILE_LENGTH];
if(!IsPlayerAdmin(playerid)) return 0;
if(sscanf(params, "d", h)) return SendClientMessage(playerid, COLOUR_SYSTEM, E_CMD_USAGE_GOTOHOUSE);
format(file, sizeof(file), FILEPATH, h);
if(!dini_Exists(file)) return SendClientMessage(playerid, COLOUR_SYSTEM, E_INVALID_HID);
else
{
SetPlayerPosEx(playerid, dini_Float(file, "SpawnOutX"), dini_Float(file, "SpawnOutY"), dini_Float(file, "SpawnOutZ"), dini_Int(file, "SpawnInterior"), dini_Int(file, "SpawnWorld"));
SendMSG(playerid, COLOUR_YELLOW, 128, I_TELEPORT_MSG, h);
}
return 1;
}
And to add the command / myhouses
As I write to teleport into their house?
Re: [HELP]dcmd_gotohouse -
Eth - 11.02.2015
pawn Код:
dcmd_gotohouse(playerid, params[])
{
new h, file[HOUSEFILE_LENGTH];
if(sscanf(params, "d", h)) return SendClientMessage(playerid, COLOUR_SYSTEM, E_CMD_USAGE_GOTOHOUSE);
format(file, sizeof(file), FILEPATH, h);
if(!dini_Exists(file)) return SendClientMessage(playerid, COLOUR_SYSTEM, E_INVALID_HID);
else
{
SetPlayerPosEx(playerid, dini_Float(file, "SpawnOutX"), dini_Float(file, "SpawnOutY"), dini_Float(file, "SpawnOutZ"), dini_Int(file, "SpawnInterior"), dini_Int(file, "SpawnWorld"));
SendMSG(playerid, COLOUR_YELLOW, 128, I_TELEPORT_MSG, h);
}
return 1;
}
this will allow everyone to use this command
Re: [HELP]dcmd_gotohouse -
Sew_Sumi - 11.02.2015
Quote:
Originally Posted by Eth
this will allow everyone to use this command
|
I don't think that's what he asked for... I think he wants it to go to the interior, hence why he said "in to", rather than "go to"...
Re: [HELP]dcmd_gotohouse -
pitchooo - 11.02.2015
Quote:
Originally Posted by Eth
pawn Код:
dcmd_gotohouse(playerid, params[]) { new h, file[HOUSEFILE_LENGTH]; if(sscanf(params, "d", h)) return SendClientMessage(playerid, COLOUR_SYSTEM, E_CMD_USAGE_GOTOHOUSE); format(file, sizeof(file), FILEPATH, h); if(!dini_Exists(file)) return SendClientMessage(playerid, COLOUR_SYSTEM, E_INVALID_HID); else { SetPlayerPosEx(playerid, dini_Float(file, "SpawnOutX"), dini_Float(file, "SpawnOutY"), dini_Float(file, "SpawnOutZ"), dini_Int(file, "SpawnInterior"), dini_Int(file, "SpawnWorld")); SendMSG(playerid, COLOUR_YELLOW, 128, I_TELEPORT_MSG, h); } return 1; }
this will allow everyone to use this command
|
Not working
Re: [HELP]dcmd_gotohouse -
Sew_Sumi - 11.02.2015
Quote:
Originally Posted by pitchooo
Not working
|
It should, what it should be doing is if you use that command is it should put you at the door/entrance to that house.
The only thing he actually did though was remove the IsPlayerAdmin, so in essence anyone could use that command.
Link to the thread with the FS you have used so that we can see more.
And clarify what you're wanting, whether you want them in the house, or just out the door...
Do you want everyone rather than just admins to be able to use it?
Re: [HELP]dcmd_gotohouse -
pitchooo - 12.02.2015
Once removed IsPlayerAdmin command /gotohouse work.
But hides the icon to enter the house
Re: [HELP]dcmd_gotohouse -
Sew_Sumi - 13.02.2015
Quote:
Originally Posted by pitchooo
Once removed IsPlayerAdmin command /gotohouse work.
But hides the icon to enter the house
|
That suggests something else other than a fail.
Is it working as intended, minus the pickup issue?
Do you have any other script portions that relate and use pickups?