Jump to content
Sign in to follow this  
HeroesandvillainsOS

Placed units lay down in buildings. Is CQB possible?

Recommended Posts

I'm trying to set a scenario up where I need to go into this lush building and kill an HVT. I've manually placed 7 OPFOR inside it, strategically trying to angle them near corners.

Every single one of them, no matter what, lays down right where I place them when they detect they are under attack. They don't search for cover or move hardly at all. They just lay down and take it.

Am I supposed to group them all together? Or change their initial stance in the editor? Or anything? All I did was just place them where I wanted them to be (which is them standing with their gun ready).

I really don't get it.

Normally I use ALiVE and that mod seems to handle this stuff well on its own. I'm trying to manually do this and every time, they just hit the floor when the firefight starts. Sometimes I get lucky and surprise the first guy and get him while he's standing. But his buddies all lie down just biding their time until they get executed.

Is there any way around this?

  • Like 1

Share this post


Link to post
Share on other sites

I'll try grouping them together to see if maybe that forces them to work out a strategy, or something rather than lying down, while I wait to get a more experienced mission maker's take on this.

Share this post


Link to post
Share on other sites

You can force them to maintain a stance with setUnitPos. If you're using it in the unit's initialization field it will look like this:

this setUnitPos "up";

Acceptable inputs for the quotation marks are up, middle, and down. CQB in general is clunky with Arma sadly, and the vanilla AI easily get confused and will just stand in place, but at least you can force them to stay standing,take a knee, or lie down.

  • Like 2

Share this post


Link to post
Share on other sites

this setUnitPos "up";

This, plus this forceSpeed 0 is what i use to keep them where i want them (i.e. just angling around a corner).

  • Like 1

Share this post


Link to post
Share on other sites

You can force them to maintain a stance with setUnitPos. If you're using it in the unit's initialization field it will look like this:this setUnitPos "up";Acceptable inputs for the quotation marks are up, middle, and down. CQB in general is clunky with Arma sadly, and the vanilla AI easily get confused and will just stand in place, but at least you can force them to stay standing,take a knee, or lie down.

This, plus this forceSpeed 0 is what i use to keep them where i want them (i.e. just angling around a corner).

Thanks guys. This is exactly what I was looking for.

Hopefully I won't have to use forceSpeed 0; just to make CQB moderately attainable (in a perfect world, I'd like for them to move from cover to cover as they try and position themselves in the best possible way to defend themselves), but at least now I have some options! :)

I appreciate it.

Share this post


Link to post
Share on other sites

Can the AI move at all with SetUnitPos? Is this just a stance modifier or does it plant them in place similar to forceSpeed?

EDIT: Yes they can! This is a big improvement!

Share this post


Link to post
Share on other sites

You have also a bunch for behaviors with disableAi . Look at AutoCombat and powerful checkVisible .

Oh that's helpful too. I like the sound of AutoCombat. Thanks to you too!

Share this post


Link to post
Share on other sites

Hi,

 

I've just making a SQS script file since month ago to make the AI randomly choose between crouch and stand position while in combat behaviour and stay up when in safe behaviour.

 

I've already asked for help from a scripter to convert it to SQF and having it in a PBO file to execute it at game start but nodody never answered. It seems that helping each other became less important in this community, and that's bad.

 

So, actually, I still use this SQS script and must add and execute it as a script in each custom mission. I'd like to see it become a mod file because I'm tired of always being obligated to shoot grass to be able to neutralize hostiles. That's really boring and unrealistic at all.

 

I can share you the script if you want to test it and see if that fit to the result you want. That only avoid AI that execute the script to go prone while in combat behaviour, and not modify the strategic capacity of each of them.

Let me know if you want to test it.

Share this post


Link to post
Share on other sites

Hi,

 

I've just making a SQS script file since month ago to make the AI randomly choose between crouch and stand position while in combat behaviour and stay up when in safe behaviour.

 

I've already asked for help from a scripter to convert it to SQF and having it in a PBO file to execute it at game start but nodody never answered. It seems that helping each other became less important in this community, and that's bad.

 

So, actually, I still use this SQS script and must add and execute it as a script in each custom mission. I'd like to see it become a mod file because I'm tired of always being obligated to shoot grass to be able to neutralize hostiles. That's really boring and unrealistic at all.

 

I can share you the script if you want to test it and see if that fit to the result you want. That only avoid AI that execute the script to go prone while in combat behaviour, and not modify the strategic capacity of each of them.

Let me know if you want to test it.

That sounds like a neat script.

I'm a little hesitant to universally attempt to adjust AI behavior in my current projects, mainly because I use ALiVE to set the random ambient battlefield, and have only recently (I mean really recently) begun manually adding units and tasks for more precision and something a player could complete in let's say an hour, rather than a standard ALiVE battle which could take days.

