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 8:57 pm
All times are UTC + 0
Weird problem or unit not voluntarily targeting?
Moderators: Global Moderators, Red Alert 2 Moderators
Post new topic   Reply to topic Page 1 of 1 [8 Posts] Mark the topic unread ::  View previous topic :: View next topic
Author Message
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Mon Oct 10, 2016 7:19 pm    Post subject:  Weird problem or unit not voluntarily targeting? Reply with quote  Mark this post and the followings unread

So I added my technical (truck mounted AA-only gun), voices, sfx, voxel, FLH, all good...

Now what happens is the unit will happily target aircraft but doesn't seem to want to bother with paratroopers, or at least it loses interest in them, it's hard to describe. If I select the unit and attack the paratrooper it will happily fire though, and may continue attacking another 1-2 after as it gets excited. Thing is where the paratroopers are well within range and just falling, and I have flak troopers right next to the technical, the trooper will fire, the technical will not.

I've played around with giving it DefaultToGuardArea but that makes them chase aircraft, even then it behaved the same way towards paratroopers.

Below is the current code, if anyone has ideas...
Code:


[TECHTRK]
UIName=Name:TECHTRK
Name=Technical AA-truck
Prerequisite=NAWEAP
Primary=TechnicalCannon
ElitePrimary=TechnicalCannonE
Strength=180
Category=AFV
Armor=medium
Turret=yes
IsTilter=yes
TooBigToFitUnderBridge=false
TechLevel=5
Sight=8
Speed=8
ROT=8
CanPassiveAquire=yes
CanRetaliate=yes
OpportunityFire=true
CrateGoodie=yes
Crusher=no
Owner=Confederation
RequiredHouses=Confederation
AllowedToStartInMultiplayer=no
Cost=380
Points=5
IsSelectableCombatant=yes
Explosion=TWLT070,S_BANG48,S_BRNL58,S_CLSN58,S_TUMU60
VoiceSelect=TechnicalSelect
VoiceMove=TechnicalMove
VoiceAttack=TechnicalAttackVoice
VoiceFeedback=
DieSound=GenVehicleDie
MoveSound=LightTankMoveStart
Maxdebris=2
SpeedType=Wheel
Locomotor={4A582741-9839-11d1-B709-00A024DDAFD1}
MovementZone=Destroyer
ThreatPosed=10   ; This value MUST be 0 for all building addons
DamageParticleSystems=SparkSys,SmallGreySSys
DamageSmokeOffset=100,80,275
Weight=3.5
VeteranAbilities=STRONGER,FIREPOWER,SIGHT,FASTER
EliteAbilities=SELF_HEAL,STRONGER,FIREPOWER,ROF
ZFudgeColumn=8
ZFudgeTunnel=13
Size=3
Accelerates=true

[TechnicalCannon] ; used by TECHTRK
Damage=20
ROF=35
Range=10
Projectile=TechnicalP
Speed=200
Report=TechnicalAttack
Warhead=TechFlakWH
Anim=GUNFIRE
Degenerates=true

[TechnicalP] ; normal inaccurate AA bullets
Image=none
Inviso=yes
AA=yes
AG=no
AN=no
Shadow=no
Inaccurate=yes   ; Bullets do not snap onto targets when "close enough".
Ranged=yes
SubjectToCliffs=no
SubjectToElevation=yes
SubjectToWalls=no

[TechFlakWH]
CellSpread=1
PercentAtMax=.1
Verses=80%,80%,80%,150%,0%,0%,0%,0%,0%,0%,100%   
AnimList=PIFF,GUNFIRE,UCFLASH
InfDeath=3
Bullets=yes


PS. I recently added Bullets=yes and Ranged=yes but they don't seem to have any impact on the issue, just let's you see bullet flames around the target.



noshooting.jpg
 Description:
 Filesize:  433.78 KB
 Viewed:  1501 Time(s)

noshooting.jpg



_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

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


Joined: 16 Aug 2006
Location: Germany

PostPosted: Mon Oct 10, 2016 8:08 pm    Post subject: Reply with quote  Mark this post and the followings unread

I'm not that experienced with RA2 modding, but i would assume it's because even paratroopers are internally seen as ground units.
Since your unit has AA=yes only weaponry, it doesn't auto-targets these flying ground units.

If i'm not mistaken do all AA units in RA2, that successfully target paratroopers, also have an AG weapon.

I would try to give the unit a dummy ground weapon. One with Damage=0, same Range as the AA weapon and a dummy Warhead with all infantry armor Verses=2% so it auto-targets them.

Since your AA weapon has higher Verses values as your AG weapon, your AA one is always used for airborne targets.

Though the dummy AG weapon could cause trouble when the unit is firing happily on ground infantry without being able to do any damage to them, while at the same time ignoring real flying threats above it.

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


Joined: 28 Sep 2013
Location: Plovdiv, Bulgaria.

PostPosted: Mon Oct 10, 2016 8:29 pm    Post subject: Reply with quote  Mark this post and the followings unread

It is something I had in my mod, before. Try those:
LandTargeting=1
NavalTargeting=6

Smile

_________________
"If it ain't broke, don't fix it."
"If you are loyal to everybody, can you truly be loyal to anybody?"
Ares Documentation: http://ares-developers.github.io/Ares-docs/
My YouTube Channel: https://www.youtube.com/channel/UCtxeQoEM_iVd-F-xUIwleyQ
PillBox20's Red Alert 2 Mod: http://www.moddb.com/mods/pillbox20s-red-alert-2/downloads/pillbox20s-red-alert-2-version-02

Back to top
View user's profile Send private message Visit poster's website YouTube User URL Skype Account
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Mon Oct 10, 2016 8:29 pm    Post subject: Reply with quote  Mark this post and the followings unread

I could try a dummy weapon ala NavalScanner with NeverUse=yes... but it is important that it doesn't shoot ground units.

_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Mon Oct 10, 2016 8:36 pm    Post subject: Reply with quote  Mark this post and the followings unread

PillBox20 wrote:
It is something I had in my mod, before. Try those:
LandTargeting=1
NavalTargeting=6

Smile

So would I change the projectiles to AG=yes with that?

_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

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


Joined: 28 Dec 2010
Location: The United States

PostPosted: Mon Oct 10, 2016 10:51 pm    Post subject: Reply with quote  Mark this post and the followings unread

Yes, that works. It's the same way you get Patriot Missiles and Flak Cannons to fire at Paratroopers. AG=yes on a projectile with LandTargeting=1 (can't fire on land), allows a weapon to fire at "ground units" (paratroopers are considered ground, as LKO stated) so long as they are in the air.

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


Joined: 11 Feb 2016

PostPosted: Tue Oct 11, 2016 7:11 am    Post subject: Reply with quote  Mark this post and the followings unread

Giving a AG fake weapon solves the problem

_________________

Back to top
View user's profile Send private message Skype Account
G-E
Defense Minister


Joined: 09 Feb 2015

PostPosted: Fri Oct 14, 2016 2:10 pm    Post subject: Reply with quote  Mark this post and the followings unread

I commented out AG=no after adding the targeting and it works fine...  although I did have to tweak some stuff so it wouldn't chase aircraft Smile

_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [8 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.1584s ][ Queries: 14 (0.0100s) ][ Debug on ]