Jump to content
Sign in to follow this  
VictorFarbau

VFAI - AI Extension

Recommended Posts

An issue is still there also in version 2.2:

Sometimes units grab something from a dead body and then stay with the pistol animation (without pistol in hand) and don't change back to rifle.

Also they don't shoot. They only throw grenades and finally get killed.

EDIT: It's funny that when these soldiers get injured they take their rifle in hands and act normally.

Share this post


Link to post
Share on other sites
An issue is still there also in version 2.2:

Sometimes units grab something from a dead body and then stay with the pistol animation (without pistol in hand) and don't change back to rifle.

Also they don't shoot. They only throw grenades and finally get killed.

EDIT: It's funny that when these soldiers get injured they take their rifle in hands and act normally.

i this this problem is similar to what may happen to You as human player too

0: exchange weapons (all) or only pistol stays in inventory

1:change from weapon A to weapon B and try move

2: that triggers automatically change of Weapon B to A happens and if try move again

then goto 1(loop)

only way to avoid this is let finish the weapon change animations and move AFTER it's done

i guess same problem applies to AI so there must be delay where AI waits for weapon change anim to complete

also i think AI should preventively reload any new weapon after pickup (imagine as function check)

Share this post


Link to post
Share on other sites

I agree with Dwarden - a lot of weird behaviour just surfaces through using regular functions (such as picking up weapons). I already noted down to explicitely select a weapon after pickup for the next version. But there's no way to determine the currently selected one so it might always be the wrong one. Which will lead to new bug reports tounge2.gif Isn't it fun.

Cheers,

VictorFarbau

PS: kroky, earlier you mentioned some odd hiding behaviour. That's got nothing to do with VFAI. It might happen that when several units go on "STEALTH" or into fleeing mode that they pick the first hiding spot around.

Share this post


Link to post
Share on other sites

@Victor Farbau

I think for a future update of Equipment AI, it would be a great idea to make AI exchange magazines between each other in their own squad, before abandoning formation a running around and scavenge dead bodies.

Do you think this could be done?

Share this post


Link to post
Share on other sites

is this working with latest XEH ? because somehow i can't get it to work ...

Share this post


Link to post
Share on other sites

@Kroky

Quote[/b] ]make AI exchange magazines between each other in their own squad

That's the way I wanted to have this work originally, place some stuff here and there for other team members to pick up. Turned out that "ground" as weapon holder cannot be accessed by scripts (always returns empty). So the next obvious choice was dead bodies. I will put this suggestion back on my list. Latest when I will start working on a some group AI to enable smart weapon choices I will need a common group inventory concept anyway.

@Dwarden - I think I was even the first one to release something which was explicitely with XEH (as it is mentioned in the change notes on page 1) smile_o.gif

So I wouldn't see an obvious reason why this does not work for you. At least for the equipment part I can tell you that there might be initial delays up to ~30 seconds since the script waits for global variables etc. Can you set up a very simple mission and test this again? Like 1 dead soldier with weapons, 1 alive soldier (removeallweapons this) and you as spectator? After about 40 seconds (latest) the soldier should start stealing equipment and ammo.

Regards,

VictorFarbau

Share this post


Link to post
Share on other sites

@Victor Farbau

1. Glad to hear you still work on this great addon (has become standard for me, don't play ArmA without it anymore.)

Still hope you fix the problem that AI get stuck sometimes when picking up a pistol. Maybe exclude picking up pistols for the AI?

@Dwarden

Are you using the newest XEH by Solus AND Killswitch?

If yes you have to use the older XEH made only by Solus.

Right now I have put both XEH in my @UserAddons/Addons folder and all mods work that need XEH. There have been some issues with the newest XEH, since in some config file of some mods there is a line saying: needed addons: Extended_Init_Eventhandlers and Extended_Fired_Eventhandlers. But the newest XEH is named ssimply Extended_Eventhandlers. See the topic in Addons mods complete.

Share this post


Link to post
Share on other sites

well that's catch22 because if i use latest XEH by S&K and first XEH by S

together some other's XEH based addons go rnd crazy (aka don't work)

plus latest XEH is 'supposed' to be backward compatible with addons which were build for older XEH

great

Share this post


Link to post
Share on other sites

I have tested VFAI_Smokeshell addon in MP - doesn't work...

Both sides - server and client have this addon, I have made

sample mission and enemy AI will never throw smoke grenade...

Even if I'm sure that he has one (I have add manually SmokeShell).

Yes - I have shoot to him to test it.

Share this post


Link to post
Share on other sites

