Jump to content
Sign in to follow this  
Sonicboom777

I need help with a Script issue! ( Scared Assault Boats )

Recommended Posts

I have been looking for hours on how to fix this issue.

- How can I get an assault boat under fire to land on the shore with out Banking off or running away?

- I tried: BoatUnit SetCaptive true; But that just makes it to where no one shoots at the boat

- The boat has to be able to get shot at with out running to make my mission more fun.

- Thank you! :)

Share this post


Link to post
Share on other sites

Not fully tested but your boat driver should not really care about what is going on around him.

_group allowfleeing 0; //the boats group
(driver _boatname) disableAI "AUTOTARGET";
(driver _boatname) disableAI "TARGET";
(driver _boatname) setBehavior "CARELESS";
(driver _boatname) setCombatMode "BLUE";

Share this post


Link to post
Share on other sites
Not fully tested but your boat driver should not really care about what is going on around him.

_group allowfleeing 0; //the boats group
(driver _boatname) disableAI "AUTOTARGET";
(driver _boatname) disableAI "TARGET";
(driver _boatname) setBehavior "CARELESS";
(driver _boatname) setCombatMode "BLUE";

Hm, I even put boatunit_allowFleeing_0;

and when the boat is shot, it still banks off and runs even with a careless way point

( I cant put _group1 allowFleeing 0; ) Because the underscore says "local variable in a global space," and if any spaces it says "missing ;"

I am sorry, I am fairly new with this coding.

Share this post


Link to post
Share on other sites

Did you type this in the editor? You cannot use local variables (defined with a "_" preceding the name) in the editor. You can use "this" in the init field of the unit which is a placeholder for the unit you are modifying. An example would be:

(group this) allowfleeing 0; 
(driver this) disableAI "AUTOTARGET";
(driver this) disableAI "TARGET";
(driver this) setBehavior "CARELESS";
(driver this) setCombatMode "BLUE";

Share this post


Link to post
Share on other sites

very useful thread. working on a similar scenario but my assault boats are usually fine under fire!

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  

×