Jump to content
alarm9k

Smarter tanks script

Recommended Posts

Hello, and Thanks for the update, However, a signature doesnt do any good with out a key. Remember, you share the one that ends in ".bikey"... you NEVER share the one that ends with ".privatekey"

Thanks again.. I look foreward to putting this on my server with your Sig instead of mine.

Share this post


Link to post
Share on other sites
signature doesnt do any good with out a key

Silly me, I thought my public key was included in the signature file. Version 1.7.1 includes public key.

Share this post


Link to post
Share on other sites

Just tested for about an hour with RDS Tank Pack and BWMod. None of available tanks included in these two mods want to shoot main cannon at helicopters, all of them use only MGs to shoot them down. Tested also with CSAT Replacement Mod - modded T-100 will also not fire its main cannon at helicopters. I managed only all vanilla tanks to shoot main cannot at them, none from mods. Can you take a look at this issue?

Share this post


Link to post
Share on other sites
Can you take a look at this issue?

Sure, I know what causes that. Will fix that in a couple of days.

Share this post


Link to post
Share on other sites

New version 1.8 is available.

v.1.8

-Fixed: commander stuck watching the same direction forever after has been given doTarget order.

-Fixed: 'lazy' target switching. Will now immediately switch to more valueable target.

-Fixed: setup.sqf non starting for vehicles with non-standard names (modded). Should now work for any vehicle that has weapons (list of weapons is still hardcoded though).

-Fixed: small fixes here and there.

-Added: vehicle commander (or gunner, if no commander) will 'scan the horizon' for targets when idle. Commander will use his optics independently of gunner's main turret.

P.S. There is a trade-off though: commander's automatic 'scan the horizon' feature will reset gunner's 'Watch direction' orders (if any) from time to time.

Edited by alarm9k

Share this post


Link to post
Share on other sites

alarm9k, do you think this script could work for Iron Front too?

Share this post


Link to post
Share on other sites
do you think this script could work for Iron Front too?

I don't know much about Iron Front. Is it Arma2 Iron Front? Anyway, since version 1.8 the only hardcoded things remaining are:

  • Whether the vehicle is a tracked vehicle is determined by its parent "Tank" class.
  • Weapon turret paths: [0], [0,0], [-1].
  • Weapon names, to calculate threat from the particular weapon
  • General target classes (CAManBase, Car, Tank etc), to determine what can be damaged by particular weapon to prevent firing MG at tanks.

That's it... I think. If the things above are not modified in your mod then it will work. If not, then you'll have to make adjustments to the script code.

Oh... and if Iron Front is an Arma2 mod, then... it may not work due to using the scripting commands available only in Arma3.

Share this post


Link to post
Share on other sites
Guest

New version frontpaged on the Armaholic homepage.

================================================

We have also "connected" these pages to your account on Armaholic.

This means in the future you will be able to maintain these pages yourself if you wish to do so. Once this new feature is ready we will contact you about it and explain how things work and what options you have.

When you have any questions already feel free to PM or email me!

Share this post


Link to post
Share on other sites

BTW just did a quick and simple performance testing (quick because of lack of free time, haven't done before because of messy development style). Those of you who were concerned about the mod being performance friendly (including myself), rest assured -- seems like it is... mostly.

Test:

-created in Editor, run in Preview

-standing in the middle of Altis big dry lake

-40 tanks with AI crews standing far beyond the view distance

-no enemy targets

Result with addon enabled: 65 fps.

Result with addon disabled: 67 fps.

Of course with multiple targets know to each of the tank the result would be different, but not drasticly because the idle loop includes most of the checks anyway. Run on i7 3770K@4.5, measured with Fraps.

Edited by alarm9k
spellcheck

Share this post


Link to post
Share on other sites
Just tested for about an hour with RDS Tank Pack and BWMod. None of available tanks included in these two mods want to shoot main cannon at helicopters, all of them use only MGs to shoot them down.

Did ya fix this? Ya mentioned "some fixes" - it is?

Share this post


Link to post
Share on other sites

would this help with general behavior of AI tank gunners in MP?

For example) Human commander orders gunner to target hostile tank. AI gunner continues looking in whatever direction he feels like, regardless of ANYTHING the commander does.

Share this post


Link to post
Share on other sites
Human commander orders gunner to target hostile tank.

The script currently does not affect vehicles with human crew members.

Edited by alarm9k
typo

Share this post


Link to post
Share on other sites

alarm9k mate, it seems the latest A3 update broke the script. Gunners now point at something in the distance and fail to engage mechanized targets much of the time. I hope you can figure it out!

Share this post


Link to post
Share on other sites

Does this script need to run where the unit is local ? Or is is enough to execute it on the server?

Share this post


Link to post
Share on other sites

