Jump to content
Sign in to follow this  
nuxil

how to calulate the direction of the weapon?

Recommended Posts

Hi forum

i need to know how to calulate the direction of the weapon..

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

_me = (_this select 0);

_pw = primaryweapon _me;

_wdir = weapondirection _pw;

now. how do i get the x,y values converted to direction

im not so good with asin/acos/atan(2)

Share this post


Link to post
Share on other sites
Quote[/b] ]im not so good with asin/acos/atan(2)

so find some secondary school textbook wink_o.gif

Share this post


Link to post
Share on other sites
Quote[/b] ]im not so good with asin/acos/atan(2)

so find some secondary school textbook wink_o.gif

that was helpfull.. sad_o.gif

keep you ignorant post's to yourself. and let people that acutaly want to help post.

Share this post


Link to post
Share on other sites

thanks Junker. im verry grateful for that

i dont have inet myself so i have a hard time getting info about all commands..all i got is a old outdated ofp command ref..

now i'll go back to my scripting smile_o.gif

thanks again

Share this post


Link to post
Share on other sites

How do I find the intersection position in the terrain that my weapon is currently facing? That is the centre of the screen when I'm in my primary weapon position?

Share this post


Link to post
Share on other sites

I would usually of thought that a getdir would of been suffice, but then again with ArmA's new floating zone features, makes things interesting doesn't it tounge2.gif (+ vehicle turrets)

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×