Jump to content
genesis92x

Vcom AI V2.0 - AI Overhaul

Recommended Posts

Error undefined variable in expression _timeshot

 

VCOMAI_CombatMode.sqf, line 10

Thank you. Error is now fixed.

 

i tested this in our community with 10 players.  We didint get any errors in server rpt log.

 

But i noticed that it is hard to get AI move. When they are in danger mode, they move very slowly and run back and forth, even when they are not close tho fire fight.

 

All ai have MOVE or SAD waypoint where players are. After 30s on video, i put fast and aware status for ai groups, after that, they started moving faster (like you said in changelog)

https://youtu.be/-QWgK2uqXHg

Thanks for the video (That is quite impressive to see - I could watch that kind of AAR all day.)! I am taking a look into that now - Even without looking directly at the code I believe I have an idea of how to fix this.

 

When I spawn a group and assign BIS_fnc_taskPatrol it fails whenever VCOMAI is active.

The patrol just stands at their spawn point. (although it looks like the Team leader scans the horizon in different directions, he still just stands there).

 

init.sqf

[] execVM "VCOMAI\init.sqf";

Assign BIS_fnc_taskPatrol from my spawn script where PatrolThis is marker point.

nul = [_grp1, getMarkerPos PatrolThis,150] call BIS_fnc_taskPatrol;

Same if I spawn the units and try to use shk_patrol.

nul = [_grp1,150] execVM "scripts\shk_patrol.sqf";

Both work if I don't activate VCOMAI via init.sqf.

 

Using latest version mentioned above.

Hrm. I will have to look at what waypoints this function uses and see if I can integrate Vcom AI into them better.

 

Is there a thing where the AI run to one specific spot as some sort of safe zone or something? Everything worked pretty well, AI engaged intelligently, called in mortars on my position (I think), and all in all seemed to act more human. However when I came to a location I placed enemies, there was no one there, then I see just this horde of AI gathering around one spot that had a Colonel ranked AI. I mean AI came from all around the map, leaving their positions to come to this one little area. Maybe it's a setting with the hearing or reaction thing (Despite this area having no combat around it)?

What an odd thing. I have seen multiple AI use the same building as cover, but never such a convergence like this. Does this mission use any mods or anything? I am asking because I would like to see the behavior to better pin-point what is going on.

If you are trying to play a mission and need a temp fix I would try lowering their response range and give AI HOLD waypoints where you want them to stick. (Let me know if they even do this odd bug with a HOLD waypoint). If you can somehow upload the mission and give it to me, that'd be great. (If it has mod requirements, I will have to figure it out another way).

 

 

Really like using this mod, adds so much more to the COOP gameplay. I had a quick search of the thread but couldn't find a link to a Steam Workshop version - I know not everyone is a fun of releasing on there but do you plan to have a version on the Workshop?

Thank you! I realized recently how commonly used Steam Workshops are. I need to upload Vcom AI to that, and will do so for my next version :)

 

 

 

 

 

 

 

 

This leads me to my another question - When I am testing I am only testing with a maximum of two people and would love an opportunity to simply watch the AI and debug them with a larger # of people present. I would simply see more that way. If any group is willing to let me join in and simply watch (Via Zeus or any other camera function really) I would be extremely grateful for that. PM me if you are willing :)

Share this post


Link to post
Share on other sites

Does every player on a server that runs the mod need it, or does it suffice if the server just gets it? :)

Share this post


Link to post
Share on other sites

Does every player on a server that runs the mod need it, or does it suffice if the server just gets it? :)

Any machine that is controlling AI (AI spawned locally to that machine) will need the mod if they wish to run with the AI.

Share this post


Link to post
Share on other sites

I once started a server with the VcomAi.
 
If anyone has interest to play here is the server IP: 178.32.49.181:2302
 
Free Addons:
 
@CBA_A3
@TFAR
@KSK 2035 - Tropic  
@Arma Enhanced Movement
@ShackTac User Interface
@C2 - Command & Control (V1.4.5)

 

 

Game Info

 

Liberation 0.924 Tanoa ( Apex-Dev. )

 

 

 

PS: @genesis92x has all rights to the server and can the AI Optimize

Share this post


Link to post
Share on other sites

Okay here is (I believe) the final test version before I 'officially' release the update.

 

 

Vcom AI 2.6 Test Version - Round 2

 

Here is the full change log again - fixed the bugs reported in this thread. At least... I did for my tests.

 

 

 

 

