Jump to content
Sign in to follow this  
Nick225

finding the X,Y,Z coordinates

Recommended Posts

for the setpos command, how do i find the xyz coordinates it asks for?

Share this post


Link to post
Share on other sites

depends...

you could just place a game logic and make the command move things there:

thingtomove setpos (getpos gamelogicname)

easiest way around it. If you reaaly want to use co-ordinates, then camera.sqs and a longer explanation is your answer.

Share this post


Link to post
Share on other sites
Quote[/b] ]If you reaaly want to use co-ordinates, then camera.sqs and a longer explanation is your answer

what do you mean?

i mainly need it to set the height of stuff.

Share this post


Link to post
Share on other sites

this setpos [getpos this select 0, getpos this select 1, height in meters]

Just put it into a units init field and he will stay at his position but you can change the height wink_o.gif

m_search.gifthumbs-up.gif

Share this post


Link to post
Share on other sites

i have a completely unrelated question, but i didnt want to create a new topic.

In my mission I have a helo and 3 boats going from a small island to assualt a city. the boats work fine and everypme gets out, but the helo does the little circly, spinny, 180 and then continues to drop the parachuters. whats up with this?

Share this post


Link to post
Share on other sites

On the setPos thing, bear in mind a few wrinkles:

1. objectname setPos getPos objectname

Will cause many objects to move quite some distance laterally.  Try it with a wire, it moves about half its own length sideways.  This is a pain if you want to place one ammo crate on top of another you need to do something like:

_xpos = getPos ammo1 select 0

_ypos = getPos ammo1 select 1

ammo1 setPos [_xpos,ypos,0]

ammo2 setPos [_xpos,_ypos,z]

Surprising though it may seem this does result in ammo1 moving sideways.

2. objectname setPos [x,y,z] will for most objects place them z meters above ground.  But if the object is a trigger it will place it z meters above sealevel

3. x is the number of meters from the left hand side of the map and y is the number of meters from the bottom of the map.

On the copper problem:  Controlling choppers is like trying to train a cat.  Not impossible, but it is easy to find better ways of spending your life. smile_o.gif

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  

×