Page 1 of 1

Fighters vs. Nukes

Posted: Tue Nov 29, 2011 8:05 pm
by microchip08
The age-old question of lore has been answered!

Code: Select all

 static int s_attackOdds[ WorldObject::NumObjectTypes ] [ WorldObject::NumObjectTypes ] =

                                                /* ATTACKER */

                                    /* INV CTY SIL RDR NUK EXP SUB SHP AIR FTR BMR CRR TOR SAU*/

                                    {   
                                        0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  // Invalid
                                        0,  0,  0,  0, 99,  0,  0,  0,  0,  0,  0,  0,  0,  0,  // City
                                        0,  0,  0,  0, 99,  0,  0,  0,  0,  0,  0,  0,  0, 50,  // Silo
                                        0,  0,  0,  0, 99,  0,  0,  0,  0,  0,  0,  0,  0, 50,  // Radar
                                        0,  0, 25,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  // Nuke            DEFENDER
                                        0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  // Explosion
                                        0,  0,  0,  0, 99,  0, id, 30,  0,  3, 25, 30,  0, 50,  // Sub
                                        0,  0,  0,  0, 99,  0, 20, id,  0, 10, 25,  0,  0, 50,  // BattleShip
                                        0,  0,  0,  0, 99,  0,  0,  0,  0,  0,  0,  0,  0, 50,  // Airbase
                                        0,  0, 10,  0,  0,  0,  0, 30,  0, id,  0,  0,  0, 50,  // Fighter
                                        0,  0, 10,  0,  0,  0,  0, 20,  0, 30,  0,  0,  0, 50,  // Bomber
                                        0,  0,  0,  0, 99,  0, 20, 20,  0, 10, 25,  0,  0, 50,  // Carrier
                                        0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  // Tornado
                                        0,  0, 10,  0,  0,  0,  0, 10,  0, 10,  0,  0,  0,  0,  // Saucer
                                    };


    return s_attackOdds[ defenderType ][ attackerType ];

 // id = 10

Posted: Tue Nov 29, 2011 8:20 pm
by tllotpfkamvpe
.

Posted: Wed Nov 30, 2011 2:02 pm
by Why?
I think 'saucer' is the part of the explosion that can kill fighters, bombers, etc. The center point(Nuke) has the highest damage(99), and then the outer ring(saucer) has half the damage(50)... and cant hurt anything but other nukes and cities.

I don't understand what role the tornado plays, tho.... Tornados in defcon?

Posted: Wed Nov 30, 2011 2:08 pm
by Why?
Since 'explosions' and 'tornados' do no damage on this table, maybe they are just visual effects that are already tied in with other damages. i.e. Nuke and saucer could be the bounds of damage for a nuke, and explosion could be the animation.

Still not sure about 'tornado', tho.... maybe it's the animation that causes AA fire, and fighters, to spiral like a tornado?

Posted: Wed Nov 30, 2011 4:31 pm
by xander
Why? wrote:Since 'explosions' and 'tornados' do no damage on this table, maybe they are just visual effects that are already tied in with other damages. i.e. Nuke and saucer could be the bounds of damage for a nuke, and explosion could be the animation.

Still not sure about 'tornado', tho.... maybe it's the animation that causes AA fire, and fighters, to spiral like a tornado?

Or they are things that were never fully implemented in the final version of the game.

xander

Posted: Wed Nov 30, 2011 7:11 pm
by trickser
I doubt the relevance of the table. I know for sure nukes will kill bombers, while the table says otherwise.

Posted: Wed Nov 30, 2011 8:29 pm
by microchip08
trickser wrote:I doubt the relevance of the table. I know for sure nukes will kill bombers, while the table says otherwise.


I assume that the nuke detonations are covered elsewhere, and this merely deals with the nukes whilst they are in transit (but I haven't checked).

Why? wrote:'tornado'


There's an unused tornado texture in the game. According to IRC yesterday, it's simple to reimplement (apart from the small matter of crashing the client). There's also unused code regarding alien attacks on cities ("ALIEN ATTACK ON LONDON, 12.2M DEAD"). Obviously, these are both features that were abandoned in alpha.[size=0] <snuggles xander>[/size]

Posted: Wed Nov 30, 2011 8:43 pm
by tllotpfkamvpe
.

Posted: Wed Nov 30, 2011 9:27 pm
by tllotpfkamvpe
.

Posted: Thu Dec 01, 2011 1:12 pm
by Zorotama
tllotpfkamvpe wrote:Besides, fighters can kill nukes. They kill bombers which carry nukes therefore they kill nukes. Since all nukes are the same, from silos or subs or bombers, fighters can kill all nukes.

QED mvpe 8)


:P

Posted: Thu Dec 01, 2011 7:04 pm
by xander
I have been trying to convince my department that the correct abbreviation is "QEDB," for "quod erat demonstratum, bitches." It isn't really catching on, though I think that "Therefore P is a projective R-module. QEDB" has a nice ring to it.

xander

Posted: Wed Dec 14, 2011 6:20 pm
by Weps
The table shows only the hitpercentage per shot, however, the table is incomplete.

There is at least one unit that must be hit -at least- twice before it is destroyed. I thought it was a bb, am too lazy to look it up right now.

Posted: Wed Dec 14, 2011 9:47 pm
by xander
Weps wrote:The table shows only the hitpercentage per shot, however, the table is incomplete.

There is at least one unit that must be hit -at least- twice before it is destroyed. I thought it was a bb, am too lazy to look it up right now.

Airbases have to be hit twice. Silos must be hit three times.

xander

Posted: Thu Dec 15, 2011 4:32 pm
by Weps
Ah noes,

the table shows the value for a submerged sub.

For a surfaced sub, the value should be doubled. (So not hit twice as I assumed I remembered)

Code: Select all

        if( targetObject->m_type == WorldObject::TypeSub &&
            targetObject->m_currentState == 2 )
        {
            m_attackOdds *= 2;
        }



And also, carrier vrs (submerged) sub, the table says 30, but it's actually depending on the distance between the carrier and the sub:

Code: Select all

                if( rangeSqd <= 5 * 5 )
                {
                    if( wobj->m_currentState == 2 )
                    {
                        m_attackOdds = 0;
                    }
                    Fixed factor = 2 - rangeSqd/(5 * 5);
                    int odds = (m_attackOdds * factor).IntValue();
                    if( odds > syncrand() % 100 )
                    {
                        wobj->m_life = 0; 
                  wobj->m_lastHitByTeamId = m_teamId;
                    }
                }



This information is not in that table, hence it is incomplete.