SA-MP Forums Archive
Pool Help - 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: Pool Help (/showthread.php?tid=206618)



Pool Help - sushihusi - 04.01.2011

Hello!

I have seen niCe's pool script and I started to create a pool script. Its almost finished but I need 1 thing.
I have marked my balls with p[16], so p[0],p[1],p[2]. The White Ball's objectid is the p[0].

How to get when the pool ball bumps another pool ball??

I have tried this:

Код:
for(new i;i<16;i++)
{
for(new d;d<16;d++)
{
new Float:Xa,Float:Ya,Float:Za,Float:X,Float:Y;
GetObjectPos(p[i],Xa,Ya,Za);
GetObjectPos(p[d],X,Y,Za);
if(0.075>=GetPointDistanceToPoint(X,Y,Xa,Ya)>=0.05 && IsMoving[i]==1)
{
OnBallBumpBall(i,d);
}
}
}
So my question is: How to get when the pool ball bumps another pool ball??

PS: sorry for my bad english


Re: Pool Help - Stricica - 04.01.2011

Uhh...I do not know...

Cső Bart...


Re: Pool Help - sushihusi - 05.01.2011

Csб

Nobody??