Posts: 319
Threads: 7
Joined: Jul 2012
Reputation:
0
If it's exactly in the middle:
(x1 + x2) / 2 = (-121.1 + -2071.3) / 2 = -2192.4 / 2 = -1096.2
(y1 + y2) / 2 = (3583.52 + 1603.2) / 2 = 5186.72 / 2 = 2593.36
(z1 + z2) / 2 = (16.1 + 49.5) / 2 = 65.6 / 2 = 32.8
Just take the average of both coordinates.
Posts: 1,208
Threads: 36
Joined: Apr 2015
I recommend:
PHP код:
GetPointFor2Point2D(Float:x1,Float:y1,Float:x2,Float:y2,Float:percent_size,&Float:tx,&Float:ty);
GetPointFor2Point3D(Float:x1,Float:y1,Float:z1,Float:x2,Float:y2,Float:z2,Float:percent_size,&Float:tx,&Float:ty,&Float:tz);
Point 1-> aims Point 2
percent_size // 0.0 - 100.0
https://github.com/AbyssMorgan/SA-MP...SAM/3DTryg.inc