sc: update mode specials metadata
[sheet.git] / sc-units-lotv.inc.pl
1 use utf8;
2 use strict;
3
4 my $V = v5.0.2;
5 my $RT = 1.4;  # real-time speed factor to faster
6
7 my $hots = do 'sc-units-hots.inc.pl' or die $!;
8 my %unit;
9 for my $row (@{$hots}) {
10         ref $row eq 'HASH' or next;
11         for ($row, @{ $row->{special} }, @{ $row->{upgrade} }) {
12                 $_ *= $RT for $_->{speed} // ();
13                 $_ /= $RT for $_->{build} // (), $_->{transform} // (), $_->{warp} // (), $_->{cooldown} // ();
14                 $_->{cooldown} and $_->{cooldown} /= $RT for @{ $_->{attack} // [] };
15         }
16         $unit{ lc $row->{name} =~ tr/ /_/r } = $row;
17 }
18
19 [
20 sprintf('patch %vd', $V),
21
22 # protoss
23
24 $unit{probe},
25
26 $unit{photon_cannon},
27
28 {
29         %{ $unit{mothership} },
30         speed => 2.62,
31         special => [
32                 $unit{mothership}->{special}->[0], # cf
33                 $unit{mothership}->{special}->[1], # mr
34                 {
35                         %{ $unit{mothership}->{special}->[2] }, # tw
36                         desc => $V lt v4.11.0 ? 'create a temporal field which slows ground units by 50%'
37                                               : 'create a temporal field which slows ground and air units by 50%',
38                 },
39         ],
40 },
41
42 {
43         %{ $unit{nexus} },
44         attack => [],
45         energy => 50,
46         capacity => 200,
47         special => [
48                 $unit{nexus}->{special}->[0], # chrono boost
49                 {
50                         name => $V lt v4.7.1 ? 'Mass Recall' : 'Strategic Recall',
51                         abbr => 'sr',
52                         desc => 'recalls units owned by the player in the target area to the Nexus',
53                         cost => 50,
54                         cooldown => $V lt v4.7.1 || $V ge v4.10.1 ? 130 : 85,
55                         radius => $V lt v4.7.1 ? 6.5 : 2.5,
56                         duration => 3.6, # +.7 warp in
57                 },
58                 $V lt v4.12.0 ? () : {
59                         name => 'Battery Overcharge',
60                         abbr => 'bo',
61                         desc => 'increase target Shield Battery restoration rate by 100% and function without consuming energy for 14s',
62                         cost => 50,
63                         duration => 14,
64                         cooldown => 60, # shared by all nexuses
65                         range => 8, # within any friendly nexus
66                 },
67         ],
68 },
69
70 {
71         %{ $unit{zealot} },
72         special => [
73                 {
74                         name => 'Charge',
75                         abbr => 'ch',
76                         desc => 'on attack, increases movement speed to 8.47 for 2.5s and deals 8 damage on hit',
77                         min => 100, # changed in 3.14.0
78                         gas => 100,
79                         build => 100,
80                         speed => .5,
81                         range => 4,
82                         duration => 2.5,
83                         cooldown => 7,
84                 },
85         ],
86         upgrade => [
87                 {
88                         name => 'Charge',
89                         speed => $V lt v4.11.0 ? .98 : 1.57,
90                 },
91         ],
92 },
93
94 {
95         %{ $unit{sentry} },
96         special => [
97                 $unit{sentry}->{special}->[0], # ff
98                 {
99                         %{ $unit{sentry}->{special}->[1] }, # gs
100                         radius => $V lt v4.7.1 ? 4 : 4.5,
101                 },
102                 {
103                         %{ $unit{sentry}->{special}->[2] }, # hl
104                         cost => $V lt v4.7.1 ? 100 : 75,
105                 },
106         ],
107 },
108
109 {
110         %{ $unit{stalker} },
111         attack => [
112                 {
113                         %{ $unit{stalker}->{attack}->[0] }, # particle disruptors
114                         damage => 13,
115                         bonus => {
116                                 armored => 5,
117                                 -armored => 1,
118                         },
119                         cooldown => 1.34,
120                 },
121         ],
122 },
123
124 {
125         race => 'protoss',
126         cat => 'gateway',
127         name => 'Adept',
128         pop => 2,
129         min => 100,
130         gas => 25,
131         build => $V lt v4.8.2 ? 27 : 30,
132         warp => 20,
133         size => 1,
134         cargo => 2,
135         armor => 1,
136         hp => 70,
137         shield => 70,
138         attr => {
139                 light => 1,
140                 organic => 1,
141         },
142         attack => [
143                 {
144                         anti => 1,
145                         name => undef, #TODO
146                         damage => 10,
147                         upgrade => 1,
148                         bonus => {
149                                 light => 12,
150                                 -light => 1,
151                         },
152                         type => 'projectile', #XXX: assumption
153                         cooldown => 1.61,
154                         range => 4,
155                 },
156         ],
157         speed => 3.5,
158         sight => 9,
159         special => [
160                 {
161                         name => 'Psionic Transfer',
162                         abbr => 'pt',
163                         desc => 'project shade, teleport after 7s',
164                         cooldown => 11,
165
166                         alt => 'Shade',
167                         build => 0,
168                         size => 0,
169                         cargo => 0,
170                         hp => -1,
171                         attack => [], #TODO: indicate diff from parent
172                         speed => 5, #XXX: faster than 3.5
173                         range => 7, #XXX: calculate from speed
174                         sight => 4,
175                 },
176         ],
177         upgrade => [
178                 {
179                         name => 'Resonating Glaives',
180                         min => 100,
181                         gas => 100,
182                         build => 100,
183                         attack => [
184                                 {
185                                         cooldown => $V lt v4.11.0 || $V ge v4.11.3 ? -.5 : -.6, # +45%/60%
186                                 },
187                         ],
188                 },
189         ],
190 },
191
192 {
193         %{ $unit{high_templar} },
194         attack => [
195                 {
196                         anti => 1,
197                         name => '?', #XXX
198                         damage => 4,
199                         upgrade => 1,
200                         cooldown => 1.25,
201                         range => 6,
202                 },
203         ],
204         special => [
205                 {
206                         $unit{high_templar}->{special}->[0], # fb
207                         range => $V lt v4.12.0 ? 9 : 10,
208                 },
209                 $unit{high_templar}->{special}->[1], # ps
210         ],
211 },
212
213 {
214         %{ $unit{dark_templar} },
215         special => [
216                 $unit{dark_templar}->{special}->[0], # cl
217                 {
218                         name => 'Shadow Stride',
219                         abbr => 'bl',
220                         desc => 'teleport to visible location',
221                         min => 100,
222                         gas => 100,
223                         build => $V lt v4.7.1 ? 121 : 100,
224                         range => 8,
225                         cooldown => $V lt v4.7.1 ? 21 : 14,
226                 },
227         ],
228 },
229
230 $unit{archon},
231
232 {
233         %{ $unit{observer} },
234         speed => $V lt v4.8.2 || $V ge v4.11.0 ? 2.63 : 3.01,
235         special => [
236                 $unit{observer}->{special}->[0], # cloak
237                 {
238                         name => 'Surveillance Mode',
239                         abbr => 'sm',
240                         desc => 'gain 25% vision while immobilized',
241                         speed => 0,
242                         sight => 2.75, # +25%
243                         transform => .54,
244                 },
245         ],
246 },
247
248 {
249         %{ $unit{warp_prism} },
250         hp => 80,
251         min => $V lt v4.10.1 ? 200 : 250,
252         range => $V lt v4.10.1 ? 6 : 5, # pickup
253         upgrade => [
254                 {
255                         %{ $unit{warp_prism}->{special}->[0] }, # gravitic drive
256                         speed => 1.23,
257                 },
258         ],
259 },
260
261 $unit{immortal},
262
263 {
264         %{ $unit{colossus} },
265         attack => [
266                 {
267                         %{ $unit{colossus}->{attack}->[0] }, # thermal lances
268                         damage => 10,
269                         upgrade => 1,
270                         bonus => {
271                                 light => 5,
272                                 -light => 1,
273                         },
274 #                       cooldown => 1.18, #XXX
275                 },
276         ],
277 },
278
279 {
280         race => 'protoss',
281         cat => 'robotic',
282         name => 'Disruptor',
283         pop => 3,
284         min => 150,
285         gas => 150,
286         build => 36,
287         size => 1,
288         cargo => 4,
289         armor => 1,
290         hp => 100,
291         shield => 100,
292         attr => {
293                 armored => 1,
294                 mech => 1,
295         },
296         attack => [
297                 {
298                         anti => 1,
299                         name => 'Purification Nova',
300                         damage => 145,
301                         bonus => {
302                                 shields => 55,
303                         },
304                         type => 'trans', #TODO: indicate
305                         splash => 1.5,
306                         cooldown => 14.3,
307                         range => 13, # 2s
308                 },
309         ],
310         speed => 3.15,
311         sight => 9,
312 },
313
314 $unit{phoenix},
315
316 {
317         %{ $unit{void_ray} },
318         min => $V lt v5.0.2 ? 250 : 200,
319         speed => $V lt v5.0.2 ? 3.5 : 3.85,
320         build => $V lt v5.0.2 ? 43 : 37,
321         upgrade => [
322                 {
323                         name => 'Flux Vanes',
324                         min => 100,
325                         gas => 100,
326                         build => 57,
327                         speed => $V lt v5.0.2 ? 1.15 : .798,
328                 },
329         ],
330 },
331
332 {
333         %{ $unit{oracle} },
334         build => 37,
335         attr => {
336                 $V lt v4.8.2 ? 'light' : 'armored' => 1,
337                 mech => 1,
338                 psionic => 1,
339                 flying => 1,
340         },
341         attack => [
342                 {
343                         %{ $unit{oracle}->{attack}->[0] }, # pulsar beam
344                         bonus => {
345                                 light => 7,
346                         },
347                 },
348         ],
349         special => [
350                 {
351                         name => 'Revelation',
352                         abbr => 'rv',
353                         desc => 'hit enemy units and buildings are revealed for Â½ minute',
354                         cost => $V lt v4.12.0 ? 50 : 25,
355                         range => 9,
356                         cooldown => $V lt v4.12.0 ? 2 : 10,
357                         duration => $V lt v4.12.0 ? 30 : $V lt v5.0.2 ? 15 : 20,
358                         radius => 6,
359                 },
360                 {
361                         name => 'Stasis Ward',
362                         abbr => 'sw',
363                         desc => 'places ward for 170s',
364                         cost => 50,
365                         range => 6,
366                         build => 3.58,
367                         duration => 170,
368                         alt => 'Stasis Ward',
369                         hp => 30,
370                         shield => 30,
371                         armor => 0,
372                         attr => {
373                                 light => 1,
374                                 structure => 1,
375                         },
376                         sight => 0,
377                         speed => 0,
378                         special => [
379                                 {
380                                         name => 'Permanent Cloak',
381                                         abbr => 'cl',
382                                         desc => 'cloaked at all times',
383                                         duration => -1,
384                                 },
385                                 {
386                                         name => 'Stasis Trap',
387                                         abbr => 'st',
388                                         desc => 'triggered by nearby ground units, trapping them for 21½s',
389                                 },
390                         ],
391                 },
392         ],
393 },
394
395 {
396         %{ $unit{tempest} },
397         hp => $V lt v4.7.1 ? 300 : $V lt v4.11.0 ? 150 : 200,
398         shield => $V lt v4.7.1 ? 150 : $V lt v4.11.0 ? 125 : 100,
399         min => $V lt v4.7.1 ? 300 : 250,
400         gas => $V lt v4.7.1 ? 200 : 175,
401         pop => $V lt v4.7.1 ? 6 : 5,
402         speed => $V lt v4.7.1 ? 2.63 : $V lt v4.8.2 ? 3.5 : 3.15,
403         attack => [
404                 {
405                         %{ $unit{tempest}->{attack}->[0] }, # kinetic overload
406                         bonus => {
407                                 massive => 22,
408                                 -massive => 2,
409                         },
410                         range => $V lt v4.11.0 ? 15 : 14,
411                 },
412                 {
413                         %{ $unit{tempest}->{attack}->[1] }, # resonance coil
414                         bonus => {
415                                 structure => 0,
416                         },
417                         damage => 40,
418                         upgrade => 4,
419                 },
420         ],
421         upgrade => [
422                 $V lt v5.0.2 ? () : {
423                         name => 'Tectonic Destabilizers',
424                         attack => [
425                                 {},
426                                 {
427                                         bonus => {
428                                                 structure => 40,
429                                         },
430                                 },
431                         ],
432                         min => 150,
433                         gas => 150,
434                         build => 100,
435                 },
436         ],
437 },
438
439 {
440         %{ $unit{carrier} },
441         hp => $V lt v4.7.1 ? 250 : 300,
442         build => $V lt v4.7.1 ? 86 : 64,
443         special => [
444                 {
445                         %{ $unit{carrier}->{special}->[0] }, # interceptor
446                         min => 5,
447                         build => $V lt v4.7.1 ? 6 : $V lt v4.10.1 ? 11 : 9,
448                 },
449         ],
450         $V lt v4.7.1 ? () : (upgrade => []), # remove Graviton Catapult
451 },
452
453 # terran
454
455 $unit{scv},
456 $unit{mule},
457 $unit{missile_turret},
458 $unit{planetary_fortress},
459
460 $unit{marine},
461
462 {
463         %{ $unit{marauder} },
464         attack => [
465                 {
466                         %{ $unit{marauder}->{attack}->[0] }, # punisher grenades
467                         count => $V lt v4.3.0 ? 2 : 1,
468                         damage => $V lt v4.3.0 ? 5 : 10,
469                         upgrade => 1,
470                         bonus => {
471                                 armored => $V lt v4.3.0 ? 5 : 10,
472                                 -armored => $V lt v4.3.0 ? 0 : 1,
473                         },
474                 },
475         ],
476 },
477
478 {
479         %{ $unit{reaper} },
480         build => 32,
481 },
482
483 {
484         %{ $unit{ghost} },
485         min => 150,
486         gas => 125,
487         speed => 3.94,
488         special => [
489                 {
490                         # replaces Sniper Round
491                         name => 'Steady Targeting',
492                         abbr => 'st',
493                         desc => '170 damage ignoring armor to a biological unit after 1.43s without damage',
494                         cost => 50,
495                         range => 10,
496                         duration => 1.43,
497                 },
498                 {
499                         %{ $unit{ghost}->{special}->[1] }, # emp round
500                         radius => $V lt v4.10.1 ? 1.5 : 2,
501                 },
502                 $unit{ghost}->{special}->[2], # cloak
503                 $unit{ghost}->{special}->[3], # tac nuke strike
504         ],
505 },
506
507 {
508         %{ $unit{hellion} },
509         attack => [
510                 {
511                         %{ $unit{hellion}->{attack}->[0] }, # infernal flamethrower
512                         bonus => {
513                                 light => 5,
514                                 -light => 0,
515                         },
516                 },
517         ],
518         #TODO smart servos
519 },
520
521 {
522         %{ $unit{hellbat} },
523         special => [
524                 $unit{hellbat}->{special}->[0], # Hellion Mode
525                 {
526                         name => 'Smart Servos',
527                         min => 100,
528                         gas => 100,
529                         build => 79,
530                         transform => -1.43, # halve #TODO: alter special duration?
531                 },
532         ],
533 },
534
535 {
536         %{ $unit{widow_mine} },
537         build => 21,
538         attack => [
539                 {
540                         %{ $unit{widow_mine}->{attack}->[0] }, # Sentinel Missiles
541                         bonus => {
542                                 shields => 25,
543                         },
544                 },
545         ],
546 },
547
548 {
549         %{ $unit{siege_tank} },
550         hp => 175,
551         special => [
552                 {
553                         %{ $unit{siege_tank}->{special}->[0] }, # siege mode
554                         attack => [
555                                 {
556                                         %{ $unit{siege_tank}->{special}->[0]->{attack}->[0] }, # shock cannon
557                                         damage => 40,
558                                         upgrade => 4,
559                                         bonus => {
560                                                 armored => 30,
561                                                 -armored => 1,
562                                         },
563                                         cooldown => 2.14,
564                                 },
565                         ],
566                 },
567         ],
568 },
569
570 {
571         race => 'terran',
572         cat => 'factory',
573         name => 'Cyclone',
574         pop => 3,
575         min => 150,
576         gas => 100,
577         build => 32,
578         size => 1.5,
579         cargo => 3,
580         armor => 1,
581         hp => $V lt v4.7.1 ? 180 : 120,
582         attr => {
583                 armored => 1,
584                 mech => 1,
585         },
586         attack => [
587                 {
588                         anti => 1,
589                         name => $V lt v4.7.1 ? 'Tornado Blaster' : 'Typhoon Missile Pod',
590                         damage => $V lt v4.7.1 ? 3 : 18,
591                         upgrade => $V lt v4.7.1 ? 1 : 2,
592                         bonus => $V ge v4.7.1 ? {} : {
593                                 armored => 2,
594                                 -armored => 0,
595                         },
596                         cooldown => $V lt v4.7.1 ? .1 : .71,
597                         range => $V lt v4.7.1 ? 6 : 5,
598                 },
599         ],
600         speed => $V lt v4.7.1 ? 4.13 : 4.73,
601         sight => 11,
602         special => [
603                 {
604                         name => 'Lock On',
605                         abbr => 'lo',
606                         desc => $V lt v4.7.1 ? 'target air for 160 damage ignoring armor while visible and within 15 range'
607                                              : 'deal 400 damage (double to armored after upgrade) over 14 seconds',
608                         range => 7,
609                         duration => 14.3,
610                         cooldown => 4,
611                 },
612                 $V ge v4.7.1 ? () : {
613                         name => 'Rapid Fire Launchers',
614                         abbr => 'rf',
615                         desc => 'rapid first 12 Lock On shots',
616                         min => 75,
617                         gas => 75,
618                         build => 79,
619                 },
620         ],
621         upgrade => [
622                 $V lt v4.7.1 ? () : {
623                         name => 'Mag-Field Accelerator',
624                         min => 100,
625                         gas => 100,
626                         build => $V lt v4.8.2 ? 79 : 100,
627                         desc => 'increases lock-on damage to ',
628                 },
629         ],
630 },
631
632 {
633         %{ $unit{thor} },
634         armor => $V ge v3.14.0 && $V lt v4.7.1 ? 2 : 1,
635         attack => [
636                 $unit{thor}->{attack}->[0], # thor's hammer
637                 $unit{thor}->{attack}->[1], # javelin missiles
638                 {
639                         %{ $unit{thor}->{attack}->[2] }, # punisher cannons
640                         name => 'High Impact Payload',
641                         damage => $V lt v4.7.1 ? 35 : $V lt v4.11.0 ? 40 : 25,
642                         upgrade => 3,
643                         bonus => {
644                                 $V lt v4.7.1 ? 'armored' : 'massive' => $V lt v4.11.0 ? 15 : 10,
645                                 $V lt v4.7.1 ? '-armored' : '-massive' => 2,
646                         },
647                         cooldown => $V lt v4.7.1 ? 2.14 : $V lt v4.11.0 ? 1.71 : .9,
648                         range => $V lt v4.8.2 ? 10 : 11,
649                 },
650         ],
651         #TODO smart servos
652 },
653
654 {
655         %{ $unit{viking} },
656         hp => $V lt v4.3.0 ? 125 : 135,
657 },
658
659 {
660         %{ $unit{medivac} },
661         special => [
662                 $unit{medivac}->{special}->[0], # heal
663                 {
664                         %{ $unit{medivac}->{special}->[1] }, # ignite afterburners
665                         desc => 'boost speed and accelleration to 4.25 for 8s',
666                         speed => 5.94,
667                         duration => $V lt v4.7.1 ? 6.43 : 4.29,
668                         cooldown => $V lt v4.11.0 ? 20 : 14,
669                         -cooldown => 9,
670                 },
671         ],
672         upgrade => [
673                 {
674                         name => 'Rapid Reignition System',
675                         min => 100,
676                         gas => 100,
677                         build => 57,
678                         speed => .63,
679                 },
680         ],
681 },
682
683 {
684         race => 'terran',
685         cat => 'starport',
686         name => 'Liberator',
687
688         pop => 3,
689         min => 150,
690         gas => 150,
691         build => 43,
692         size => 1.5,
693         armor => 0,
694         hp => 180,
695         attr => {
696                 armored => 1,
697                 mech => 1,
698                 flying => 1,
699         },
700         attack => [
701                 {
702                         anti => 2,
703                         name => 'Lexington Rockets',
704                         damage => 5,
705                         upgrade => 1,
706                         type => 'projectile',
707                         cooldown => 1.29,
708                         count => 2,
709                         range => 5,
710                 },
711         ],
712         special => [
713                 {
714                         name => 'Defender Mode',
715                         abbr => 'dm',
716                         transform => 2.88, # 1.46s to revert
717                         alt => 'Defender Liberator',
718                         attack => [
719                                 {
720                                         anti => 1,
721                                         name => 'Concord Cannon',
722                                         desc => 'within 5 diameter circle',
723                                         damage => 75,
724                                         upgrade => 5,
725                                         cooldown => 1.14,
726                                         range => 10,
727                                 },
728                         ],
729                         speed => 0,
730                         sight => 15, # only targeted area
731                         upgrade => [
732                                 {
733                                         name => 'Advanced Ballistics',
734                                         min => 150,
735                                         gas => 150,
736                                         build => 79,
737                                         attack => [
738                                                 {
739                                                         range => 4,
740                                                 },
741                                         ],
742                                         sight => 4,
743                                 },
744                         ],
745                 },
746         ],
747         speed => 4.72,
748         sight => 10,
749 },
750
751 {
752         %{ $unit{banshee} },
753         speed => 3.85,
754         upgrade => [
755                 {
756                         name => 'Hyperflight Rotors',
757                         speed => 1.4,
758                         min => $V lt v4.7.1 ? 200 : 150,
759                         gas => $V lt v4.7.1 ? 200 : 150,
760                         build => 121,
761                 },
762         ],
763 },
764
765 {
766         %{ $unit{raven} },
767         speed => $V lt v4.11.0 ? 3.85 : 4.13,
768         special => [
769                 {
770                         %{ $unit{raven}->{special}->[0] }, # auto-turret
771                         attack => [
772                                 {
773                                         anti => 3,
774                                         name => '12 mm Gauss Cannon',
775                                         damage => 18,
776                                         cooldown => .57,
777                                         range => 6,
778                                 },
779                         ],
780                         range => $V lt v4.3.0 ? 1 : 2,
781                         duration => 10,
782                         upgrade => [
783                                 $unit{raven}->{special}->[0]->{upgrade}->[0], # hi-sec auto tracking
784                                 $unit{raven}->{special}->[0]->{upgrade}->[1], # structure armor
785                                 # no more durable materials
786                         ],
787                 },
788                 {
789                         name => 'Interference Matrix',
790                         abbr => 'im',
791                         desc => 'disable target mech or psionic unit rendering it unable to attack or cast',
792                         cost => $V lt v4.11.0 ? 50 : 75,
793                         range => 9,
794                         duration => $V lt v4.11.0 ? 7.9 : 11,
795                 },
796                 {
797                         name => 'Anti-Armor Missile',
798                         abbr => 'aa',
799                         desc => $V lt v4.7.1 ? 'launches missile to do splash damage and reduce armor by 3'
800                                              : 'launches missile to reduce armor by 3',
801                         range => 10,
802                         size => 2.88,
803                         attack => [
804                                 {
805                                         damage => $V lt v4.3.0 ? 30 : $V lt v4.7.1 ? 15 : 0,
806                                         splash => 1,
807                                 },
808                         ],
809                         cost => 75,
810                         duration => 21,
811                 },
812         ],
813 },
814
815 {
816         %{ $unit{battlecruiser} },
817         attack => [
818                 $unit{battlecruiser}->{attack}->[0], # ats laser
819                 {
820                         %{ $unit{battlecruiser}->{attack}->[1] }, # ata laser
821                         damage => $V lt v4.7.1 ? 6 : 5,
822                 },
823         ],
824         special => [
825                 {
826                         name => 'Tactical Jump',
827                         abbr => 'tj',
828                         desc => 'warps to the target location after 5s (invulnerable after 1s)',
829                         duration => 4,
830                         cooldown => 71,
831                 },
832                 {
833                         %{ $unit{battlecruiser}->{special}->[0] }, # yc
834                         desc => '240 damage to a single target',
835                         attack => [
836                                 {
837                                         damage => 240,
838                                 },
839                         ],
840                         cost => undef,
841                         cooldown => 71,
842                 },
843         ],
844         upgrade => [],
845 },
846
847 # zerg
848
849 $unit{drone},
850
851 {
852         %{ $unit{queen} },
853         attack => [
854                 $unit{queen}->{attack}->[0], # claws
855                 {
856                         %{ $unit{queen}->{attack}->[1] }, # acid spines
857                         range => $V lt v4.12.0 ? 8 : 7,
858                 },
859         ],
860         range => 8,
861 },
862
863 {
864         %{ $unit{overlord} },
865         speed => .902, # changed in 4.0.0
866         upgrade => [
867                 {
868                         %{ $unit{overlord}->{upgrade}->[0] }, # carapace
869                         speed => 2.63-.902,
870                 },
871                 $unit{overlord}->{upgrade}->[1], # sacs
872         ],
873 },
874
875 {
876         %{ $unit{overseer} },
877         special => [
878                 {
879                         name => 'Oversight Mode',
880                         abbr => 'om',
881                         desc => 'gain 25% vision while immobilized',
882                         speed => 0,
883                         sight => 11 * 1.25,
884                         transform => .54,
885                 },
886                 @{ $unit{overseer}->{special} }, # changeling, contaminate
887         ],
888 },
889
890 $unit{larva},
891 $unit{spine_crawler},
892
893 {
894         %{ $unit{spore_crawler} },
895         attack => [
896                 {
897                         %{ $unit{spore_crawler}->{attack}->[0] }, # seeker spores
898                         bonus => {
899                                 organic => 15,
900                         },
901                 },
902         ],
903         speed => (1.5),
904         creep => 2.6,
905 },
906
907 $unit{zergling},
908
909 {
910         %{ $unit{baneling} },
911         min => 25,
912         attack => [
913                 {
914                         %{ $unit{baneling}->{attack}->[0] }, # volatile burst
915                         damage => $V lt v4.12.0 ? 20 : $V lt v5.0.2 ? 18 : 15,
916                         bonus => {
917                                 light => $V lt v4.12.0 ? 15 : $V lt v5.0.2 ? 17 : 20,
918                                 -light => 2,
919                                 structure => 80,
920                                 -structure => 5,
921                         },
922                         splash => 1,
923                         range => 0,
924                 },
925         ],
926         upgrade => [
927                 {
928                         %{ $unit{baneling}->{upgrade}->[0] }, # centrifugal hooks
929                         hp => 5,
930                 },
931         ],
932 },
933
934 {
935         %{ $unit{roach} },
936         special => [
937                 {
938                         %{ $unit{roach}->{special}->[0] }, # rapid regeneration
939                         desc => 'regenerates health at 7 HP/s while burrowed',
940                 },
941                 {
942                         %{ $unit{roach}->{special}->[1] }, # tunneling claws
943                         min => $V lt v4.7.1 ? 150 : 100,
944                         gas => $V lt v4.7.1 ? 150 : 100,
945                         build => 79,
946                         desc => 'move while burrowed at speed of 2.8',
947                 },
948         ],
949 },
950
951 {
952         race => 'zerg',
953         cat => 'hatchery',
954         name => 'Ravager',
955         base => ['Roach'],
956         pop => 3,
957         min => 25,
958         gas => 75,
959         build => 9,
960         size => 1.5,
961         cargo => 4,
962         armor => 1,
963         hp => 120,
964         attr => {
965                 organic => 1,
966         },
967         attack => [
968                 {
969                         anti => 1,
970                         name => '?',
971                         damage => 16,
972                         upgrade => 2,
973                         type => 'projectile',
974                         cooldown => 1.14,
975                         range => 6,
976                 },
977         ],
978         speed => 3.85,
979         creep => 1.3,
980         sight => 9,
981 },
982
983 {
984         %{ $unit{hydralisk} },
985         hp => 90,
986         upgrade => [
987                 {
988                         %{ $unit{hydralisk}->{upgrade}->[0] }, # grooved spines
989                         attack => [
990                                 {
991                                         range => 2,
992                                 },
993                         ],
994                 },
995                 $unit{hydralisk}->{upgrade}->[1], # muscular augments
996         ],
997 },
998
999 {
1000         race => 'zerg',
1001         cat => 'lair',
1002         name => 'Lurker',
1003         base => ['Hydralisk'],
1004         pop => 3,
1005         min => 50,
1006         gas => 100,
1007         build => 18,
1008         cargo => 4,
1009         armor => 1,
1010         hp => 200,
1011         attr => {
1012                 armored => 1,
1013                 organic => 1,
1014         },
1015         attack => [
1016                 {
1017                         anti => 1,
1018                         name => '?',
1019                         damage => 20,
1020                         upgrade => 2,
1021                         splash => 'line',
1022                         cooldown => 1.43,
1023                         range => $V lt v4.11.0 ? 9 : 8,
1024                         bonus => {
1025                                 armored => 10,
1026                                 -armored => 1,
1027                         },
1028                 },
1029         ],
1030         upgrade => [
1031                 $V lt v4.11.0 ? () : {
1032                         name => 'Seismic Spines',
1033                         attack => [
1034                                 {
1035                                         range => 2,
1036                                 },
1037                         ],
1038                         req => 'Hive',
1039                         min => 150,
1040                         gas => 150,
1041                         build => 57,
1042                 },
1043         ],
1044         speed => 4.13,
1045         creep => 1.3,
1046         sight => 10,
1047 },
1048
1049 {
1050         %{ $unit{infestor} },
1051         special => [
1052                 {
1053                         %{ $unit{infestor}->{special}->[0] }, # neural parasite
1054                         range => $V lt v4.11.0 ? 9 : 8,
1055                 },
1056                 $unit{infestor}->{special}->[1], # fungal growth
1057                 {
1058                         name => 'Microbial Shroud',
1059                         abbr => 'ms',
1060                         desc => 'reduce damage from air by 50% to ground units in target area',
1061                         cost => $V lt v4.11.3 ? 100 : 75,
1062                         min => $V lt v4.11.3 ? 150 : undef,
1063                         gas => $V lt v4.11.3 ? 150 : undef,
1064                         build => $V lt v4.11.3 ? 79 : undef,
1065                         req => $V lt v4.11.3 ? 'Hive' : undef,
1066                         range => 9,
1067                         duration => 11,
1068                         radius => $V lt v4.11.3 ? 3 : 3.5,
1069                 },
1070                 $V ge v4.11.0 ? () : {
1071                         %{ $unit{infestor}->{special}->[2] }, # infested terran
1072                         attack => [
1073                                 {
1074                                         %{ $unit{infestor}->{special}->[2]->{attack}->[0] }, # rockets
1075                                         cooldown => $V lt v4.10.1 ? .95 : 1.14,
1076                                 },
1077                         ],
1078                 },
1079         ],
1080 },
1081
1082 {
1083         % {$unit{nydus_worm} },
1084         min => $V lt v4.7.1 ? 100 : $V lt v4.11.0 ? 50 : 75, # Nydus Network costs 150/150
1085         gas => $V lt v4.7.1 ? 100 : $V lt v4.11.0 ? 50 : 75,
1086         cooldown => $V lt v4.11.0 ? 0 : 14, # Summon Nydus Worm
1087 },
1088
1089 {
1090         %{ $unit{swarm_host} },
1091         gas => 75,
1092         special => [
1093                 {
1094                         %{ $unit{swarm_host}->{special}->[0] }, # locust
1095                         hp => 50,
1096                         upgrade => [], # no flying
1097                 },
1098         ],
1099         upgrade => [],
1100 },
1101
1102 $unit{mutalisk},
1103 $unit{corruptor},
1104 $unit{brood_lord},
1105 $unit{viper},
1106
1107 {
1108         %{ $unit{ultralisk} },
1109         armor => 2,
1110         upgrade => [
1111                 $unit{ultralisk}->{upgrade}->[0], # chitinous plating
1112                 {
1113                         name => 'Anabolic Synthesis',
1114                         min => 150,
1115                         gas => 150,
1116                         build => 42.85,
1117                         speed => $V lt v4.8.2 ? .41 : .82,
1118                         creep => -.215, # reverse speed increase
1119                 },
1120         ],
1121 },
1122
1123 ]