Jump to content
Sign in to follow this  
node_runner

Marker Positions and lookAt

Recommended Posts

Two questions:

1) What is the best way to get a unit to move to a marker? I've tried placing a marker on the map named "marker1" and I've tried two different variations that say they should work according to the BIS editing wiki:

this move position "marker1";

and

_pos1 = getMarkerPos "marker1";

this move position _pos1;

and they don't work, but the editor seems to accept the syntax without any problems.

2) When I tell a unit to "lookAT" another unit or object, is there a way to keep the unit from glancing around side to side? I'm trying to use lookAt as a cheap way to avoid camera scripting a first-person cut scene in the intro to a mission. I can get the character to walk around and look at units, but sometimes I want to stop him from glancing around the area and focus on an object. Any tips?

Share this post


Link to post
Share on other sites

For movement, try MoveTo and doMove as well...I don't have a lot of experience with them but hopefully you can get something to work. I assume from your use of this that you are placing this in the unit's init line.

For look at, after giving the lookAt command, maybe try disableAI "TARGET" and disableAI "AUTOTARGET" as well.

Share this post


Link to post
Share on other sites
For movement, try MoveTo and doMove as well...I don't have a lot of experience with them but hopefully you can get something to work. I assume from your use of this that you are placing this in the unit's init line.

For look at, after giving the lookAt command, maybe try disableAI "TARGET" and disableAI "AUTOTARGET" as well.

Thanks loyal! What ended up working for me was:

_pos1 = getMarkerPos "Marker1";

this domove _pos1;

The disableAI trick helped, but didn't completely stop him from glancing. But hey, it's good enough I think, so thanks for the advice.

Share this post


Link to post
Share on other sites

No problem. You can also try disableAI "ANIM" as well...then he shouldn't move at all, but, he will also look stiff as a board.

Edited by Loyalguard

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  

×