AI scripts versus building is broken
First check
- [X] The issue happens on the latest official version of Phobos and wasn't fixed yet.
- [X] I agree to elaborate the details if requested and provide thorough testing if the bugfix is implemented.
- [X] I added a very descriptive title to this issue.
- [X] I used the GitHub search and read the issue list to find a similar issue and didn't find it.
- [X] I have attached as much information as possible (screenshots, gifs, videos, debug and exception logs, etc).
Description
The Phobos AI scripts about attacking buildings are glitched, it cannot work out well during the battle. Siege units are producted by AI but the strike team is never regrouped. When using Script Actions 10010, and the target is set to buildings (value=2, Structures) , it acts abnormal. The anti-building squads are broken, the only team that works is the team which attacks the specific building (eg. superweapon).
Phobos Version
B31
Conditions to reproduce
Ares-Phobos B31 with Syringe 0.7.3.0, in modified Mental Omega, attached with aimo here.
INI code
In rules:
[AITargetTypes]
0=GAAIRC,GAMERC,GASCEA,GASCPF,GACLAB,NARADR,NAAIR,NAPOWR,YAPSIS,YAAIRP,FACYBR,FANANO,HACORE
1=GAOREP,NAINDP,NACLON,FAREPR
2=GADEPO,GAHPAD,NAPRIS,YAVULT
3=GAGAP,GASTAS,NAIRDM,YARIFT,YARIFTAI,FACOAT,FAINHI,FAINHIB,FAAVAL
Others are in the AImo.ini (attached here)
Steps to reproduce
- Using the ai code
- Watching the AI production & combat
- "Why no siege units are sent out here?"
Expected behaviour
AI builds siege units, and the squad that attack the building is working.
Actual behaviour
The squads those who are ordered to attack the building are just staying at their bases.
Additional context
DEBUG: [FOETT117-G] [0CB13B4CC-G] (line: 2 = 10010,2) Jump to next line: 3 = 49,0 (Leader [TARCHIA] (UID: 3833819) can't find a new target)
What is a "tarchia" ? there can be some causes like the leadership values or the weapon properties used by the Team Leader, in this case a Tarchia.
if that unit not represents the whole team because other units are artilleries and they can target things the tarchia can't... then change the leadership values of the units, being the higher one of the team the Team Leader (who decides what attack). In the case of the weapons be sure that it has well defined the projectile properties like the AG=yes in this case and that the tarchia does positive damage against structures.
In that log I see similar actions that works as expected by the Leader.
Think that possibly the rulesmd.ini of that YR mod should be revised for the Team leadership if you want to use the new attack actions.
TARCHIA is an unit name, a siege cannon, in our cases all the siege weapons are not sent to their enemies. Thanks a lot! We shall try the leadership values adjusting, however these teams are definately available with ares only, so there might be more tests to do.
Sorry, I don't understand this part: "these teams are definately available with ares only"
Sorry, I don't understand this part: "these teams are definately available with ares only"
Without those codes, the siege units act as normal in ares/phobos, no matter what leadership rates they have. Still testing...:/
Can you paste the unit code & weapons & weapon projectiles? I could clarify something watching it
As you wish: [TARCHIA] UIName=NAME:TARCHIA Name=Tarchia Cannon Prerequisite=FAWEAP,FACLDP_B Gattling.Cycle=yes IsGattling=yes Ammo=3 PipWrap=3 PipScale=none EmptyReload=1 Reload=60 TurretCount=1 WeaponCount=6 BurstDelay0=50 BurstDelay1=50 BurstDelay2=50 Weapon1=TarchiaTarget EliteWeapon1=TarchiaTarget Weapon2=TarchiaTarget EliteWeapon2=TarchiaTarget Weapon3=TarchiaCannon EliteWeapon3=TarchiaCannonE Weapon4=TarchiaCannon EliteWeapon4=TarchiaCannonE Weapon5=TarchiaTarget EliteWeapon5=TarchiaTarget Weapon6=TarchiaTarget EliteWeapon6=TarchiaTarget WeaponStages=3 Stage1=100 Stage2=250 Stage3=400 EliteStage1=100 EliteStage2=250 EliteStage3=400 RateUp=1 RateDown=400 Strength=650 Category=AFV Armor=spin_medium Turret=no IsTilter=yes Crewed=no TooBigToFitUnderBridge=true TechLevel=8 Sight=6 Speed=4 SelfHealing=no CrateGoodie=yes Accelerates=true SlowdownDistance=1 AccelerationFactor=1 DeaccelerationFactor=0 MobileFire=no Crusher=no ProtectedDriver=yes Owner=Guild1,Guild2,Guild3 Cost=1650 Soylent=825 Bounty.Value=330 Bounty=yes Bounty.Display=yes PreventAttackMove=no Points=50 ROT=9 AllowedToStartInMultiplayer=no IsSelectableCombatant=yes DeathWeapon=UnitDeathWeapon Explodes=yes VoiceSelect=TarchiaSelect VoiceMove=TarchiaMove VoiceAttack=TarchiaAttackCommand DieSound=GenVehicleDie MoveSound=TarchiaMoveStart CrushSound=TankCrush MinDebris=2 MaxDebris=4 SpeedType=Hover Locomotor={4A582742-9839-11d1-B709-00A024DDAFD1} MovementZone=AmphibiousDestroyer ThreatPosed=40 DamageParticleSystems=SparkSys,SmallGreySSys DamageSmokeOffset=100,100,275 Weight=5 VeteranAbilities=STRONGER EliteAbilities=SELF_HEAL,FIREPOWER,FASTER ZFudgeColumn=8 ZFudgeTunnel=13 Size=6 OpportunityFire=no Bunkerable=no CanPassiveAquire=yes DamageSound=VehicleDamagedHeavy BuildTime.MultipleFactory=0.9 OmniCrushResistant=yes IFVMode=18 CanBeReversed=no EMP.Threshold=no Chronoshift.Crushable=no
[TarchiaTarget] Damage=1 ROF=25 Range=18 MinimumRange=5 Speed=100 Projectile=TarchiaProjFake Warhead=TarchiaTargetWH Anim=TARCMARK Ammo=0
[TarchiaProjFake] Proximity=no Image=DUMMY SubjectToCliffs=no SubjectToElevation=yes SubjectToWalls=no Arcing=yes High=yes
[TarchiaCannon] Damage=110 ROF=50 Range=18 MinimumRange=5 Projectile=TarchiaProj Speed=1 Warhead=TarchiaWH Anim=TARCTRAIX Ammo=1 Burst=3
[TarchiaProj] Proximity=no Image=TARCPROJ SubjectToCliffs=no SubjectToElevation=yes SubjectToWalls=no Arcing=yes High=yes
Try putting the AG=yes (and/or AA=yes in those units that are anti-air) in projectiles like in [TarchiaProjFake] that is the first weapon of that gattling logic.
Can you post the warhead of that fake weapon too? the: [TarchiaTargetWH]
I think that if final damage is 0 can't be promoted as Leader :-/
If the problem is that nobody in the team becomes Leader because they are similar then we should pick the first one of the taskforce as Leader and done...
I'll check the code later.
Okay here it goes: [TarchiaTargetWH] Wall=yes Wood=yes Verses=3%,3%,3%,3%,3%,3%,3%,3%,3%,3%,3% Versus.camo.PassiveAcquire=no InfDeath=0 AnimList=TARCTARG PreventScatter=yes
And, we found sref (prism tank) is also not available, so this might not be the problem of weapon itself.
debug.zip In this test, I found the siege weapons are only coming into battle when they had fired to the enemies. or they will stay in their bases, buratino/v3/athena/magnet are all the same, the AI would not build prism tank for some unknown reasons.
If they don't have the AG=yes for ground targets probably is the cause.
I remember a similar case with Yuri mindcontrol and all was because the lack of that tag in the projectile.
If they don't have the AG=yes for ground targets probably is the cause.
I remember a similar case with Yuri mindcontrol and all was because the lack of that tag in the projectile.
Ok, after testing we found the problem is the lacking AG=yes for all the projectiles used by siege weapons (including spawned aircrafts), now the problem is: shall we change the rules and you mention this in the ai scripts & mapping (as there are no such bugs without this feature), or just let the phobos set the default projectile AG=yes?
Besides, units would not counter back to tower, I know many of them have no AG=yes with their projectiles, however, siege weapons with this still not prefer to attack tower. debug.zip
So is there any result about what shall we do next? Mentioning modders should add these by themselves at the phobos note or changing the projectiles default value AG=yes? And for now, more testing were taken, but the units with projectiles AG=yes were often ingoring the towers still.
If they don't have the AG=yes for ground targets probably is the cause.
I remember a similar case with Yuri mindcontrol and all was because the lack of that tag in the projectile.
In B36, the RE issue still here, but less frequency. snapshot-20230715-222903.zip snapshot-20230715-223801.zip