Project Perfect Mod Forums
:: Home :: Get Hosted :: PPM FAQ :: Forum FAQ :: Privacy Policy :: Search :: Memberlist :: Usergroups :: Register :: Profile :: Log in to check your private messages :: Log in ::


The time now is Thu Mar 28, 2024 10:28 pm
All times are UTC + 0
Speaker Tower Breaking AI
Moderators: Global Moderators, Red Alert 2 Moderators
Post new topic   Reply to topic Page 1 of 1 [5 Posts] Mark the topic unread ::  View previous topic :: View next topic
Author Message
PePsiCola
Cyborg Specialist


Joined: 28 Dec 2010
Location: The United States

PostPosted: Wed Feb 17, 2016 9:41 pm    Post subject:  Speaker Tower Breaking AI Reply with quote  Mark this post and the followings unread

So as I covered in my last topic in this forum, the Chinese AI in my mod had suffered an inability to rebuild important buildings (factories, battle labs, superweapons, etc), and would only build Tesla Reactors and base defenses. The cause was clearly one of the China-specific defenses, the Thermal Gun or the Speaker Tower. By removing them and re-adding one at a time, I was able to figure out that the Speaker Tower was the problem.

What is strange is that this issue occurs simply by allowing the AI to build it. Whether it is listed under SovietBaseDefenses, or treated as a regular non-defense building the AI only builds one of, the problem occurs. The only two features of this building that no others have are being an EMPulseCannon with a superweapon auto-firing every few seconds (the only way I know of to make a Speaker Tower), and a weapon that deals negative damage. I wouldn't think either of these would be an issue, and the building works perfectly fine, other than screwing up the AI.

Code:
[NASTWR]
UIName=Name:NATWR
Name=Speaker Tower
Image=NATOWR
BuildCat=Combat
Prerequisite=NATECH,NACNST
Strength=400
Armor=concrete
TechLevel=8
Adjacent=3
Sight=8
ForbiddenHouses=British,French,Germans,Americans,Alliance,Russians,Confederation,Africans,Arabs,YuriCountry,Ukraine,Greece,Italy,Norway
Owner=Chinese
AIBasePlanningSide=1
Cost=2000
Points=30
Power=-100
Crewed=no
Capturable=false
Explosion=TWLT070,S_BANG48,S_BRNL58,S_CLSN58,S_TUMU60
Primary=STBuff
EMPulseCannon=yes
SuperWeapon=SpeakerSpecial
HasRadialIndicator=true
ConcentricRadialIndicator=true
Turret=no
TurretAnimZAdjust=-100
DebrisAnims=Dbris1sm,Dbris1lg,Dbris4sm,Dbris5sm,Dbris4lg,Dbris7sm,Dbris8sm,Dbris5lg,Dbris4lg
MaxDebris=15
MinDebris=5
ThreatPosed=40 ; This value MUST be 0 for all building addons
DamageParticleSystems=SparkSys,SmallGreySSys,BigGreySmokeSys
DamageSmokeOffset=96, 64, 112
IsBaseDefense=yes
BaseNormal=yes
Powered=yes
HasStupidGuardMode=false
WorkingSound=PowerOn
NotWorkingSound=PowerOff
ImmuneToPsionics=no
Drainable=yes
AntiInfantryValue=15
AntiArmorValue=15
AntiAirValue=0
SolidLevel=0

[STBuff]
Damage=65
ROF=300
Range=-2
Projectile=Invisible
Speed=100
Warhead=PVWarhead
AreaFire=yes

[PVWarhead]
Wall=no
Wood=no
Verses=-100%,-100%,-100%,-100%,-100%,-100%,0%,0%,0%,-100%,100%
InfDeath=0
AttachEffect.FirepowerMultiplier=1.25
AttachEffect.Duration=300
AttachEffect.Animation=POSFPWR
CellSpread=7.5
PercentAtMax=.5
AffectsAllies=yes
AffectsEnemies=no

_________________
Tiberium Uprising (a few missions for TS): http://www.ppmsite.com/forum/viewtopic.php?t=31029

Back to top
View user's profile Send private message
Lin Kuei Ominae
Seth


Joined: 16 Aug 2006
Location: Germany