I'm not saying this script wouldn't play nicely with ALiVE's units, but the way the system spawns and despawns them I'd have to wonder if it could conflict or simply not be compatible in a dedicated server environment. Although Pooter's Enhanced AI seems to do just fine so perhaps a more focused project like yours that alters one set of behavior, rather than lots, would work just as well or better.

I have had decent success getting help in the scripting area of the forums here, and also r/armadev when I need an answer quickly. I definitely don't see why you wouldn't have better luck getting help with your project than me because at least it seems like you're starting with functioning code.

Though I don't mind at all if you share it here. Have at it. I could see myself trying it too but I'd have to see how this init adjustment stuff goes first.

Share this post


Link to post
Share on other sites

 

 

I'm not saying this script wouldn't play nicely with ALiVE's units, but the way the system spawns and despawns them I'd have to wonder if it could conflict or simply not be compatible in a dedicated server environment

 

That's why I trying to find some help to turn this script (that needed to be add in each init field of each unit that must execute it) into a global script executed by all entities (ManBase) and loading with the game. Without that, all spawned units can't execute this script unlike a global mod.

 

 

 

Although Pooter's Enhanced AI seems to do just fine so perhaps a more focused project like yours that alters one set of behavior, rather than lots, would work just as well or better.

 

I think that my script can correctly works with AI mods. I don't try until now because no AI mods actually works correctly (compared to the descriptions) or some just add functionnalities I don't want. But if we can merge my script with another good AI mod that let the AI move and adapt to each situation, we can have an AI mod that avoid this abusive prone position (and finally get rid of this grass shooting simulator and those inadapted positions) and those AI that can't do anything without any script.

 

 

 

I have had decent success getting help in the scripting area of the forums here

 

I've already wait more than a week with multiple views on a topic created to asking for help on this, and even try myself to do it, but nobody never answered and I don't find any way to do it myself. And other topics most recents than mine get answered. So, nobody seems to want to help me doing this.

 

Actually, the SQS works very simply and well. Some issues appear while trying to use a SQF file instead, maybe I don't do it correctly, but for example, an AI in safe behaviour is detected as in combat behaviour by the SQF script code. So, I don't really know if I do something wrong or if it's a game issue.

Share this post


Link to post
Share on other sites

The threads doesn't exist anymore because useless after seeing that nobody giving any help.

 

The script is relatively simple as SQS format, but no way to get it working in SQF. And I don't know anybody that can give me any help.

 

I always use it in my custom missions, and it's really nice to don't always have all hostiles in the grass. And like I'd really like to use it as general mod for original BI missions, I still searching for help, but it's hard to find some.

Share this post


Link to post
Share on other sites

I think you should try posting it again. Or share the script here for all I care. It's on-topic and could prove useful.

Though I think if you want a proper addon or sqf format, you'll have better luck having the bigger hitters see it over on the scripting area.

Share this post


Link to post
Share on other sites

nobody giving any help.

 

And I don't know anybody that can give me any help.

 

I believe Heroesandvillains is trying to help. Maybe it was just that the people that looked at it either couldn't help, were interested in a solution to the problem, or both. And, off the top of my head this sound like a very simple sqf to write, and I was going to look at your thread to see what you'd actually tried with the sqf but you've apparently removed it by the sound of it. But as far as the community being unwilling to help, this post was answered to a simple degree by Mynock and myself in the 4th and 5th posts. Also, since you mentioned realism, it's actually far far less realistic that soldiers would present a raised profile and expose themselves like that when out in the open.

 

But, seeing as Heroesandvillains wants a look to try and help, why not accept the help.

Share this post


Link to post
Share on other sites

 

 

I think you should try posting it again. Or share the script here for all I care.

 

I can send you the script via PM. Like that, you can see and test it.

 

 

 

see it over on the scripting area

 

Already done. Already ignored haha. I'm not the only one that speaking about this lack of help, I have a friend that encounter the same problem to find help on the forums. And I've already tried to share it here with images to show how the script work. But nobody ever test it or giving any feedback. That's why I understand that members are not interested and delete it from the forums.

 

 

 

Also, since you mentioned realism, it's actually far far less realistic that soldiers would present a raised profile and expose themselves like that when out in the open

 

In fact, if you look at the combat videos available, you oftenly can check that soldiers never go prone without any good reasons. And the reason to not go prone in combat is that you clearly reduce your moving speed and your movements. And that can be a definition appearing in the "How to be easily killed" in a combat manual.

 

