johnnyboy 3739 Posted March 16, 2018 I searched for a while for this, and came up empty... I want to be able to point an object at another object in 3d space. So I need to calculate the values to use for setVectorDirAndUp. I know how to get the vector to the target (heading): _heading = [getPosASL _arrow, getPosASL _targetObj] call BIS_fnc_vectorFromXToY; And I know how to setvelocity using that heading, so the object moves toward the target. But how do I get the values for setVectorDirAndUp so the object is pointing at the target? I'll never understand vectors...they drive me crazy. Share this post Link to post Share on other sites
pierremgi 4736 Posted March 17, 2018 Just use bis_fnc_VectorDirAndUpRelative 3 Share this post Link to post Share on other sites
johnnyboy 3739 Posted March 17, 2018 12 minutes ago, pierremgi said: Just use bis_fnc_VectorDirAndUpRelative Beautiful! Merci Pierre! 2 Share this post Link to post Share on other sites
Grumpy Old Man 3540 Posted March 17, 2018 On a sidenote: Just because you think an object is facing forward doesn't mean it's actually facing forward. Forward direction is being defined at model level, take a camping chair for example: You'd think it's facing the same direction as the player, but it actually is facing the other way, the chairs "forward" is facing towards me in this picture. vectorDir player: [0.0240843,0.99971,0] vectorDir chair: [0.196999,-0.98017,-0.021405] Now go tell one arma inhabitant to put some chairs around a table, facing the table. Hopefully he will explode his quad on the next fence. I don't want to know for how many objects this actually applies, has got to be a running gag at this time, next to the lovely boundingBoxReal... Cheers 3 1 Share this post Link to post Share on other sites
johnnyboy 3739 Posted March 17, 2018 6 hours ago, Grumpy Old Man said: Now go tell one arma inhabitant to put some chairs around a table, facing the table. Hopefully he will explode his quad on the next fence. I don't want to know for how many objects this actually applies, has got to be a running gag at this time, next to the lovely boundingBoxReal... Grumpy actually being grumpy...I like it! Thanks, I knew about the chairs...pretty lame. Share this post Link to post Share on other sites
Harzach 2505 Posted March 17, 2018 It seems that a lot of wall/fence objects are long axis forward (90 degrees from where you might expect), which really confused the heck out of me for a minute. Share this post Link to post Share on other sites