Problem with Houses and Businesses - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Problem with Houses and Businesses (
/showthread.php?tid=115828)
Problem with Houses and Businesses -
kukars22 - 26.12.2009
Hello everyone... I've got a house and biz system.
When people buy House or Business he automaticaly teleports in this biz or house.
Of course Doors are locked for this house/biz, but the thing is. This owner cant unlock doors, when hes inside.
Server says, than hes not an owner of this busines.. Maybe someone can help me.
Код:
if(strcmp(cmd, "/openhouse", true) == 0)
{
if(IsPlayerConnected(playerid))
{
for(new i = 0; i < sizeof(Houses); i++)
{
if (PlayerToPoint(3.0, playerid,Houses[i][EnterX], Houses[i][EnterY], Houses[i][EnterZ]) || PlayerToPoint(3.0, playerid,Houses[i][ExitX], Houses[i][ExitY], Houses[i][ExitZ]))
{
if(PlayerInfo[playerid][pHouseKey] == i)
{
if(Houses[i][Locked] == 1)
{
Houses[i][Locked] = 0;
SendClientMessage(playerid, COLOR_LIGHTYELLOW2,"[INFO:] Durvis Atvērtas.");
PlayerActionMessage(playerid,15.0,"izvelk atslēgu no kabatas un atslēdz durvis.");
SaveHouses();
return 1;
}
if(Houses[i][Locked] == 0)
{
Houses[i][Locked] = 1;
SendClientMessage(playerid, COLOR_LIGHTYELLOW2,"[INFO:] Durvis Aizslēgtas.");
PlayerActionMessage(playerid,15.0,"izvelk atslēgu no kabatas un aizslēdz durvis.");
SaveHouses();
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_LIGHTYELLOW2,"[ERROR:] Tev nav atslēgas љai mājai!");
return 1;
}
}
}
}
return 1;
}
THis is /penhouse command
(no its not)
Re: Problem with Houses and Businesses -
Grim_ - 26.12.2009
Ask in this scripts topic.
Re: Problem with Houses and Businesses -
kukars22 - 28.12.2009
Quote:
Originally Posted by _Xerxes_
Ask in this scripts topic.
|
well no
P.S Anyone know?