Those who use machineguns and marksmen rifles can go prone if they are above the target area or need to stabilize the weapon, and that is effective. Without that, you'll never see any professional soldiers doing the things the AI soldiers do in ArmA. And like I know some friends that are in army, or even civilian forces like the Police, they are agreed with that, especially the soldiers. We must stop to share this false idea that all the soldiers go prone, even in open areas. They stay up or crouched and go under cover. And if all soldiers are prone, nobody can see the others and they just stayed here without any field of view and the situation stay blocked. But, if some people still wants to trust the fact that all soldiers go prone everytime during combat, well, I can't do anything against that and they just don't have to use my script or critizice it. They just can continu to use ArmA like a "Grass Shooting Simulator"  ;)

 

HeroesandvillainsOS don't clearly said he will help me. But if he wants to, and if the script interest him, I'll share it with him of course.

 

 

 

why not accept the help

 

I've never said I'll don't accept any help from him if he wants to. I can even give him my Skype contact to speaking about that without any problems.

Share this post


Link to post
Share on other sites

No no I can't help because I don't have the skill. If I did I wouldn't be starting threads like this. :)

I'm offering this thread to him if he wants to share the script. Though that said, if your BIS threads aren't getting enough traffic, try r/armadev over on Reddit. There's a decent crew over there too.

Regardless, you can't get help if you don't share the script.

  • Like 1

Share this post


Link to post
Share on other sites

In fact, if you look at the combat videos available

I don't look at combat videos for advice on military principles, i rely on my decade plus of experience. There's so many things wrong with standing in the open that go beyond just simply exposing yourself. But then, in built up or some other complex terrain standing IS likely to be preferable. HOWEVER, i understand the pain it is to be low to the ground, in grass and be facing off against an AI in who is also low and hidden in grass, only to have them accurately engage you because of the various quirks that exist in this game. I figured you would put up what you had already come up with for us to look at, and i like to help solve problems and this one sounds like it'll be easy to write a script for.

Share this post


Link to post
Share on other sites

 

 

No no I can't help because I don't have the skill. If I did I wouldn't be starting threads like this.

 

Yep, that's what I've understand too  :)

 

 

 

Regardless, you can't get help if you don't share the script. 

 

Yes, I just waiting to find somebody that can help.

 

 

 

There's so many things wrong with standing in the open

 

Yes, naturally, I don't say that soldiers must stand up in an open field, that's logical. But when they move in open areas, they often are inside troop carriers and with vehicles, and if there's hostiles, they can hide behind the vehicles. I just say that finally, there's not really many soldiers that go prone during combat to keep their movements and ability to move fast. And finally, only those who take a covering or defending position or must use special weapons take this position. All others must move to take advantage, and so, we never see all the soldiers go prone in a combat area.

 

 

 

i understand the pain it is to be low to the ground, in grass and be facing off against an AI in who is also low and hidden in grass, only to have them accurately engage you because of the various quirks that exist in this game.

 

And yeah, that's a major part of the goal of this script. Like the AI in ArmA have "X-Ray" view and can shoot us even hiding behind tall grass or even bushes, and at 300 meters laying in the grass when we just can't see or aim them, getting the AI go crouch or stay up give us more accessible situations.

 

 

 

i like to help solve problems and this one sounds like it'll be easy to write a script for.

 

If you like to test the script and give a feedback, why not. And if you know how to get a functionnal conversion of this SQS script to a SQF one, and working in a PBO file that can work for all ManBase ingame, that's a good news. After that, if you have more skills in scripting, maybe we can see to make an alternate version of this script by adding some elements.

 

We can make a basic file to make AI choose randomly between stand and crouch while getting in combat behaviour.

We can make an alternate one that make the same thing but make those who use marksmen rifles or machineguns go prone. That can be a version that be prefered for those who still wants to see some AI go prone.

 

That's an example of what I tried to do, but considering that I'm not really an advanced scripter, successfully doing that to correct my problem in my custom missions is already great and so don't already looking for it.

Share this post


Link to post
Share on other sites

PBOs I can't help with, and I only briefly ventured into sqs way back in OFP days when I barely even knew how to adjust the weather in the editor. If you post an example here of what you have already tried with your sqf we can have a look at it, and offer advice on where you went wrong.

Share this post


Link to post
Share on other sites

Hey,

 

I only share the file via PM, I've already been confronted to the disrespect of the sharing condition for some of my mods that I need to stop sharing after this kind of attitude.

 

So, I only share the script via PM, like that, I can explain the conditions and I explain them inside the script file as well. That can avoid some problems and give me proof if something bad happened.

 

Just ask for the file by PM if you want to test it  ;)

Share this post


Link to post
Share on other sites

Send what you have in the sqf across and I'll have a look for you.

Share this post


Link to post
Share on other sites

Just barging in here, but wanted to share that I had some success with using the Sentry waypoint type. The AI does not seem prone to lying down as soon as bullets start flying

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  

×