Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: 9bitjared on April 07, 2015, 08:47:47 PM

Title: Tell the direction of an object
Post by: 9bitjared on April 07, 2015, 08:47:47 PM
In a game I am trying to tell the direction (just left or right will work) of an object from another object

Here is an example

(http://i.imgur.com/HjE2w8F.png)

if that doesn't work
http://imgur.com/HjE2w8F (http://imgur.com/HjE2w8F)

thanks in advance
Title: Re: Tell the direction of an object
Post by: MU65 on April 08, 2015, 02:50:32 AM
Hi,

in 2D space and in world coordinate I would find the position of the game objects and compare them (using Get position and a Float comparison action)... in 3D space I would do something similare but maybe using a comparison of the 3 axes unless hight doesn't matter.

Hope that could help

Have a nice day
Title: Re: Tell the direction of an object
Post by: 9bitjared on April 08, 2015, 06:04:00 PM
Hi,

in 2D space and in world coordinate I would find the position of the game objects and compare them (using Get position and a Float comparison action)... in 3D space I would do something similare but maybe using a comparison of the 3 axes unless hight doesn't matter.

Hope that could help

Have a nice day

Think I already tried that, but once more can't hurt