Posted: Mon Jan 21, 2019 9:02 pm Post subject:
Question about AnimList= on warheads..
Subject description: A bit of clarification needed please.
Basically I wanted some feedback on how the game can cycle through multiple animations when listed on a warhead. Reason I need clarification is because I have a split weapon in use with a unit, and I'm trying to have 3 different animation play randomly when the first stage expires.
Original example:
AnimList=TWLT026,TWLT036,TWLT050,TWLT070,TWLT100
I'm wondering what factors come into play to tell the game which animation to use?. Is it numerical order on the tags, damage based on the weapon ect?
It takes the weapon with the lowest damage that uses this warhead for the first anim.
The weapon with the highest damage using this warhead for the last anim.
All other weapons using this warhead get their damage sorted into the range of the lowest to highest and based upon this get one of the anims assigned.
e.g.
lowest damaging weapon using this warhead has Damage=10
highest damaging weapon using this warhead has Damage=210
gives a Damage range of 200 for this warhead
divided by 5 anims, each anim is assigned to weapons within the range of a multiple of 40 damage.
Anim1=10 - 50
Anim2=50 - 90
Anim3=90 - 130
Anim4=130 - 170
Anim5=170 - 210
if a third weapon has Damage=70, it would fall into the damage range of the second anim.
Thus, anims are assigned based on weapon damage.
Nothing random here, unfortunately. _________________ SHP Artist of Twisted Insurrection: Nod buildings
Which anim is played depends on the Damage value. Slots are fixed of 25 damage. 1st anim in the AnimList is played when damage is 1 to 24, 2nd in list on damage 25 to 49, 3rd when 50 to 74 and so on. When the damage exceeds, then last in the list is played. For example, when Damage=230, the 10th anim in the list is played. If there are only 5 anims defined, then the last anim that is the 5th anim will be played on damage 230. Versus percentage does not affect it. EMEffect=yes makes it random anim. For water, water anims are used.
Could also see ModEnc, though current content is tuned for RA2. ModEnc is again having that session timing issues currently, some browsers allow bypassing that problem. QUICK_EDIT
EMeffect=yes works perfectly, Thank you all! And is really great info about the damage characteristics on the anim slot. As always, I really appreciate the help! QUICK_EDIT
EMEffect makes it impossible to use Damage directly.
You would have to use a Splits=yes projectile with a second stage weapon to deliver the damage.
@E1 are you sure that fixed 25 damage step logic is the same in TS?
IIRC during my tests to get TIberium debris work, i noticed that adding a single anim to the end, changed the anims for several weapons that used this warhead already.
In contrary to Modenc, the AnimList is also not unlimited, but limited to 127 characters on the key (why the anims in TI used on the TIBHE warhead use only very short names, otherwise the 20 anims can exceed already the char limit). _________________ SHP Artist of Twisted Insurrection: Nod buildings
@E1 are you sure that fixed 25 damage step logic is the same in TS?
IIRC during my tests to get TIberium debris work, i noticed that adding a single anim to the end, changed the anims for several weapons that used this warhead already.
Sure on the 25 damage slot for TS as well. By increasing the anims in the list, some higher damage cases which would have been using the last anim as the damage would have exceeded the slots, would now have their own slot. Like in the example I gave earlier, Damage=230 should play the 10th anim, but because the list contains only 5, so it would have been playing the 5th anim until the list got more. QUICK_EDIT
@LKO No damaged needed on the first stage of my split weapon. I'm emulating a "aircraft carrier" logic in TS... Basically my "Jet" projectile explodes with 1 of the 8 different animation playing and the 2nd stage delivers a salvo of somewhat accurate missles for the damage. Excusing the horrid imbalance of an immune/unstoppable projectile is actually looks and plays perfectly...credit to you for inspiring me with your TI weapon logic topic. QUICK_EDIT
According to your description it sounds like you found a way to let the projectile fire the missile not from directly above the target (like a bomb in my solution) but actually from a point before it's directly above.
I use Airburst=yes so it flies above the target, explode, to then split there into the next stage, while using the warhead when splitting to show the bomb anim (art.ini debris). _________________ SHP Artist of Twisted Insurrection: Nod buildings
@LKO I used a similar method for the most part. I did implement the ProjectileRange= tag on the weapon to ensure detonation of stage 1 before the target, then allow the 2nd stage with the missile to do the damage.It looks like i will need to refine and add 8 total directions for the aircraft to make it a bit more smooth.
I don't think you need it, but you are welcome to my code if need be.
** only problem I have is if the 1st or 2nd fighter destroys the target, the last projectiles remaining explode immediately. I know this is a topic of things to fix...hope it can happen soonish!
thanks again!
AIRCRAFT CARRIER.gif
Description:
Filesize:
1.05 MB
Viewed:
1754 Time(s)
Last edited by Slavack on Wed Jan 23, 2019 3:08 am; edited 1 time in total QUICK_EDIT
@LKO I used a similar method for the most part. I did implement the ProjectileRange= tag on the weapon to ensure detonation of stage 1 before the target, then allow the 2nd stage with the missile to do the damage.It looks like i will need to refine and add 8 total directions for the aircraft to make it a bit more smooth.
I see a problem with this. What if the target is closer than your set ProjectileRange?
In this case your 1st stage plane would do a suicide attack or explode right above the target. It wouldn't look like the missiles are fired before reaching the target.
Unless you also set MinimumRange to be the same as ProjectileRange, i doubt it would look good in most cases.
MinimumRange wouldn't work well either, since this is a long range weapon and it would look stupid if the ship has to move away.
Using ProjectileRange you pretty much restricted the weapon to look good for a very narrow attackrange only.
Slavack wrote:
I don't think you need it, but you are welcome to my code if need be.
nah, that's not necessary.
btw, if you don't use a VXL for the 1st stage, you can get rid of the ugly tilted launch and also use the special SHP start flight behaviour for slow projectiles.
Projectiles with Speed less than 16 fly straight and parallel to ground before they start climbing and homing in on the target.
DTA is using this to give the carrier drones something like a runway start.
What i really like about your solution is that your unit can still gain veterancy. The missiles are still a rules.ini weapon, unlike my way of using art.ini debris for the bombs. _________________ SHP Artist of Twisted Insurrection: Nod buildings
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