In my mind the biggest problem with AFV AI is the tendency to move like an infantryman and charge the enemy to shoot them at point blank range. Without fail, this brings tanks within range of every handheld AT weapon and exposes their flanks.

Could the mod change their movement behavior (when there are no Move waypoints) to make them stop and lob HE from 800m instead of going in for a bizarre and suicidal knife-fight?

Share this post


Link to post
Share on other sites

Just checking - this does pickup non vanilla vehicles right ? I.e. RHS Tanks ? RDS Tanks ?

Cheers

Share this post


Link to post
Share on other sites

I don't know much about Iron Front. Is it Arma2 Iron Front? Anyway, since version 1.8 the only hardcoded things remaining are:

  • Whether the vehicle is a tracked vehicle is determined by its parent "Tank" class.
  • Weapon turret paths: [0], [0,0], [-1].
  • Weapon names, to calculate threat from the particular weapon
  • General target classes (CAManBase, Car, Tank etc), to determine what can be damaged by particular weapon to prevent firing MG at tanks.
That's it... I think. If the things above are not modified in your mod then it will work. If not, then you'll have to make adjustments to the script code.

Oh... and if Iron Front is an Arma2 mod, then... it may not work due to using the scripting commands available only in Arma3.

 

Hello,

 

This smarter tanks mod is a great idea thanks for doing it.

 

Iron Front 44 (which is WW2) has been ported to ARMA3 and offers the best WW2 tanking sim experience one can get. I have applied your mod there and it appears to work.

 

One thing I would like to ask for is a WW2 tanking adaption of the smarter tanks mod.

 

The reason is that WW2 tanks did not generally fire on the move like the modern ones can and do.

 

Mostly when moving the guns were hitched so that the elevation mechanisms were not damaged from the stresses of moving. All aiming and shooting was strictly analog, no computers no automation of any sort. To fire the tank one had to stop, unhitch the gun, take aim and fire, rehitch the gun and move on.

 

Another important factor in the old days was angling the armour on the tank. This is explained here: http://steamcommunity.com/id/RCpanzertank/myworkshopfiles/?section=guides

 

Generally tanks tried to present corners to the enemy in order to both thicken their armour and also to promote a deflection of the incoming round. Very important for heavily armoured tanks like the Stalin and Tiger who could really use this feature to its maximum advantage.

 

I wonder if stopping to fire and angling of armour could be added to the mod for WW2 vehicles. Perhaps a completely seperate "Smarter WW2 Tanks mod" is required rather than altering the existing one.

 

Another feature would be never presenting the rear end to the enemy with the turret turned back towards the enemy and driving away (this seems to be a standard ARMA3 tank tactic). Always face the enemy, perhaps angled, and roll forwards and backwards between shots, always with the front armour of both the turret and hull towards the enemy or angled at 11 o´clock.

 

The tank and weapon names are as follows:

 

Tanks

LIB_JS2_43

LIB_PzKpfwIV_H

LIB_PzKpfwV

LIB_PzKpfwVI_B

LIB_PzKpfwVI_E

LIB_StuG_III_G

LIB_SU85

LIB_T34_76

LIB_T34_85

LIB_M4A3_75

 

Weapons

 

"LIB_D25T", "LIB_KwK40_L48", "LIB_KwK42_L70", "LIB_KwK43_L71", "LIB_StuK40_L48", "LIB_ZIS_S_53", "LIB_F34", "LIB_ZIS_S_53", "LIB_M3_L40"

If I can help in anyway please let me know as I would be happy to.

 

Thanks

 

Alan

Share this post


Link to post
Share on other sites

The mod author is no longer active unfortunately. Furthermore this mod didn't implement the hull-down tactic that you mention. Someday Bohemia must do something to fix driver and gunner AI and make them communicate to coordinate fire and hull positioning.

Share this post


Link to post
Share on other sites

Is there any way to "learn" ai drivers to drive backwards? I'm sic when they rotating whole vehicle instead of reversing. We have 2015 year, arma was released in 2013, and its playable like games from 1990.... there must be some way to reversing.... please help.

Share this post


Link to post
Share on other sites

I feel your pain. There's a command called driverOverride that can let you control the tank directly and override AI driver, but I have no idea how to script it.

Share this post


Link to post
Share on other sites

I feel your pain. There's a command called driverOverride that can let you control the tank directly and override AI driver, but I have no idea how to script it.

Init field of unit in editor? I have checked it long time ago, but it wasnt working... :( I'm gonna made my first mod, maybe i'll start today, it will change FSM files. I will try also  to make teammates moving in safemode directly behind you - as this is not fixed, beacuse they got raised weapons after enemy contact, and move very slow. 2 years of waiting is enough for me. I wanna see Developers face when i  (totally amateur in coding) fix it. I will do this mod specially for this reaction.

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

×