Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
3 weapons for tanks and buildings
#1
Until PD releases an patch wich would allow units to have Tertiary= weapons, you can use a tweak using the Gattling logic to give to a tank or a building ( but not to a Infantry unit ) 3 different weapons ( at least one of them MUST be anti-air ).
For example, you can give the Apocalypse Tank an anti-infantry machine-gun, keep the AA missiles for air attacks and let the tank use it's cannons only against buildings or vehicles.
First, change the Primary= weapon to the one you want it to be "Secondary" ( NOT the one used when force-fire into the ground ); in this case, it's the machine-gun.
Code:
Primary=Para 
Secondary=MammothTusk        ; this remains the same
ElitePrimary=ParaE
EliteSecondary=MammothTusk
Then copy & edit the gattling tags:
Code:
IsGattling=yes
TurretCount=1
WeaponCount=6
Weapon1=Para
EliteWeapon1=ParaE
Weapon2=MammothTusk
EliteWeapon2=MammothTusk
Weapon3=120mmx                       ;in this case, weapon3 will be the "primary" weapon - the one used when you force-fire
EliteWeapon3=120mmxE
Weapon4=MammothTusk
EliteWeapon4=MammothTusk
Weapon5=120mmx
EliteWeapon5=120mmxE
Weapon6=MammothTusk
EliteWeapon6=MammothTusk
WeaponStages=3
Stage1=1
Stage2=9999999   ;; never get to Stage3
Stage3=1
EliteStage1=1
EliteStage2=9999999
EliteStage3=1
RateUp=1
RateDown=1

Then find [ApocAP] and [ApocAPE] ( the warheads for [120mmx] and [120mmxE] ) and change the first 3 values from Verses to 0%:
Code:
Verses=0%,0%,0%,95%,80%,70%,100%,70%,50%,100%,100%
The last step is to change the PrimaryFireFLH= and SecondaryFireFLH= in ArtMD like in Gattling tank's entry - Weapon1FLH=, Weapon2FLH= ,Weapon3FLH= and Weapon4FLH ( and their elite stages ) - weapon 5 & 6 will not be used.

When the Appocalypse will attack an infantry unit, it will use Para ( as the first AG weapon ) but when it gets to stage 2, as the warhead has 0% damage for infantry, it will keep attacking using Weapon1.
Against an vehicle or building, it will fire a single Machine-Gun burst, then will quickly switch to the 120mmX weapon. Sometimes, it will not even use the machinegun, but attack directly with the cannons.

There's a huge value for Stage2 weapon and EliteStage2 - this means that it's unlikely to ever get to that stage ( it would require a few hours ? days ? to continously fire... ).
Here's a screenshot of 3 apocs, each attacking a different target:
[Image: apocs.jpg]
"Bugs"
In this example, the Primary is Para ( deployed GI's machine-gun ); but since this weapon's warhead doesn't have Wall=yes, it means it cannot destroy walls... you won't even get an attack cursor over the walls; but cloning both [Para] and Para's warhead - [SSA], and adding Wall=yes ( and Wood=yes ) to the cloned warhead will solve this.
Another problem is related to Report= ( the sounds created when firing ) - it sometimes gets strange effects.
A quick "fix" is to remove all Report= from weapons and call the sounds from Artmd.ini with Report= tag to Anim= animations - this also may require a clone of the animations.
I never tested, but I'm pretty shure that 4-,5-or even 6-weapon tanks or buildings are possibile; just give them the right warheads - like:
Weapon1 warhead efficient VS infantry, tanks, buildings
Weapon3 warhead efficient VS tanks, buildings, but 0% for first 3 armors ( infantry )
Weapon5 warhead efficient VS buildings only, 0% verses for infantry and tanks
The unit uses Weapon 1 to attack anything. If it's an infantry, it will keep firing. If it's a tank or building, it will switch to Weapon2 and then either keep firing Weapon2 ( anti-tank ) or, if the target is a building, it will finally switch to Weapon3. Of course, in this case, Stage2 and EliteStage2 will have to be 1 in order to get to Stage3.
AA weapons can be similar ( Weapon2 = Weapon4 = Weapon6 ), or you can give the unit different weapons for V3 Rockets, Paratroopers and Aircrafts& jumpjet vehicles.
Reply
#2
This is an amazing discovery/hack/tutorial.

Would you be willing to add it to ModEnc, or allow us to do that?
Forum Rules

(01.06.2011, 05:43:25)kenosis Wrote: Oh damn don't be disgraced again!

(25.06.2011, 20:42:59)Nighthawk Wrote: The proverbial bearded omni-bug may be dead, but the containment campaign is still being waged in the desert.
Reply
#3
I "discovered" it, but now it's public, it's for all. Of course you can add it to ModEnc or where you wish, so any modder can use this Smile

Edit: "... to ModEnc AND where ...."
Reply
#4
Indeed this is a fantastic discovery, i congratulate you.
[Image: sig.jpg]
Reply
#5
WOOTage for you! Tongue
Reply
#6
Wow! Nice find!
[Image: alexstand1.gif]
Reply
#7
This is true modding; no "easy-way-out" exe hacking stuff required. Funnily enough, I did something like this not too long ago,when messing around trying to edit the Gattling Tank. I was messing with VirtualScanner and all sorts of weird stuff... and for some reason I just didn't think much of it and abandoned it.

+1 rep, BaRaKa_, for *not* abandoning Tongue
Reply
#8
Excellent work.
Reply
#9
New discovery: this seems to be incompatible with RP 1.08 ! A 3-weapon APOC wich works perfectly in YR normal & RP1.07, in RP 1.08 sometimes gives IEs when elite and firing VS infantry... not allways, just...
Reply
#10
interesting...
test again and upload here EXCEPT.TXT Wink
ARM forever - x86 sucks!


Reply
#11
Ok, I'm trying to attach the EXCEPT.TXT...


Attached Files
.txt   except.txt (Size: 25.38 KB / Downloads: 410)
Reply
#12
Error in PD's Bounty code Unhappy
ECX = 00000000h Unhappy
I am not detecting why yet.
Tomorrow I will put more infoSmile
ARM forever - x86 sucks!


Reply




Users browsing this thread: 1 Guest(s)