Home   Help Search Login Register  

Author Topic: stop unit in combat mode  (Read 1200 times)

0 Members and 1 Guest are viewing this topic.

Offline Fire-Fox

  • Members
  • *
  • Violence is just a friend walking on the right way
stop unit in combat mode
« on: 02 Aug 2007, 02:42:26 »
Hi @all! :) It's been some time.

Now I have a sniper on a radio tower ("radar") to overwatch part of an airfield. I want it to STAY THERE no matter what happens.

I've tried:
- commandstop this
- dostop this
- this disableAI "MOVE"
- this disableAI "TARGET"
- this disableAI "AUTOTARGET"
- this allowfleeing 0

...even all of them in combination plus in the init field and in a trigger activated by "true". But once Mr. Lemming Sniper has changed to behaviour "COMBAT" (automatically, by firing at him as an enemy or just by standing beside him as a friendly soldier and firing some rounds into the dust) he will:
- lay down (good)
- then stand up again (bad)
- start to run like hell (very bad)
- fall of the tower
- and finally die the death he deserves for such stupid behaviour

The sniper is a single unit w/o any group mate or leader. He is in SAFE behaviour mode. I'm using v1.08 of ArmA.

I've used the search function but could not find anything suitable for this problem (seems like such an obvious problem, hopefully I'm not the only having it). Looks like editing in ArmA is all about forcing that unwilling AI to do what you want just like in OFP... :confused:

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: stop unit in combat mode
« Reply #1 on: 02 Aug 2007, 03:58:34 »
I've had consistent success with snipers in towers using:

unit disableAI "MOVE";
unit disableAI "TARGET";
dostop unit;

Does this happen any time?  Or does it happen only after a SAVE?

There is a known problem with saves:  They eliminate any previous disableAI commands.

I recommend you build a little separate sample mission with just the sniper and a few enemies, and see if it still behaves badly.  If so post it here, and I will take a look.

El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline LeeHunt

  • Former Staff
  • ****
  • John 21:25
Re: stop unit in combat mode
« Reply #2 on: 02 Aug 2007, 17:46:37 »
I feel like I've tried everything in this regard to stop AI units as well. It must be the save game bug.  Also sometimes AI that joins your squad won't become "unstuck" and refuses to obey any order.  The only solution to that stickyness has been changing the AI unit's gear around.

Offline Fire-Fox

  • Members
  • *
  • Violence is just a friend walking on the right way
Re: stop unit in combat mode
« Reply #3 on: 03 Aug 2007, 00:50:08 »
Aha, I've found the little sucker that's been responsible for my trouble! :cool2: It was the behaviour setting all along. If you set a sniper on a tower to "SAFE" manually and then have him change his behaviour to "COMBAT" automatically due to fired shots, he will do the lemming run no matter how many disableAI or stop commands try to hold him back.

I have not encountered a save game bug so far, although something mysteriously tells me I'm going to do so in the near future... ::)


Hm, is it just me or has the good old "SOLVED" button been removed? ???

Thanks for comments, ppl! :clap:


EDIT:
Further investigation revealed that firing shots close to the sniper as a unit friendly to him does not make him change his behaviour to "COMBAT", it just makes him lay down. Only contact to enemy units makes him change his behaviour automatically.
« Last Edit: 03 Aug 2007, 01:05:14 by Fire-Fox »