sc: bw unit dimensions from bwapi
[sheet.git] / sc-units-bw.inc.pl
index b79ce6574b2cb4afdc4ef548bc133d57a07aa630..75908837fc6f6ca42cc256de33e801c6e8029c1f 100644 (file)
@@ -1,10 +1,12 @@
 use utf8;
 use strict;
 
-# time in fastest game seconds
-my $FPS = 24;  # frames per second
-# toss shield += .65 per second
-# zerg regen  += .37 per second
+my $PPT = 32;  # tile size in pixels
+my $FPS = 1000 / 56;  # frames per second on fast
+# energy      += 8HP/frame ≈ .74 per second
+# toss shield += 7HP/frame ≈ .65/s
+# zerg regen  += 4HP/frame ≈ .37/s
+my $SM = $FPS / $PPT;  # pixels per frame to tiles per second multiplication
 
 [
 '<span title="no known changes as of v1.16.1">version≥1.08</span>',
@@ -19,6 +21,7 @@ min => 50,
 gas => 0,
 build => 20,
 suit => 1,
+size => 23 / $PPT,
 pop => 1,
 cargo => 1,
 race => 'protoss',
@@ -34,11 +37,11 @@ attack => [
                name => "Particle Beam",
                damage => 5,
                cooldown => 22 / $FPS,
-               range => 0,
+               range => 1,
        },
 ],
 sight => 8,
-speed => 14,
+speed => 4.92 * $SM,
 counter => ['vulture', 'dark templar'],
 },
 
@@ -53,6 +56,7 @@ min => 150,
 gas => 0,
 build => 50,
 suit => 3,
+size => 2, # 41x33
 race => 'protoss',
 attr => {
        structure => 1,
@@ -85,6 +89,7 @@ min => 100,
 gas => 0,
 build => 40,
 suit => 1,
+size => 23 / $PPT, # x19
 pop => 2,
 cargo => 2,
 race => 'protoss',
@@ -105,11 +110,11 @@ attack => [
        },
 ],
 sight => 7,
