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 9:37 pm
All times are UTC + 0
AI exploits and how to fix them
Moderators: Global Moderators, Tiberian Sun Moderators
Post new topic   Reply to topic Page 1 of 1 [7 Posts] Mark the topic unread ::  View previous topic :: View next topic
Author Message
SuperJoe
Commander


Joined: 03 Sep 2009

PostPosted: Fri Oct 15, 2010 4:31 am    Post subject:  AI exploits and how to fix them Reply with quote  Mark this post and the followings unread

I've recently been working with AI alot, and trying to fix some major exploits human players can do to it. Of course the AI will never be as smart as human players, but the less exploitable it is the better. Here are some of the bigger issues:

1. AI does not respond to being fired on by particle based damage, such as the Devil's Tongue flame tank. I actually got this fixed, the solution will be further down the post.

2. Once AI unit gets EMP'd it loses track of what it was doing. Very very exploitable, especially to AI harvesters. You can basically EMP all his harvesters and he will never understand to replace them.

3. AI units that don't have anti-air weapons will still try to target flying jumpjet troopers. Basically you can lure an entire team after your jumpjets and slowly but steadily kill them off. The solution would be to just ignore being fired on by jumpjets, like they do against airplanes. But I haven't found any way to do this.

4. AI does not automatically target units along the way. You can make them respond to being fired on, but I haven't found any way to make AI stop and take out whatever units come into its weapon range. This would improve the AI alot since they would actively take out hijackers, suicide units, etc. Also anti-air units are quite useless with AI attack forces since they only target enemy aircraft when being attacked, which most of the time is way too late.

Anyone have ideas or knowledge how to fix these issues? Like I said earlier I did find a way to fix the particle damage thing. You need to edit the fire based weapon to use the Reaper missile logic. Here I've edited the devil's tongue weapon:

Code:

[FireballLauncher]
Damage=0
AmbientDamage=2
ROF=50
Range=4.25
Speed=75 ;1 ; This was changed
Warhead=Fire
Report=FLAMTNK1
UseFireParticles=yes
AttachedParticleSystem=FireStreamSys
Burst=2
ProjectileRange=2 ; Added these 2 keys to use reaper logic
Projectile=FireballFixPR ;Invisible

; Reaper logic weapon attached to FireballLauncher to make AI retaliate
[FireballFix]
Damage=1 ; Gets multiplied by 10, so adjust verses in warhead.
ROF=1000
Range=4 ; Allows them to hit far since the particle flames can travel far too
Speed=100 ; To make sure they always hit
Warhead=FireballFixWH
Projectile=FireballFixPR2


Add the new projectiles:

Code:

; Used by 1st stage of reaper logic attached to FireballLauncher
[FireballFixPR]
Image=INVPROJ ; Need to define an image or the missile logic doesn't work
High=no
VeryHigh=no
Proximity=no
Cluster=2
Ranged=yes
Range=4
ROT=8
Splits=yes
AirburstWeapon=FireballFix
IgnoresFirestorm=no
RetargetAccuracy=50% ; So force-firing ground usually hits enemy too

; Used by 2nd stage of reaper logic attached to FireballLauncher
[FireballFixPR2]
Image=INVPROJ
High=yes
Shadow=no
Proximity=yes
Ranged=no


And finally add the new warhead:

Code:

[FireballFixWH]
Spread=6
Verses=10%,10%,10%,10%,10% ; Will even out the dmg to 1
InfDeath=4
ProneDamage=100% ; Always force that 1 dmg


In art.ini add the following:

Code:

; *** Projectile Objects ***

[INVPROJ]


Also remember to add the new warhead to the warheads list, and more importantly, remember to give FireballFix as a primary, secondary or elite weapon to some fake unit, like the Weedguy infantry. Every weapon has to be used by at least one unit in rules.ini or the game will cause an IE. I've included the INVPROJ shp as attachment to this post.

Basically this fix will make the devil's tongue fire both the normal fire attack and an invisible weapon that deals 1 damage. That 1 damage will be enough to make the AI target and destroy the unit. Even if you force-fire close to the enemy they will get mad at you since the invisible reaper "missiles" home in on units. So much for owning all those Disk Throwers with a single flame tank...  Cool

Interesting but off-topic thing to note is that by using particle based weapon + reaper logic you could add more than 2 weapons for a unit, actually up to 4. They would just fire in pairs, at the same time. By tweaking the reaper logic into more stages I guess you could go even for more weapons.



invproj.shp
 Description:
The invisible projectile