*OPTIMIZATION* Replaced MANY getvariable and setvariable commands and replacing with local variables where necessary/possible.
*OPTIMIZATION* Optimized the check AI leaders would do for enemies being inside buildings. It is less accurate overall, but should yield much better performance.
*OPTIMIZATION* Artillery firing function slightly optimized.
*CHANGED* HOLD waypoint will prevent AI from being pulled around by VCOM AI. AI will still notice fire/proceed to combat mode. AI will still take cover and move to better cover locations.
*CHANGED* HOLD waypoint will only make AI garrison if the waypoint is within 15 meters of a building.
*CHANGED* AI will surpress enemies better.
*CHANGED* AI will respect Zeus waypoints even better now. (Make sure to use "FULL" movement if you want them to move NOW)
*NEW* AI will not leave their cover if they have shot recently.
*NEW* AI will do much better with CQB. The amount of times enemy AI will run right by each other should be drastically reduced.
*NEW* AI can not see through smoke grenades
*NEW* AI set on "FULL" speed will charge their enemies and disregard cover unless under direct fire.
*NEW* AI's accuracy/vision is impact my rain intensity.
*NEW* AI defined as medics (by default, or by using the setUnitTrait command, will automatically heal hurt squad members when THEY deem is safe enough)
*FIXED* New vanilla units for Tanoa will deploy static weapons
*FIXED* Artillery units will now fire properly.
*FIXED* AI will ignore high flying aircraft for movement commands. This prevents AI trying to capture planes and rainbows.
*FIXED* AI's increasing accuracy system now works properly. The AI's accuracy will slowly increase as their enemies stick in one spot. Their accuracy is reset when target moves a short distance.
*FIXED* Fixed FSM hangup where AI would get stuck in a certain function - causing them to respond less to threats.
*FIXED* AI helicopters no longer attempt to fly into space with VCOM_AIDEBUG = 1 command.
  • Like 2

Share this post


Link to post
Share on other sites


20:39:31 Error in expression <osestObject;};

while {(_Unit distance _ClosestPos) > 3 && alive _Unit} do

{

_>

20:39:31 Error position: <_ClosestPos) > 3 && alive _Unit} do

{

_>

20:39:31 Error Undefined variable in expression: _closestpos

20:39:31 File C:\Users\Mika\Documents\Arma 3 - Other Profiles\Tuntematon[HAKA]\missions\COxx_Brits_Try_Again.fata\VCOMAI\Functions\VCOMAI_GarrisonClearPatrol.sqf, line 31

Share this post


Link to post
Share on other sites
20:39:31 Error in expression <osestObject;};


