Jump to content
Sign in to follow this  
Tand3rsson

damn night time

Recommended Posts

Hi!

Im having a bit of problem getting the ai to engage as i want during night time. This is what I got:

38 independent soldiers (namned un1 - un38), riding in truck1,truck2,truck3,truck4.

The total convoy looks liks this (in order of apperance ofc): tank1, truck1, truck2, truck3, truck4, truck 5, tank2.

All these veichles are running a fine convoy through the night using the unit capture/play function. Then tank1 hits an IED, shortly followed by tank2. All 38 un soldiers jump out of their veichles. The sky is litt up a flare by using

bomb = "F_40mm_White" createVehicle [(getpos flare1 select 0),( getpos flare1 select 1), 300]

untill the time of the first flare, all units are setCaptive true.

Flares pops up in new pos over the area the next 2 mins or so.

In the hills beside the road is the opfor with hmg, lmg and rpg. (opf1, opf2 and so on) But since they do not react to the light, they do not engage the un-soldiers. I have tried several different approaches; doTarget, doFire, reveal, knowsAbout, how ever they do not engage.

Is there any way to "trick" the ai to belive that it is daytime after that first flare? (The combat distances is just above 200m). I have searched for a while now, but can't find anything I understand, even though questions like this have been up before,

Please help!:confused:

Share this post


Link to post
Share on other sites
Hi!

Im having a bit of problem getting the ai to engage as i want during night time. This is what I got:

38 independent soldiers (namned un1 - un38), riding in truck1,truck2,truck3,truck4.

The total convoy looks liks this (in order of apperance ofc): tank1, truck1, truck2, truck3, truck4, truck 5, tank2.

All these veichles are running a fine convoy through the night using the unit capture/play function. Then tank1 hits an IED, shortly followed by tank2. All 38 un soldiers jump out of their veichles. The sky is litt up a flare by using

bomb = "F_40mm_White" createVehicle [(getpos flare1 select 0),( getpos flare1 select 1), 300]

untill the time of the first flare, all units are setCaptive true.

Flares pops up in new pos over the area the next 2 mins or so.

In the hills beside the road is the opfor with hmg, lmg and rpg. (opf1, opf2 and so on) But since they do not react to the light, they do not engage the un-soldiers. I have tried several different approaches; doTarget, doFire, reveal, knowsAbout, how ever they do not engage.

Is there any way to "trick" the ai to belive that it is daytime after that first flare? (The combat distances is just above 200m). I have searched for a while now, but can't find anything I understand, even though questions like this have been up before,

Please help!:confused:

Tinker with skill and give the team leaders NV googles. Use smaller teams with independent routes.

Share this post


Link to post
Share on other sites
Guest

I would also like to know if this is possible. The only way I can get the AI to spot/engage decently at night is by giving them NV goggles which imo is lame...

Share this post


Link to post
Share on other sites

_li = "#lightpoint" createVehicleLocal [0,0,0];

_li setLightBrightness 0.24;

_li setLightAmbient[_r*0.8, _g*0.8, _b*0.8];

_li setLightColor[_r, _g, _b];

_li lightAttachObject [_projectile, [0,0,0]];

nicked this out of a script... it is said to give the ai a light source not visible to players? how would i use this?

---------- Post added at 11:38 PM ---------- Previous post was at 11:36 PM ----------

Tinker with skill and give the team leaders NV googles. Use smaller teams with independent routes.

I actually don't want to use NV, because the Opfor is suppose to be low tech. And Smaller teams? Dont understand. They do also not seem to react differently with high/low skill :S

---------- Post added at 11:58 PM ---------- Previous post was at 11:38 PM ----------

I think I've got it :P so sorry to waste ppls time when I suddenly find it...

light2 = "#lightpoint" createVehicleLocal [0,0,0]; light2 setLightBrightness 1; light2 setLightAmbient[1, .1, .1]; light2 setLightColor[1, .07, .05]; light2 lightAttachObject [rm2, [0,-0.1,0]];

something likes that :D

---------- Post added at 11:59 PM ---------- Previous post was at 11:58 PM ----------

rm2 is btw rifleman2, a unit it attaches 2

---------- Post added at 12:05 AM ---------- Previous post was Yesterday at 11:59 PM ----------

or no, wrong again. This makes the independent appear to the opfor, and they engage propperly. But the light is visible to me.

Edited by Tand3rsson

Share this post


Link to post
Share on other sites
I would also like to know if this is possible. The only way I can get the AI to spot/engage decently at night is by giving them NV goggles which imo is lame...

How about reveal?

Share this post


Link to post
Share on other sites

Hmmm.... i now have a new problem after resolving my last.

I use this to call the script with the ambient light:

nul = execVM "flareambient.sqf"

Problem is I would like to restrict it, using forEach unit in a specific group. How would I go about this?

---------- Post added at 00:54 ---------- Previous post was at 00:37 ----------

this execVM "flareambient.sqf" forEach units group grpAlpha

HELP!!! I dont know how to script.. please help!

---------- Post added at 01:24 ---------- Previous post was at 00:54 ----------

one way is to set the light colour to 0, 0, 0... that way you cant see the light, although ai does

Share this post


Link to post
Share on other sites

try my flare script it stops the sky from being spammed by flares, and gives the light needed to give AI actual visibility.

Can be customised several ways.

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  

×