PostPosted: Thu Feb 18, 2016 7:49 am    Post subject: Reply with quote  Mark this post and the followings unread

remove IsBaseDefense=yes and add AIBuildThis=yes
The AI has no clue how to handle such a defense building. It has no idea how many it has to build, that these are high tech defenses and thus only late available, nor that these will make the AI go broke when building several of these (due to the high cost)
I'm not sure, but i think base defenses also need to be at RADAR tech level or lower, due to the way the AI builds up its base. And when it tries to build a TechCenter level defense, without having a tech center, it stops working at all.

Use AIBuildThis=yes and if you want the AI to build more than only 1, add some clones, which are buildable by the AI only (not for human)

_________________
SHP Artist of Twisted Insurrection:  Nod buildings

Public SHPs
X-Mech Calendar (28 Mechs for GDI and Nod)
5 GDI, 5 Nod, 1 Mutant, 1 Scrin unit, 1 GDI building

Tools
Image Shaper______TMP Shop______C&C Executable Modifier

Back to top
View user's profile Send private message
MustaphaTR
Scorpion Sniper


Joined: 22 Jan 2015
Location: Kastamonu, Turkey

PostPosted: Thu Feb 18, 2016 3:18 pm    Post subject: Reply with quote  Mark this post and the followings unread

My GLA AI builds their Sniper Towers with no problem. 3rd tier defences shouldn't broke ai.

_________________
CnCD2K Mod: http://www.moddb.com/mods/red-alert-2-yuris-revenge-cncd2k-mod
Changed Dune Mod: http://www.moddb.com/mods/changed-dune
MustaphaTR's D2K Mod: http://www.moddb.com/mods/mustaphatrs-d2k-mod
Generals Alpha: http://www.moddb.com/mods/generals-alpha
Romanov's Vengeange: https://www.moddb.com/mods/romanovs-vengeance

Back to top
View user's profile Send private message
PePsiCola
Cyborg Specialist


Joined: 28 Dec 2010
Location: The United States

PostPosted: Thu Feb 18, 2016 4:06 pm    Post subject: Reply with quote  Mark this post and the followings unread

Almost every country in my mod has their own tier 3 defenses (and only two cost a bit over $2000) with zero issues, so it probably isn't that.

Funny thing is, I've already tried making the AI treat them as non-defensive buildings (taken off list of defenses, with AI only clones, and removing the defense-specific tags), and this is why it really baffles me.

You can find more detail on the issue here, if it helps:
http://www.ppmforums.com/viewtopic.php?t=40517

_________________
Tiberium Uprising (a few missions for TS): http://www.ppmsite.com/forum/viewtopic.php?t=31029

Back to top
View user's profile Send private message
PePsiCola
Cyborg Specialist


Joined: 28 Dec 2010
Location: The United States

PostPosted: Mon Jan 02, 2017 3:20 pm    Post subject: Reply with quote  Mark this post and the followings unread

Reviving this thread to revisit this still unsolved issue. I'm trying to balance out every country's AI against one another, and I figure one way to buff China against others is to get the Speaker Tower working for them.

So a lot of my coding is based on what has been shared by others who have no problem with working Speaker Towers (now I don't know if they use it for their AI as well, since my issue only lies with AI use). And of course, the building itself works great. Surely someone has their AI building Speaker Towers without any issues.

I'm beginning to wonder if the issue lies in the fact that the tower has a weapon with negative verses (I've also tried with positive verses and negative damage). This is the only statistic of the Speaker Tower shared with no other building in the game. There is one other noteworthy feature of the weapon that some part of me wants to believe may be causing this. As with a terror drone attack, or anytime damage is dealt to a unit which cannot retaliate to the firing weapon, AI units scatter when hit by the weapon. I've never seen this done by a building weapon used by the AI either, so perhaps there is something behind this as well.

_________________
Tiberium Uprising (a few missions for TS): http://www.ppmsite.com/forum/viewtopic.php?t=31029

Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [5 Posts] Mark the topic unread ::  View previous topic :: View next topic
 
Share on TwitterShare on FacebookShare on Google+Share on DiggShare on RedditShare on PInterestShare on Del.icio.usShare on Stumble Upon
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © phpBB Group

[ Time: 0.1389s ][ Queries: 11 (0.0071s) ][ Debug on ]