It worked yesterday (don't know the exact version) on PME 1.09 server... both for server and clients.

I think that this script shouldn't affect remote units.

Share this post


Link to post
Share on other sites
It worked yesterday (don't know the exact version) on PME 1.09 server... both for server and clients.

I think that this script shouldn't affect remote units.

I have tried on 1.08.

It worked for you for AI units in your group? Or for enemy AI only

group?

I have tested SP - working fine. I have created sample mission -

on the map: only I, hidden in bush and one enemy with SmokeShell.

I have uploaded addon pbo file and extended eventhandlers.

Server after that was restarted. I have joined the server, then

chose sample mission, and shot once to the enemy

and waited... Enemy hasn't throwed smoke grenade... I have

tried many times.. In SP that works, for enemy in MP - not...

Share this post


Link to post
Share on other sites

The problem with AI:s not throwing smoke when hit can partially be explained by a buglet in VFAI_SmokeShell\smokeshell_ai.sqf, which is a hit event handler added by the VFAI_Smokeshell addon via the XEH framework.

The thing with the hit event is that it is only generated on the machine where the affected unit is local, but smokeshell_ai.sqf uses an if statement that limits execution of that script to non-player units on a server.

These two machines (the server and the one where the unit that runs the hit EH is local) are not necessarily one and the same.

The conditional in smokeshell_ai.sqf ought to be:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">...

if (!(local _who) or (isPlayer _who)) exitWith {};

...Also, the hit event handler doesn't always fire - see the comments in this Biki article: Arma: Event Handlers

Now, if the test was made on a dedicated server, that particular flaw would not come into play and the server-side AI should have thrown smoke after a while which then indicates that there are further problems elsewhere. Judging from people's MP experiences with the new XEH addon, there might be MP issues with XEH that need to be resolved.

Share this post


Link to post
Share on other sites

I was just testing this at the same time and came to the same conclusion as Killswitch. Bummer mad_o.gif

EDIT: hm, after some more testing I have to disagree in fact. The locality check is counterproductive as well. I could reproduce the same behaviour each time: if I limited the script to the server or excluded local units (as suggested) then foreign and enemy units would run the script fine but your own group mates would never react to it. One interpretation of this behaviour would be that if you're a local player on a client machine then your group will also be considered local to your machine (at least when it comes to events).

EDIT 2: well, correct assumption as it seems. The "locality in MP" explanation states:

Quote[/b] ]# AI units are always local to the client of their leader

The best solution I found is to only test for and exit if the event is received by a human player, that's it. With that I just trust the event distribution to work fine and not to occur on several machines. During testing this seemed to work just fine.

Looks like I will change the addon accordingly and change the instructions to "needs to be installed on all machines participating in an MP game". The bug only affects dedicated servers anyway.

Regards,

VictorFarbau

Share this post


Link to post
Share on other sites

I have tried also on the server with Extndent Init Eventhandlers 1.1 and 1.26 - same result, so this is not only new XEH problen...

Share this post


Link to post
Share on other sites

FIXED with version 2.3. History and download link on 1st page as usual.

Tested Smokeshell.AI on a dedicated server, works fine for me now. Bug reports still very welcome.

Tested Equipment.AI on a dedicated server. Due to the precautions taken you don't see units that often anymore stealing stuff from corpses. But I tested a basic mission on a dedicated server and after a while hostile and friendly units started to pick stuff from dead bodys. So the addon works - there might be other conditions that stop units as explained in the readme file.

VFAI will work with XEH 1.0 by Solus and Killswitch. It is the only version of extended eventhandlers that I have installed and it works fine for me. I am not sure it's a good idea to have several versions installed simultaneously - I won't be held responsible for undesired effects.

I myself use this:

-mod=beta;@DMSmokeEffects;@TrueMods;@SIX_Pack1

Works all just fine with only "Extended_Eventhandlers.pbo" (XEH).

Regards,

VictorFarbau

Share this post


Link to post
Share on other sites

Hmm... Still problem here...

I have updated smokeshell addon on the server and restarted it.

I have try the same sample mission - I have shooted to enemy

AI and waited... Nothing happens... Tested it 3 times...

Maybe AI in player group will throw smoke grenades, but enemy AI

still aren't throwing it on dedicated server (trying with the same

version of addon on the server and client, XEH 1.0)

Share this post


Link to post
Share on other sites

groch

what other addons You use on server ...

there must be some reason it fails ...

Share this post


Link to post
Share on other sites
groch

what other addons You use on server ...

there must be some reason it fails ...

When I have tested, on the server there was:

dooacs.pbo

plants.pbo (vegetation fix)

six_repl_aiaccuracy.pbo

six_repl_airange.pbo

extended_eventhandlers.pbo

vfai_equipment.pbo

vfai_smokeshell.pbo

I have made a 2 sample missions: first - enemy AI is a rifleman

without SmokeShell. second - enemy AI is a Marksman with

SmokeshellRed, SmokeShellGreen and manually added SmokeShell.

Fisrt I have run first mission, shoted to enemy and waited - nothing

happens. Killed him and looked in to his gear - no SmokeShell.

Second I have run second mission, shooted to AI and waited - nothing

happens. Killed hima nd looked in to his gear - SmokeshellRed, SmokeShellGreen and manually added SmokeShell.

Dedicated server using the same version of XEH and VFAI_smokeshell (1.2 from 2.3 release) as I, client, player

connected to that server...

PS. I have tried to test it even, when all other addons on the server was disabled (only VFAI and XEH)

Share this post


Link to post
Share on other sites

Its always worked on our dedi server with AI and smoke shells???

But we will be testing this version once we get our dedi back due to a problem.

Share this post


Link to post
Share on other sites

@MattRochelle

It always worked but only for units "local" to the server (mainly enemy AI units). Your own group was always considered "local" to the current group leaders PC, hence the script was often not run.

Not a major bug but it needed to be fixed.

VictorFarbau

Share this post


Link to post
Share on other sites
Dedicated server using the same version of XEH and VFAI_smokeshell (1.2 from 2.3 release) as I, client, player

connected to that server...

PS. I have tried to test it even, when all other addons on the server was disabled (only VFAI and XEH)

Hmm... at the time you tried with only the VFAI and XEH addon(s), where were they placed and what -mod=... shortcut did you use?

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  

×