Payment time - 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)
+--- Thread: Payment time (
/showthread.php?tid=294315)
Payment time -
juraska - 01.11.2011
Hello guys, I have with payment time. I want to make that for all players which are business owner received payment in setted time, but in my code is send to all player.
How to do, that paments received only business owner?
my business owner variable Houses[playerid][house_owner]
here's my trying but, as I say it's isn't work corectly.
forward PaymentsTime(playerid);
public PaymentsTime(playerid)
{
foreach(Player,i)
{
if(strcmp(PlayerName(i),Houses[i][house_owner]) == 1)
{
new a=Houses[i][house_owner];
SendClientMessage(a,-1,"payments!");
}
}
return 1;
}
Thanks
Re: Payment time -
juraska - 01.11.2011
Any one ?!
Re: Payment time -
juraska - 01.11.2011


Re: Payment time -
Pinguinn - 01.11.2011
pawn Код:
foreach(Player, i)
{
if(Houses[i][ /* place the variable here to check if he owns a house */ ] == true)
{
SendClientMessage(i, -1, "Payments!");
GivePlayerMoney(i, [money here]);
}
}
Re: Payment time -
juraska - 01.11.2011
Hmm same sh^^ can you suggest another way