What i do wrong - 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: What i do wrong (
/showthread.php?tid=79588)
What i do wrong -
TehNobody - 29.05.2009
It doesnt work how i want it to be, is it only because i dunno how to tell teh script that it has to be in interior 6?
Код:
if (strcmp("/rob", cmdtext, true, 10) == 0)
{
new intr = GetPlayerInterior(playerid);
new Float:x, Float:y, Float:z;
GetPlayerPos(playerid, x, y, z);
new rndm2 = random(10000);
new rndm = random(52);
{
if PlayerToPoint(playerid, 5, -29.1725,-57.2973,1003.5469) (intr == 6) *then
if (rndm == 50)
GivePlayerMoney(playerid, rndm2); }
{
if ((x <= -29.1725) && (y <= -57.2973) && (z <=1003.5469))
{
SendClientMessage(playerid, 0xFF0000AA, "There is no cash register near you");
}
if ((x >= -29.1725) && (y >= -57.2973) && (z >=1003.5469))
{
SendClientMessage(playerid, 0xFF0000AA, "There is no cash register near you");
}
}
return 1;
}
Re: What i do wrong -
ShadoW_StaH - 29.05.2009
if
(PlayerToPoint(playerid, 5, -29.1725,-57.2973,1003.5469)
)
i think that might have been the problem
Re: What i do wrong -
TehNobody - 29.05.2009
it doenst give any errors, in only keeps saying that im not near a cash register