GetClosestCar problem.
#7

Is the forklift ID in (IsATruck)? That would be the only cause for the reason i removed:
Quote:

Its because most vehicle positions are the Center of the Vehicle. Let me explain.

[ x ] Truck
[ x ] Forklift.
[x] Box

Now I havn't read you code but I am assuming your using the Box position to find the closest vehicle however that wouldn't work is your cars are arranged like this:

[ x ][x][ x ]

In this example the Center of the box is closest to the forklift therefore the Fork Lift is the closet vehicle according to the Game Engine. Whereas the truck is 7 spaces away the fork lift is 3.

Reading your code and then i will alter this post.

Thats what I originally posted.
Reply


Messages In This Thread
GetClosestCar problem. - by RALL0 - 21.07.2013, 18:31
Re: GetClosestCar problem. - by RALL0 - 21.07.2013, 19:28
Re: GetClosestCar problem. - by RALL0 - 21.07.2013, 20:15
Re: GetClosestCar problem. - by Pottus - 21.07.2013, 20:21
Re: GetClosestCar problem. - by IceCube! - 21.07.2013, 20:22
Re: GetClosestCar problem. - by RALL0 - 21.07.2013, 20:28
Re: GetClosestCar problem. - by IceCube! - 21.07.2013, 20:37
Re: GetClosestCar problem. - by IceCube! - 21.07.2013, 20:39
Re: GetClosestCar problem. - by RALL0 - 21.07.2013, 20:40
Re: GetClosestCar problem. - by IceCube! - 21.07.2013, 20:45

Forum Jump:


Users browsing this thread: 3 Guest(s)