Download
 Filename:  invproj.shp
 Filesize:  32 Bytes
 Downloaded:  261 Time(s)



Key Words: #Tutorials #Modding #TiberianSun #Firestorm #Rules.INI 

_________________

Last edited by SuperJoe on Sat Oct 16, 2010 9:46 am; edited 1 time in total

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


Joined: 16 Aug 2006
Location: Germany

PostPosted: Fri Oct 15, 2010 10:25 am    Post subject: Reply with quote  Mark this post and the followings unread

Why do you use the reaper split logic?
Simply give the FireBallLauncher Damage=1 and an invisible projectile. Wink

SuperJoe wrote:
Interesting but off-topic thing to note is that by using particle based weapon + reaper logic you could add more than 2 weapons for a unit, actually up to 4. They would just fire in pairs, at the same time. By tweaking the reaper logic into more stages I guess you could go even for more weapons.

And you could also assign a railgun, a laser and an art.ini area weapon, which makes a unit fire with one shot up to 5 different weapons at the same time. #Tongue

_________________
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
SuperJoe
Commander


Joined: 03 Sep 2009

PostPosted: Fri Oct 15, 2010 11:40 am    Post subject: Reply with quote  Mark this post and the followings unread

Using normal damage and fire particles together on a weapon works? I tested it with this

Code:

[FireballLauncher2] ; Changed to make sure it isn't hardcoded
Damage=100
;AmbientDamage=2
ROF=50
Range=4.25
Projectile=Invisible
Speed=100
Warhead=Fire
Report=FLAMTNK1
UseFireParticles=yes
AttachedParticleSystem=FireStreamSys
Burst=2


and it won't deal damage with anything else than the particles. Think UseFireParticles=yes makes it ignore normal weapon properties. Also reaper logic makes force-firing the ground (those particles would still hit the infantry) hit the enemy unit with that 1 damage.

How does multiple particle system weapons work together? Before using the reaper logic I gave the FireballLauncher IsRailgun=yes, which made it fire both of its flamethrowers at the same time, but only once, then it would resume to using only 1 at a time. Needed to change its facing and target to get it to fire both at the same time again. It would be pretty cool to get it to always fire both flamethrowers (ofc tone down dmg by half).

_________________

Back to top
View user's profile Send private message
^Rampastein
Rampastring


Joined: 11 Oct 2008
Location: Gensokyo

PostPosted: Fri Oct 15, 2010 2:52 pm    Post subject: Reply with quote  Mark this post and the followings unread

SuperJoe wrote:
3. AI units that don't have anti-air weapons will still try to target flying jumpjet troopers. Basically you can lure an entire team after your jumpjets and slowly but steadily kill them off. The solution would be to just ignore being fired on by jumpjets, like they do against airplanes. But I haven't found any way to do this.

You can make the AI counter this by adding AA units to most taskforces. This will in some cases make their taskforces more expensive and less effective against ground units though, depending on the mod.

_________________
CnCNet Client | CnCNet TS patches | More Quality-of-Life Improvements for RA Remastered


Back to top
View user's profile Send private message ModDB Profile ID Facebook Profile URL
SuperJoe
Commander


Joined: 03 Sep 2009

PostPosted: Sat Oct 16, 2010 9:50 am    Post subject: Reply with quote  Mark this post and the followings unread

I further tweaked the FireballLauncher weapon. Now it works as intended, doesn't matter whether you directly attack a unit or force-fire the ground close to enemy units, they will get mad at the flame tank and take it out. I updated the code in the 1st post to this improved version.

_________________

Back to top
View user's profile Send private message
TK3600
Medic


Joined: 26 Aug 2017

PostPosted: Tue Jun 26, 2018 3:50 pm    Post subject: Reply with quote  Mark this post and the followings unread

3. Make jumpjet infantry uncrushable.
4. Opportunityfire=yes for turreted unit, no solution otherwise.

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


Joined: 16 Aug 2006
Location: Germany

PostPosted: Tue Jun 26, 2018 8:32 pm    Post subject: Reply with quote  Mark this post and the followings unread

TK3600 wrote:
3. Make jumpjet infantry uncrushable.

Are you sure that solves it?
I doubt it works, since infantry are ground units and when they shoot something that has AG=yes, they still see the flying infantry as ground targets.
TK3600 wrote:
4. Opportunityfire=yes for turreted unit, no solution otherwise.

You can't take a RA2 key and simply add to TS. It doesn't exist in TS.

_________________
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
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [7 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.1677s ][ Queries: 13 (0.0081s) ][ Debug on ]