Kydoimos 916 Posted December 16, 2014 Hi everyone - having a real hard time getting AI to shoot at one another during the night. Basically, there's some fog, and a little cloud. The enemy have night vision. The friendly AI unit does not. Neither can see one another. I've tried using the 'reveal' command and also 'knowsabout' but neither help. I've tried giving the friendly AI unit a night vision scope, but he still won't shoot. Then I tried simulating the gunfight, by forcing the AI to fire at one another using the 'fire' command and 'doTarget' / 'doWatch' command in combination with 'reveal' and 'knowsabout'. Still no joy, the AI fire, but not at the target. Does anyone have any bright ideas? Even when the sky is lit with a flare, they can't see one another! Just need to make the AI see everything! Although there's a bit of fog, the enemy are clearly visible! Tried full moonlight too, and still nothing :P Share this post Link to post Share on other sites
Rydygier 1317 Posted December 17, 2014 (edited) Repro mission would be helpful for testing solutions. Tried with this testing mission (30% coulds, 30% fog, midnight, 300 meters of distance). Although initially they knows nothing about each other, OPFOR starts shooting as soon I use 0-0-0 to reveal the target. In such cases is often a good idea to make separate test mission to "extract" the situation from the mission "context" - easier/faster to test and you can check, if reason is hidden in that "context" or not. So reveal (high enough knowledge) should work if used properly and there is unobstructed LOS and not too big distance. Another tricks to make unit easier to spot would be keep it standing, moving and on the "hard" surface like road, give more light and/or less fog. And of course reduce the distance. All, what's necessary to make knowledge about the target high enough. But not only. Tested with same mission for 100% overcast and fog. Despite 4 of knowledge, soldier was not shooting, althoug went prone, as he knew about the target. After more testing I'm convinced, the crucial factor is the fog. For any overcast in these circumstances border fog value is 40%. For 41% OPFOR will not shoot, for 40% - will shoot after revealing the target. So you have to find such border fog value for situation in your mission. You can use my testing scenario, just apply yours units with same skills same distance and environment conditions. And be sure, shooting isn't disabled somehow, eg by "BLUE" combat mode, setcaptive on targets, setFriend etc. Edited December 17, 2014 by Rydygier Share this post Link to post Share on other sites
Kydoimos 916 Posted December 17, 2014 @Rydygier - thanks man! Yeah, it's the fog! I've done a lot of testing - doh! It's a shame, because I've set the fog at knee height, but because it's at maximum value, the AI can't see! grrr! :P Share this post Link to post Share on other sites
Polygon 11 Posted December 23, 2014 Wait a second... You wanted AI to shoot at the enemy through the fog? Blind fire a little? Share this post Link to post Share on other sites
oukej 2911 Posted December 23, 2014 You an also try lowering the fog base level a bit or increasing the decay. Once the AI is in the fog it will suffer detection and engagement range penalties. Share this post Link to post Share on other sites
austin_medic 109 Posted December 24, 2014 @Rydygier - thanks man! Yeah, it's the fog! I've done a lot of testing - doh! It's a shame, because I've set the fog at knee height, but because it's at maximum value, the AI can't see! grrr! :P you could jerry rig something up. I tried to create a surpression script earlier today but it was making my head spin as I'm not 100% healthy right now, in theory it could've been used to make AI blindfire, anyways heres what I had: AUSMD_surpress.sqf _unit = _this select 0; _shootpos = _this select 1; _logic = "Logic_F" createVehicle _shootpos; for "_i" from 0 to 15 + (random 50) do { _unit doTarget _logic; sleep 0.00001; _unit forceWeaponFire [currentweapon _unit,"fullauto"]; _logic setPos [(getpos _logic select 0) + (random 10 - random 10),(getpos _logic select 1) + (random 10 - random 10),(getpos _logic select 2) + (random 10 - random 10)]; sleep 0.001; }; init.sqf { if(isplayer leader _x) then { _x setVariable ["AUSMD_surpressing",0,true]; nul = [_x] execVM "AUSMD_AISurpression.sqf"; } foreach allGroups; AUSMD_AISurpression: _group = _this select 0; _unit = _this select 1; while{true} do { if(leader _group == player) then { AUSMD_AISurpression_Lead = player addaction ["Surpress Cursortarget",{_group setVariable ["AUSMD_surpressing",1,true]; {nul = [_x,getpos cursortarget] execVM "AUSMD_Surpress.sqf";} foreach units _group;player addaction ["Surpress Cursortarget",{_group setVariable ["AUSMD_surpressing",0,true]; _},nil,5,true,true,"",' _group getVariable ["AUSMD_surpressing",1] && leader _group == player '];},nil,5,true,true,"",' !(_group getVariable ["AUSMD_surpressing",0]) && leader _group == player ']; // I think something is broken in here, but where in here? }; waitUntil{leader _group != player}; player removeaction AUSMD_AISurpression_Lead; }; maybe one of those will give you an idea. Share this post Link to post Share on other sites
redarmy 422 Posted December 24, 2014 To the author just wana throw this out there,there is a neat little script from arma 2,that makes ai fires flares at each other once enemy detected.I understand it may not be able to fix your issue,but since your on theme of night mission,and this script isnt being used or known to still work,i thought id put it out there. i run it problem free in my scenario,and adds great ambience to a night mission.If you or anyone is interested PM me,il upload it to a dropbox,if thats not against forum rules or such.If your familiar with GAIA,which makes ai launch flares into air on known enemy position,its like that,but flares shot at much lower angle "at" enemy squad,pinpointing and making it easier for other units to see them Share this post Link to post Share on other sites