while {(_Unit distance _ClosestPos) > 3 && alive _Unit} do
{

_>
20:39:31   Error position: <_ClosestPos) > 3 && alive _Unit} do
{

_>
20:39:31   Error Undefined variable in expression: _closestpos
20:39:31 File C:\Users\Mika\Documents\Arma 3 - Other Profiles\Tuntematon[HAKA]\missions\COxx_Brits_Try_Again.fata\VCOMAI\Functions\VCOMAI_GarrisonClearPatrol.sqf, line 31

 

 

Perfect, thank you. It is fixed now.

 

Tomorrow will be my final bug fixing day before I push out the release. It seems pretty stable but I will be planning on hopping to a server to check it out. The 4th of July is always a hectic time for family, so not much scripting got done ^_^

  • Like 1

Share this post


Link to post
Share on other sites

Is there any reason AI helicopters wouldn't follow a transport unload order? I was running a simple test mission when I realized the AI helo would follow a move trigger, but not a transport unload, nothing crazy in the mission except some addon units and gear (CUP/RHS). Perhaps an issue with my addon load order, if that's even a thing with Arma?

Share this post


Link to post
Share on other sites

Is there any reason AI helicopters wouldn't follow a transport unload order? I was running a simple test mission when I realized the AI helo would follow a move trigger, but not a transport unload, nothing crazy in the mission except some addon units and gear (CUP/RHS). Perhaps an issue with my addon load order, if that's even a thing with Arma?

 

In the test version the waypoints seem to function just fine.

 

Getting helicopters to land in ArmA (especially while under fire) has always been a struggle. Adding VCOM AI on top of that can make it difficult. I would look up how to force AI to land with vanilla ArmA and use some of those tricks first and see if the helicopter pilot lands.

Share this post


Link to post
Share on other sites

Vcom AI Update: Version 2.6

 

Okay, here is an update to VCOM AI. Let me know how it goes. I had a lot of help de-bugging the most obvious problems. Please let me know if you run into any others so  I can fix em for the next verison.

Thank you!

 

VCOM AI Script Version 2.6

VCOM AI Mod Version 2.6

VCOM AI Quick Showcase

 

Changelog

 

*OPTIMIZATION* Replaced MANY getvariable and setvariable commands and replacing with local variables where necessary/possible.

*OPTIMIZATION* Optimized the check AI leaders would do for enemies being inside buildings. It is less accurate overall, but should yield much better performance.
*OPTIMIZATION* Artillery firing function slightly optimized.
*CHANGED* HOLD waypoint will prevent AI from being pulled around by VCOM AI. AI will still notice fire/proceed to combat mode. AI will still take cover and move to better cover locations.
*CHANGED* HOLD waypoint will only make AI garrison if the waypoint is within 15 meters of a building.
*CHANGED* AI will surpress enemies better.
*CHANGED* AI will respect Zeus waypoints even better now. (Make sure to use "FULL" movement if you want them to move NOW)
*NEW* AI will not leave their cover if they have shot recently.
*NEW* AI will do much better with CQB. The amount of times enemy AI will run right by each other should be drastically reduced.
*NEW* AI can not see through smoke grenades
*NEW* AI set on "FULL" speed will charge their enemies and disregard cover unless under direct fire.
*NEW* AI's accuracy/vision is impact my rain intensity.
*NEW* AI defined as medics (by default, or by using the setUnitTrait command, will automatically heal hurt squad members when THEY deem is safe enough)
*NEW* AI that wander too far from their group will attempt to re-group if possible.
*FIXED* New vanilla units for Tanoa will deploy static weapons
*FIXED* Artillery units will now fire properly.
*FIXED* AI will ignore high flying aircraft for movement commands. This prevents AI trying to capture planes and rainbows.
*FIXED* AI's increasing accuracy system now works properly. The AI's accuracy will slowly increase as their enemies stick in one spot. Their accuracy is reset when target moves a short distance.
*FIXED* Fixed FSM hangup where AI would get stuck in a certain function - causing them to respond less to threats.
*FIXED* AI helicopters no longer attempt to fly into space with VCOM_AIDEBUG = 1 command.
*FIXED* Fixed AI squads getting stuck in certain cases and not advancing to a target.
*FIXED* Fixed AI squad leaders from charging off into the distance in most cases.
  • Like 1

Share this post


Link to post
Share on other sites

In the test version the waypoints seem to function just fine.

 

Getting helicopters to land in ArmA (especially while under fire) has always been a struggle. Adding VCOM AI on top of that can make it difficult. I would look up how to force AI to land with vanilla ArmA and use some of those tricks first and see if the helicopter pilot lands.

 

I tried without VCOM and it worked fine, including using 'helo_name land "land01";'. Strange issue, but I'll try the new version and see what's what, I definitely don't want to give up using this for one issue, VCOM is probably one of the best AI mods I've tried out of any of the Arma games!  

Share this post


Link to post
Share on other sites

 

Vcom AI Update: Version 2.6

 

Okay, here is an update to VCOM AI. Let me know how it goes. I had a lot of help de-bugging the most obvious problems. Please let me know if you run into any others so  I can fix em for the next verison.

Thank you!

 

VCOM AI Script Version 2.6

VCOM AI Mod Version 2.6

VCOM AI Quick Showcase

 

Thanks for the update!

Share this post


Link to post
Share on other sites

Awesome release.

 

This is perfect for ALiVE, which by default does not call in artillery :(

  • Like 1

Share this post


Link to post
Share on other sites

Question regarding the mod version, does everyone need the addon when playing on dedi or just server/hc/zeus?

  • Like 1

Share this post


Link to post
Share on other sites

@Bamse

 

Everyone should not need the addon. The addon will not do anything unless you comeback as isServer == true. So if a client has the addon, it will do nothing.

  • Like 2

Share this post


Link to post
Share on other sites

@Bamse

 

Everyone should not need the addon. The addon will not do anything unless you comeback as isServer == true. So if a client has the addon, it will do nothing.

 Roger that! Thanks for the speedy answer, much appreciated.

  • Like 1

Share this post


Link to post
Share on other sites

Loving the new version! However, I am unfortunately still having the issue of helicopters not wanting to follow transport unload waypoints (just that helo on the map and some units in cargo). I suppose it's not much of an issue, only problem is when helicopters are in a mission, is there perhaps a way for me to disable VCOM on helicopters?

  • Like 1

Share this post


Link to post
Share on other sites

Finding that some troops are kneeling rapidly (good) then waving weapons side to side rapidly (not so good)

  • Like 1

Share this post


Link to post
Share on other sites

Thank you for a new version! :) 

Most features seem to be working fine. But AI skill setting seem broke.

 

In my AISettingsV2.hpp for Private Level AI I have:
_Unit setSkill ["spotDistance",(0.1 + (random 0.1))];

_Unit setSkill ["spotTime",(0.1 + (random 0.1))];

1 prone shot from 500m away on a squad of "privates" and I am immediately detected and fired upon.
Addon version with cba and Vcom only.

 

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

×