-speed => 11,
+speed => 4 * $SM,
 upgrade => [
        {
                name => 'Leg Enhancements',
-               speed => 16 - 11,
+               speed => (6 - 4) * $SM,
                min => 150,
                gas => 150,
                build => 133,
@@ -129,6 +134,7 @@ min => 125,
 gas => 50,
 build => 50,
 suit => 3,
+size => 32 / $PPT,
 pop => 2,
 cargo => 4,
 race => 'protoss',
@@ -150,7 +156,7 @@ attack => [
        },
 ],
 sight => 8,
-speed => 15,
+speed => 5 * $SM,
 upgrade => [
        {
                name => 'Singularity Charge',
@@ -178,6 +184,7 @@ min => 50,
 gas => 150,
 build => 50,
 suit => 1,
+size => 24 / $PPT,
 pop => 2,
 cargo => 2,
 race => 'protoss',
@@ -188,7 +195,7 @@ hp => 40,
 shield => 40,
 armor => 0,
 sight => 7,
-speed => 9,
+speed => 3.2 * $SM,
 energy => 50,
 capacity => 200,
 upgrade => [
@@ -238,6 +245,7 @@ min => 125,
 gas => 100,
 build => 50,
 suit => 1,
+size => 25 / $PPT, # 24x26
 pop => 2,
 cargo => 2,
 race => 'protoss',
@@ -258,7 +266,7 @@ attack => [
        },
 ],
 sight => 7,
-speed => 15,
+speed => 4.92 * $SM,
 special => [
        {
                name => 'Cloaked',
@@ -281,6 +289,7 @@ gas => 300,
 build => 20,
 base => ['templar', 'templar'],
 suit => 3,
+size => 32 / $PPT,
 pop => 4,
 cargo => 4,
 race => 'protoss',
@@ -302,7 +311,7 @@ attack => [
        },
 ],
 sight => 8,
-speed => 14,
+speed => 4.92 * $SM,
 },
 
 {
@@ -317,6 +326,7 @@ gas => 200,
 build => 20,
 base => ['dark templar', 'dark templar'],
 suit => 3,
+size => 32 / $PPT,
 pop => 4,
 cargo => 4,
 race => 'protoss',
@@ -327,7 +337,7 @@ hp => 25,
 shield => 200,
 armor => 1,
 sight => 10,
-speed => 14,
+speed => 4.92 * $SM,
 energy => 50,
 capacity => 200,
 upgrade => [
@@ -384,6 +394,7 @@ min => 275,
 gas => 125,
 build => 80,
 suit => 3,
+size => 36 / $PPT, # x32
 pop => 3,
 race => 'protoss',
 attr => {
@@ -412,7 +423,7 @@ attack => [
        },
 ],
 sight => 8,
-speed => 13,
+speed => 5 * $SM,
 upgrade => [
        {
                name => 'Apial Sensors',
@@ -426,7 +437,7 @@ upgrade => [
                min => 200,
                gas => 200,
                build => 166,
-               speed => 18 - 13,
+               speed => (6.67 - 5) * $SM,
        },
 ],
 },
@@ -441,6 +452,7 @@ min => 150,
 gas => 100,
 build => 40,
 suit => 2,
+size => 36 / $PPT, # x32
 pop => 2,
 race => 'protoss',
 attr => {
@@ -463,7 +475,7 @@ attack => [
        },
 ],
 sight => 9,
-speed => 17,
+speed => 6.67 * $SM,
 energy => 50,
 capacity => 200,
 upgrade => [
@@ -478,15 +490,15 @@ upgrade => [
 ],
 special => [
        {
-               name => 'Disruption web',
+               name => 'Disruption Web',
                abbr => 'dw',
                min => 200,
                gas => 200,
                build => 80,
                desc => 'creates a field in which no ground unit/structure can attack',
                range => 9,
-               cost => 62-50,
-               duration => undef, #XXX
+               cost => 125,
+               duration => 24,
        },
 ],
 counter => ['devourer', 'valkyrie'],
@@ -502,6 +514,7 @@ min => 350,
 gas => 250,
 build => 140,
 suit => 3,
+size => 64 / $PPT,
 pop => 6,
 race => 'protoss',
 attr => {
@@ -520,7 +533,7 @@ attack => [
        },
 ],
 sight => 11,
-speed => 10,
+speed => 3.33 * $SM,
 special => [
        {
                name => 'Build Interceptor',
@@ -528,6 +541,7 @@ special => [
                min => 25,
                build => 20,
                suit => 1,
+               size => 16 / $PPT,
                pop => 0,
                race => 'protoss',
                attr => {
@@ -547,8 +561,9 @@ special => [
                                range => 0,
                        },
                ],
-               sight => 0,
+               sight => 6,
                range => 0,
+               speed => 13.33 * $SM,
        },
 ],
 upgrade => [
@@ -575,6 +590,7 @@ min => 100,
 gas => 350,
 build => 160,
 suit => 3,
+size => 44 / $PPT,
 pop => 4,
 race => 'protoss',
 attr => {
@@ -596,7 +612,7 @@ attack => [
        },
 ],
 sight => 9,
-speed => 12,
+speed => 5 * $SM,
 energy => 50,
 capacity => 200,
 upgrade => [
@@ -647,6 +663,7 @@ min => 200,
 gas => 100,
 build => 70,
 suit => 3,
+size => 32 / $PPT,
 pop => 4,
 cargo => 4,
 race => 'protoss',
@@ -660,7 +677,7 @@ attack => [
        {
                anti => 1,
                damage => 100,
-               cooldown => 60 / $FPS,
+               cooldown => 60 / $FPS, # 30 after drop
                splash => 1,
                min => 15,
                build => 7,
@@ -669,7 +686,7 @@ attack => [
        },
 ],
 sight => 10,
-speed => 5,
+speed => 1.78 * $SM,
 upgrade => [
        {
                name => 'Scarab Damage',
@@ -713,6 +730,7 @@ min => 25,
 gas => 75,
 build => 40,
 suit => 1,
+size => 32 / $PPT,
 pop => 1,
 race => 'protoss',
 attr => {
@@ -725,7 +743,7 @@ shield => 20,
 armor => 0,
 sight => 9,
 detect => 1,
-speed => 9,
+speed => 3.33 * $SM,
 upgrade => [
        {
                name => "Sensor Array",
@@ -739,7 +757,7 @@ upgrade => [
                min => 150,
                gas => 150,
                build => 166,
-               speed => 13 - 9,
+               speed => (5 - 3.33) * $SM,
        },
 ],
 special => [
@@ -762,6 +780,7 @@ min => 200,
 gas => 0,
 build => 60,
 suit => 3,
+size => 40 / $PPT, # x32
 pop => 2,
 cargo => -8,
 race => 'protoss',
@@ -772,7 +791,7 @@ hp => 80,
 shield => 60,
 armor => 1,
 sight => 8,
-speed => 13,
+speed => 4.43 * $SM,
 transport => 1,
 upgrade => [
        {
@@ -780,7 +799,7 @@ upgrade => [
                min => 200,
                gas => 200,
                build => 166,
-               speed => 19 - 13,
+               speed => (6.67 - 4.43) * $SM,
        }
 ],
 },
@@ -795,6 +814,7 @@ min => 50,
 gas => 0,
 build => 20,
 suit => 1,
+size => 23 / $PPT,
 pop => 1,
 cargo => 1,
 race => 'terran',
@@ -813,7 +833,7 @@ attack => [
        },
 ],
 sight => 7,
-speed => 15,
+speed => 4.92 * $SM,
 },
 
 {
@@ -826,6 +846,7 @@ min => 75,
 gas => 0,
 build => 30,
 suit => 3,
+size => 2, # 33x49
 race => 'terran',
 attr => {
        structure => 1,
@@ -856,6 +877,7 @@ min => 50,
 gas => 0,
 build => 24,
 suit => 1,
+size => 17 / $PPT, # x20
 pop => 1,
 cargo => 1,
 race => 'terran',
@@ -874,7 +896,7 @@ attack => [
        },
 ],
 sight => 7,
-speed => 11,
+speed => 4 * $SM,
 upgrade => [
        {
                name => 'U-238 Shells',
@@ -890,13 +912,13 @@ upgrade => [
 ],
 special => [
        {
-               name => 'stim pack',
+               name => 'Stim Pack',
                abbr => 'sp',
                min => 100,
                gas => 100,
                build => 80,
                desc => 'doubles attack speed and faster movement for a few seconds at the cost of 10 health',
-               speed => 17,
+               speed => (6 - 4) * $SM,
                attack => [
                        {
                                anti => 3,
@@ -915,6 +937,7 @@ min => 50,
 gas => 25,
 build => 24,
 suit => 1,
+size => 23 / $PPT, # x22
 pop => 1,
 cargo => 1,
 race => 'terran',
@@ -935,7 +958,7 @@ attack => [
        },
 ],
 sight => 7,
-speed => 11,
+speed => 4 * $SM,
 upgrade => [
 ],
 special => [
@@ -946,7 +969,7 @@ special => [
                gas => 100,
                build => 80,
                desc => 'doubles attack speed and faster movement for a few seconds at the cost of 10 health',
-               speed => 17,
+               speed => (6 - 4) * $SM,
                attack => [
                        {
                                anti => 1,
@@ -968,6 +991,7 @@ min => 25,
 gas => 75,
 build => 50,
 suit => 1,
+size => 15 / $PPT, # x22
 pop => 1,
 cargo => 1,
 race => 'terran',
@@ -987,7 +1011,7 @@ attack => [
        },
 ],
 sight => 9,
-speed => 11,
+speed => 4 * $SM,
 energy => 50,
 capacity => 200,
 upgrade => [
@@ -1055,6 +1079,7 @@ min => 50,
 gas => 25,
 build => 30,
 suit => 1,
+size => 17 / $PPT, # x20
 pop => 1,
 cargo => 1,
 race => 'terran',
@@ -1064,7 +1089,7 @@ attr => {
 hp =>  60,
 armor => 1,
 sight => 9,
-speed => 11,
+speed => 4 * $SM,
 energy => 50,
 capacity => 200,
 upgrade => [
@@ -1121,6 +1146,7 @@ min => 75,
 gas => 0,
 build => 30,
 suit => 2,
+size => 32 / $PPT,
 pop => 2,
 cargo => 2,
 race => 'terran',
@@ -1140,14 +1166,14 @@ attack => [
        },
 ],
 sight => 8,
-speed => 20,
+speed => 6.4 * $SM,
 upgrade => [
        {
                name => 'Ion Thrusters',
                min => 100,
                gas => 100,
                build => 100,
-               speed => 28 - 20,
+               speed => (10 - 6.4) * $SM,
        },
 ],
 special => [
@@ -1165,6 +1191,7 @@ special => [
                },
                hp => 20,
                suit => 1,
+               size => 15 / $PPT,
                armor => 0,
                attack => [
                        {
@@ -1176,7 +1203,7 @@ special => [
                        },
                ],
                sight => 3,
-               speed => 25,
+               speed => 16 * $SM,
     },
 ],
 },
@@ -1191,6 +1218,7 @@ min => 150,
 gas => 100,
 build => 50,
 suit => 3,
+size => 32 / $PPT,
 pop => 2,
 cargo => 4,
 race => 'terran',
@@ -1204,13 +1232,13 @@ attack => [
                anti => 1,
                damage => 30,
                upgrade => 3,
-               cooldown => 37 / $FPS,
+               cooldown => 37 / $FPS, # 15 after drop
                type => 'explosive',
                range => 7,
        },
 ],
 sight => 10,
-speed => 12,
+speed => 4 * $SM,
 special => [
        {
                name => 'Siege Mode',
@@ -1245,6 +1273,7 @@ min => 100,
 gas => 50,
 build => 40,
 suit => 3,
+size => 32 / $PPT,
 pop => 2,
 cargo => 2,
 race => 'terran',
@@ -1258,7 +1287,7 @@ attack => [
                anti => 1,
                damage => 12,
                upgrade => 1,
-               cooldown => 22 / $FPS,
+               cooldown => 22 / $FPS, # 15 after drop
                range => 5,
        },
        {
@@ -1271,7 +1300,7 @@ attack => [
        },
 ],
 sight => 8,
-speed => 13,
+speed => 4.57 * $SM,
 upgrade => [
        {
                name => 'Charon Boosters',
@@ -1295,6 +1324,7 @@ min => 150,
 gas => 100,
 build => 60,
 suit => 3,
+size => 38 / $PPT, # x30
 pop => 2,
 race => 'terran',
 attr => {
@@ -1322,7 +1352,7 @@ attack => [
        },
 ],
 sight => 7,
-speed => 17,
+speed => 6.67 * $SM,
 energy => 50,
 capacity => 200,
 special => [
@@ -1359,6 +1389,7 @@ min => 400,
 gas => 300,
 build => 133,
 suit => 3,
+size => 75 / $PPT, # x59
 pop => 6,
 race => 'terran',
 attr => {
@@ -1378,7 +1409,7 @@ attack => [
        },
 ],
 sight => 11,
-speed => 7,
+speed => 2.5 * $SM,
 energy => 50,
 capacity => 200,
 special => [
@@ -1421,6 +1452,7 @@ min => 100,
 gas => 225,
 build => 80,
 suit => 3,
+size => 65 / $PPT, # x50
 pop => 2,
 race => 'terran',
 attr => {
@@ -1432,7 +1464,7 @@ hp => 200,
 armor => 1,
 sight => 10,
 detect => 1,
-speed => 15,
+speed => 5 * $SM,
 energy => 50,
 capacity => 200,
 special => [
@@ -1492,6 +1524,7 @@ min => 250,
 gas => 125,
 build => 50,
 suit => 3,
+size => 49 / $PPT, # x37
 pop => 3,
 race => 'terran',
 attr => {
@@ -1514,7 +1547,7 @@ attack => [
        },
 ],
 sight => 8,
-speed => 19,
+speed => 6.6 * $SM,
 },
 
 {
@@ -1524,6 +1557,7 @@ min => 100,
 gas => 100,
 build => 50,
 suit => 3,
+size => 49 / $PPT, # x37
 pop => 2,
 cargo => -8,
 race => 'terran',
@@ -1535,7 +1569,7 @@ air => 1,
 hp => 150,
 armor => 1,
 sight => 8,
-speed => 15,
+speed => 5.47 * $SM,
 transport => 1,
 },
 
@@ -1549,6 +1583,7 @@ min => 50,
 gas => 0,
 build => 20,
 suit => 1,
+size => 23 / $PPT,
 pop => 1,
 cargo => 1,
 race => 'zerg',
@@ -1562,11 +1597,11 @@ attack => [
                anti => 1,
                damage => 5,
                cooldown => 22 / $FPS,
-               range => 0,
+               range => 1,
        },
 ],
 sight => 7,
-speed => 14,
+speed => 4.92 * $SM,
 },
 
 {
@@ -1576,6 +1611,7 @@ min => 100,
 gas => 0,
 build => 40,
 suit => 3,
+size => 50 / $PPT,
 pop => -9,
 cargo => 0,
 race => 'zerg',
@@ -1589,7 +1625,7 @@ armor => 0,
 cargo => 0,
 sight => 9,
 detect => 1,
-speed => 2,
+speed => .83 * $SM,
 transport => 1,
 upgrade => [
        {
@@ -1611,7 +1647,7 @@ upgrade => [
                min => 150,
                gas => 150,
                build => 133,
-               speed => 10 - 2,
+               speed => (3.33 - .83) * $SM,
        },
 ],
 },
@@ -1624,6 +1660,7 @@ trans => {
 },
 build => 20,
 suit => 1,
+size => 16 / $PPT,
 pop => 0,
 race => 'zerg',
 attr => {
@@ -1658,6 +1695,7 @@ min => 175,
 gas => 0,
 build => 20,
 suit => 3,
+size => 2, # 48x48
 race => 'zerg',
 attr => {
        structure => 1,
@@ -1684,6 +1722,7 @@ min => 175,
 gas => 0,
 build => 20,
 suit => 3,
+size => 2, # 48x48
 race => 'zerg',
 attr => {
        structure => 1,
@@ -1710,6 +1749,7 @@ min => 25,
 gas => 0,
 build => 28, # for 2
 suit => 1,
+size => 16 / $PPT,
 pop => 0.5,
 cargo => 1,
 race => 'zerg',
@@ -1728,14 +1768,14 @@ attack => [
        },
 ],
 sight => 5,
-speed => 14,
+speed => 5.49 * $SM,
 upgrade => [
        {
                name => 'Metabolic Boost',
                min => 100,
                gas => 100,
                build => 80,
-               speed => 22 - 14,
+               speed => (8.36 - 5.49) * $SM,
        },
        {
                name => 'Adrenal Glands',
@@ -1744,7 +1784,7 @@ upgrade => [
                build => 80,
                attack => [
                        {
-                               cooldown => 6 / $FPS,
+                               cooldown => (6 - 8) / $FPS,
                        },
                ],
        },
@@ -1759,6 +1799,7 @@ min => 75,
 gas => 25,
 build => 28,
 suit => 2,
+size => 21 / $PPT, # x23
 pop => 1,
 cargo => 2,
 race => 'zerg',
@@ -1778,7 +1819,7 @@ attack => [
        },
 ],
 sight => 6,
-speed => 11,
+speed => 3.66 * $SM,
 upgrade => [
        {
                name => 'Grooved Spines',
@@ -1796,7 +1837,7 @@ upgrade => [
                min => 150,
                gas => 150,
                build => 100,
-               speed => 16 - 11,
+               speed => (5.57 - 3.66) * $SM,
        },
        {
                name => 'Lurker Aspect',
@@ -1815,6 +1856,7 @@ gas => 125,
 base => 'hydralisk',
 build => 40,
 suit => 2,
+size => 32 / $PPT,
 pop => 2,
 cargo => 4,
 race => 'zerg',
@@ -1834,7 +1876,7 @@ attack => [
        },
 ],
 sight => 8,
-speed => 17,
+speed => 5.82 * $SM,
 },
 
 {
@@ -1844,6 +1886,7 @@ min => 100,
 gas => 100,
 build => 50,
 suit => 2,
+size => 48 / $PPT,
 pop => 2,
 race => 'zerg',
 attr => {
@@ -1854,7 +1897,7 @@ air => 1,
 hp => 120,
 armor => 0,
 sight => 10,
-speed => 18,
+speed => 6.67 * $SM,
 energy => 50,
 capacity => 200,
 special => [
@@ -1895,6 +1938,7 @@ special => [
                count => 2,
                alt => 'Broodling',
                suit => 1,
+               size => 19 / $PPT,
                pop => 0,
                attr => {
                        organic => 1,
@@ -1911,7 +1955,7 @@ special => [
                        },
                ],
                sight => 5,
-               speed => 19,
+               speed => 6 * $SM,
        },
 ],
 },
@@ -1923,6 +1967,7 @@ min => 100,
 gas => 50,
 build => 40,
 suit => 1,
+size => 17 / $PPT, # x20
 pop => 1,
 race => 'zerg',
 attr => {
@@ -1940,7 +1985,7 @@ attack => [
        },
 ],
 sight => 5,
-speed => 17,
+speed => 5.82 * $SM,
 },
 
 {
@@ -1950,6 +1995,7 @@ min => 12,
 gas => 38,
 build => 30, # for 2
 suit => 1,
+size => 24 / $PPT,
 pop => 0.5,
 race => 'zerg',
 attr => {
@@ -1967,7 +2013,7 @@ attack => [
        },
 ],
 sight => 5,
-speed => 18,
+speed => 6.67 * $SM,
 counter => ['cannon', 'goliath', 'hydralisk'],
 },
 
@@ -1978,6 +2024,7 @@ min => 100,
 gas => 100,
 build => 40,
 suit => 1,
+size => 44 / $PPT,
 pop => 2,
 race => 'zerg',
 attr => {
@@ -1998,11 +2045,12 @@ attack => [
        },
 ],
 sight => 7,
-speed => 18,
+speed => 6.67 * $SM,
 special => [
        {
                alt => 'Cocoon',
                suit => 3,
+               size => 32 / $PPT,
                attr => {
                        organic => 1,
                        flying => 1,
@@ -2025,6 +2073,7 @@ gas => 200,
 build => 40,
 base => 'mutalisk',
 suit => 3,
+size => 44 / $PPT,
 pop => 2,
 race => 'zerg',
 attr => {
@@ -2044,7 +2093,7 @@ attack => [
        },
 ],
 sight => 11,
-speed => 7,
+speed => 2.5 * $SM,
 },
 
 {
@@ -2055,6 +2104,7 @@ gas => 150,
 build => 40,
 base => 'mutalisk',
 suit => 3,
+size => 44 / $PPT,
 pop => 2,
 race => 'zerg',
 attr => {
@@ -2075,7 +2125,7 @@ attack => [
        },
 ],
 sight => 10,
-speed => 15,
+speed => 5 * $SM,
 counter => ['goliath', 'dragoon', 'scourge'],
 },
 
@@ -2086,6 +2136,7 @@ min => 50,
 gas => 150,
 build => 50,
 suit => 2,
+size => 27 / $PPT, # x25
 pop => 2,
 cargo => 2,
 race => 'zerg',
@@ -2095,7 +2146,7 @@ attr => {
 hp => 80,
 armor => 1,
 sight => 10,
-speed => 12,
+speed => 4 * $SM,
 energy => 50,
 capacity => 200,
 special => [
@@ -2149,6 +2200,7 @@ min => 200,
 gas => 200,
 build => 60,
 suit => 3,
+size => 38 / $PPT, # x32
 pop => 4,
 cargo => 4,
 race => 'zerg',
@@ -2167,7 +2219,7 @@ attack => [
        },
 ],
 sight => 7,
-speed => 16,
+speed => 5.12 * $SM,
 upgrade => [
        {
                name => 'Chitinous Plating',
@@ -2181,7 +2233,7 @@ upgrade => [
                min => 200,
                gas => 200,
                build => 133,
-               speed => 21 - 16,
+               speed => (8.1 - 5.12) * $SM,
        },
 ],
 },