emoji: silence unused argument warnings
[sheet.git] / sc-units-lotv.inc.pl
1 use utf8;
2 use strict;
3
4 my $RT = 1.4;  # real-time speed factor to faster
5
6 my $hots = do 'sc-units-hots.inc.pl' or die $!;
7 my %unit;
8 for my $row (@{$hots}) {
9         ref $row eq 'HASH' or next;
10         for ($row, @{ $row->{special} }, @{ $row->{upgrade} }) {
11                 $_ *= $RT for $_->{speed} // ();
12                 $_ /= $RT for $_->{build} // (), $_->{transform} // (), $_->{warp} // (), $_->{cooldown} // ();
13                 $_->{cooldown} and $_->{cooldown} /= $RT for @{ $_->{attack} // [] };
14         }
15         $unit{ lc $row->{name} =~ tr/ /_/r } = $row;
16 }
17
18 [
19 'patch 4.1.4',
20
21 # protoss
22
23 $unit{probe},
24
25 $unit{photon_cannon},
26
27 {
28         %{ $unit{mothership} },
29         speed => 2.62,
30 },
31
32 $unit{nexus},
33
34 {
35         %{ $unit{zealot} },
36         special => [
37                 {
38                         name => 'Charge',
39                         abbr => 'ch',
40                         desc => 'on attack, increases movement speed to 8.47 for 2.5s and deals 8 damage on hit',
41                         min => 100, # changed in 3.14.0
42                         gas => 100,
43                         build => 100,
44                         speed => .5,
45                         range => 4,
46                         duration => 2.5,
47                         cooldown => 7,
48                 },
49         ],
50         upgrade => [
51                 {
52                         name => 'Charge',
53                         speed => .98,
54                 },
55         ],
56 },
57
58 $unit{sentry},
59
60 {
61         %{ $unit{stalker} },
62         attack => [
63                 {
64                         %{ $unit{stalker}->{attack}->[0] }, # particle disruptors
65                         damage => 13,
66                         bonus => {
67                                 armored => 5,
68                                 -armored => 1,
69                         },
70                         cooldown => 1.34,
71                 },
72         ],
73 },
74
75 {
76         race => 'protoss',
77         cat => 'gateway',
78         name => 'Adept',
79         pop => 2,
80         min => 100,
81         gas => 25,
82         build => 27,
83         warp => 20,
84         size => 1,
85         cargo => 2,
86         armor => 1,
87         hp => 70,
88         shield => 70,
89         attr => {
90                 light => 1,
91                 organic => 1,
92         },
93         attack => [
94                 {
95                         anti => 1,
96                         name => undef, #TODO
97                         damage => 10,
98                         upgrade => 1,
99                         bonus => {
100                                 light => 12,
101                                 -light => 1,
102                         },
103                         type => 'projectile', #XXX: assumption
104                         cooldown => 1.61,
105                         range => 4,
106                 },
107         ],
108         speed => 3.5,
109         sight => 9,
110         special => [
111                 {
112                         name => 'Psionic Transfer',
113                         abbr => 'pt',
114                         desc => 'project shade, teleport after 7s',
115                         cooldown => 11,
116
117                         alt => 'Shade',
118                         build => 0,
119                         size => 0,
120                         cargo => 0,
121                         hp => -1,
122                         attack => [], #TODO: indicate diff from parent
123                         speed => 5, #XXX: faster than 3.5
124                         range => 7, #XXX: calculate from speed
125                         sight => 4,
126                 },
127         ],
128         upgrade => [
129                 {
130                         name => 'Resonating Glaives',
131                         min => 100,
132                         gas => 100,
133                         build => 100,
134                         attack => [
135                                 {
136                                         cooldown => -.5, # +45%
137                                 },
138                         ],
139                 },
140         ],
141 },
142
143 {
144         %{ $unit{high_templar} },
145         attack => [
146                 {
147                         anti => 1,
148                         name => '?', #XXX
149                         damage => 4,
150                         upgrade => 1,
151                         cooldown => 1.25,
152                         range => 6,
153                 },
154         ],
155 },
156
157 $unit{dark_templar},
158 $unit{archon},
159 $unit{observer},
160
161 {
162         %{ $unit{warp_prism} },
163         hp => 80,
164         upgrade => [
165                 {
166                         %{ $unit{warp_prism}->{special}->[0] }, # gravitic drive
167                         speed => 1.23,
168                 },
169         ],
170 },
171
172 $unit{immortal},
173
174 {
175         %{ $unit{colossus} },
176         attack => [
177                 {
178                         %{ $unit{colossus}->{attack}->[0] }, # thermal lances
179                         damage => 10,
180                         upgrade => 1,
181                         bonus => {
182                                 light => 5,
183                                 -light => 1,
184                         },
185 #                       cooldown => 1.18, #XXX
186                 },
187         ],
188 },
189
190 {
191         race => 'protoss',
192         cat => 'robotic',
193         name => 'Disruptor',
194         pop => 3,
195         min => 150,
196         gas => 150,
197         build => 36,
198         size => 1,
199         cargo => 4,
200         armor => 1,
201         hp => 100,
202         shield => 100,
203         attr => {
204                 armored => 1,
205                 mech => 1,
206         },
207         attack => [
208                 {
209                         anti => 1,
210                         name => 'Purification Nova',
211                         damage => 145,
212                         bonus => {
213                                 shields => 55,
214                         },
215                         type => 'trans', #TODO: indicate
216                         splash => 1.5,
217                         cooldown => 14.3,
218                         range => 13, # 2s
219                 },
220         ],
221         speed => 3.15,
222         sight => 9,
223 },
224
225 $unit{phoenix},
226
227 {
228         %{ $unit{void_ray} },
229         speed => 3.5,
230 },
231
232 {
233         %{ $unit{oracle} },
234         build => 37,
235         attack => [
236                 {
237                         %{ $unit{oracle}->{attack}->[0] }, # pulsar beam
238                         bonus => {
239                                 light => 7,
240                         },
241                 },
242         ],
243         special => [
244                 {
245                         name => 'Revelation',
246                         abbr => 'rv',
247                         desc => 'hit enemy units and buildings are revealed for Â½ minute',
248                         cost => 50,
249                         range => 9,
250                         cooldown => 2.2,
251                         duration => 30,
252                         radius => 6,
253                 },
254                 {
255                         name => 'Stasis Ward',
256                         abbr => 'sw',
257                         desc => 'places ward for 170s',
258                         cost => 50,
259                         range => 6,
260                         build => 3.58,
261                         duration => 170,
262                         alt => 'Stasis Ward',
263                         hp => 30,
264                         shield => 30,
265                         armor => 0,
266                         attr => {
267                                 light => 1,
268                                 structure => 1,
269                         },
270                         sight => 0,
271                         speed => 0,
272                         special => [
273                                 {
274                                         name => 'Permanent Cloak',
275                                         abbr => 'cl',
276                                         desc => 'cloaked at all times',
277                                         duration => -1,
278                                 },
279                                 {
280                                         name => 'Stasis Trap',
281                                         abbr => 'st',
282                                         desc => 'triggered by nearby ground units, trapping them for 21½s',
283                                 },
284                         ],
285                 },
286         ],
287 },
288
289 {
290         %{ $unit{tempest} },
291         hp => 300,
292         shield => 150,
293         attack => [
294                 {
295                         %{ $unit{tempest}->{attack}->[0] }, # kinetic overload
296                         bonus => {
297                                 massive => 22,
298                                 -massive => 2,
299                         },
300                 },
301                 {
302                         %{ $unit{tempest}->{attack}->[1] }, # resonance coil
303                         damage => 40,
304                         upgrade => 4,
305                 },
306         ],
307 },
308
309 {
310         %{ $unit{carrier} },
311         hp => 250,
312         special => [
313                 {
314                         %{ $unit{carrier}->{special}->[0] }, # interceptor
315                         min => 5,
316                 },
317         ],
318 },
319
320 # terran
321
322 $unit{scv},
323 $unit{mule},
324 $unit{missile_turret},
325 $unit{planetary_fortress},
326
327 $unit{marine},
328
329 {
330         %{ $unit{marauder} },
331         attack => [
332                 {
333                         %{ $unit{marauder}->{attack}->[0] }, # punisher grenades
334                         count => 2,
335                         damage => 5,
336                         upgrade => 1,
337                         bonus => {
338                                 armored => 5,
339                                 -armored => 0,
340                         },
341                 },
342         ],
343 },
344
345 {
346         %{ $unit{reaper} },
347         build => 32,
348 },
349
350 {
351         %{ $unit{ghost} },
352         min => 150,
353         gas => 125,
354         speed => 3.94,
355         special => [
356                 {
357                         # replaces Sniper Round
358                         name => 'Steady Targeting',
359                         abbr => 'st',
360                         desc => '170 damage ignoring armor to a biological unit after 1.43s without damage',
361                         cost => 50,
362                         range => 10,
363                         duration => 1.43,
364                 },
365                 $unit{ghost}->{special}->[1], # emp round
366                 $unit{ghost}->{special}->[2], # cloak
367                 $unit{ghost}->{special}->[3], # tac nuke strike
368         ],
369 },
370
371 {
372         %{ $unit{hellion} },
373         attack => [
374                 {
375                         %{ $unit{hellion}->{attack}->[0] }, # infernal flamethrower
376                         bonus => {
377                                 light => 5,
378                                 -light => 0,
379                         },
380                 },
381         ],
382         #TODO smart servos
383 },
384
385 {
386         %{ $unit{hellbat} },
387         special => [
388                 $unit{hellbat}->{special}->[0], # Hellion Mode
389                 {
390                         name => 'Smart Servos',
391                         min => 100,
392                         gas => 100,
393                         build => 79,
394                         transform => -1.43, # halve #TODO: alter special duration?
395                 },
396         ],
397 },
398
399 {
400         %{ $unit{widow_mine} },
401         build => 21,
402         attack => [
403                 {
404                         %{ $unit{widow_mine}->{attack}->[0] }, # Sentinel Missiles
405                         bonus => {
406                                 shields => 25,
407                         },
408                 },
409         ],
410 },
411
412 {
413         %{ $unit{siege_tank} },
414         hp => 175,
415         special => [
416                 {
417                         %{ $unit{siege_tank}->{special}->[0] }, # siege mode
418                         attack => [
419                                 {
420                                         %{ $unit{siege_tank}->{special}->[0]->{attack}->[0] }, # shock cannon
421                                         damage => 40,
422                                         upgrade => 4,
423                                         bonus => {
424                                                 armored => 30,
425                                                 -armored => 1,
426                                         },
427                                         cooldown => 2.14,
428                                 },
429                         ],
430                 },
431         ],
432 },
433
434 {
435         race => 'terran',
436         cat => 'factory',
437         name => 'Cyclone',
438         pop => 3,
439         min => 150,
440         gas => 100,
441         build => 32,
442         size => 1.5,
443         cargo => 3,
444         armor => 1,
445         hp => 180,
446         attr => {
447                 armored => 1,
448                 mech => 1,
449         },
450         attack => [
451                 {
452                         anti => 1,
453                         name => 'Typhoon Blaster',
454                         damage => 3,
455                         upgrade => 1,
456                         bonus => {
457                                 armored => 2,
458                                 -armored => 0,
459                         },
460                         cooldown => .1,
461                         range => 6,
462                 },
463         ],
464         speed => 4.13,
465         sight => 11,
466         special => [
467                 {
468                         name => 'Lock On',
469                         abbr => 'lo',
470                         desc => 'target air for 160 damage ignoring armor while visible and within 15 range',
471                         range => 7,
472                         duration => 14,
473                         cooldown => 4,
474                 },
475                 {
476                         name => 'Rapid Fire Launchers',
477                         abbr => 'rf',
478                         desc => 'rapid first 12 Lock On shots',
479                         min => 75,
480                         gas => 75,
481                         build => 79,
482                 },
483         ],
484 },
485
486 {
487         %{ $unit{thor} },
488         armor => 2,
489         attack => [
490                 $unit{thor}->{attack}->[0],
491                 $unit{thor}->{attack}->[1],
492                 {
493                         %{ $unit{thor}->{attack}->[2] }, # high impact
494                         damage => 35,
495                         upgrade => 3,
496                         bonus => {
497                                 armored => 15,
498                                 -armored => 2,
499                         },
500                         cooldown => 2.14,
501                 },
502         ],
503         #TODO smart servos
504 },
505
506 $unit{viking},
507 $unit{medivac},
508
509 {
510         race => 'terran',
511         cat => 'starport',
512         name => 'Liberator',
513
514         pop => 3,
515         min => 150,
516         gas => 150,
517         build => 43,
518         size => 1.5,
519         armor => 0,
520         hp => 180,
521         attr => {
522                 armored => 1,
523                 mech => 1,
524                 flying => 1,
525         },
526         attack => [
527                 {
528                         anti => 2,
529                         name => 'Lexington Rockets',
530                         damage => 5,
531                         upgrade => 1,
532                         type => 'projectile',
533                         cooldown => 1.29,
534                         count => 2,
535                         range => 5,
536                 },
537         ],
538         special => [
539                 {
540                         name => 'Defender Mode',
541                         abbr => 'dm',
542                         transform => 2.88, # 1.46s to revert
543                         alt => 'Defender Liberator',
544                         attack => [
545                                 {
546                                         anti => 1,
547                                         name => 'Concord Cannon',
548                                         desc => 'within 5 diameter circle',
549                                         damage => 75,
550                                         upgrade => 5,
551                                         cooldown => 1.14,
552                                         range => 10,
553                                 },
554                         ],
555                         speed => 0,
556                         sight => 15, # only targeted area
557                         upgrade => [
558                                 {
559                                         name => 'Advanced Ballistics',
560                                         min => 150,
561                                         gas => 150,
562                                         build => 79,
563                                         attack => [
564                                                 {
565                                                         range => 4,
566                                                 },
567                                         ],
568                                         sight => 4,
569                                 },
570                         ],
571                 },
572         ],
573         speed => 4.72,
574         sight => 10,
575 },
576
577 $unit{banshee},
578
579 {
580         %{ $unit{raven} },
581         speed => 3.85,
582         special => [
583                 {
584                         %{ $unit{raven}->{special}->[0] }, # auto-turret
585                         attack => [
586                                 {
587                                         anti => 3,
588                                         name => '12 mm Gauss Cannon',
589                                         damage => 18,
590                                         cooldown => .57,
591                                         range => 6,
592                                 },
593                         ],
594                         range => 1,
595                         duration => 10,
596                         upgrade => [
597                                 $unit{raven}->{special}->[0]->{upgrade}->[0], # hi-sec auto tracking
598                                 $unit{raven}->{special}->[0]->{upgrade}->[1], # structure armor
599                                 # no more durable materials
600                         ],
601                 },
602                 {
603                         name => 'Interference Matrix',
604                         abbr => 'im',
605                         desc => 'disable target mech or psionic unit rendering it unable to attack or cast',
606                         cost => 50,
607                         range => 9,
608                         duration => 7.9,
609                 },
610                 {
611                         name => 'Anti-Armor Missile',
612                         abbr => 'aa',
613                         desc => 'launches missile to do 30 splash damage and reduces armor by 3',
614                         range => 10,
615                         size => 2.88,
616                         attack => [
617                                 {
618                                         damage => 30,
619                                         splash => 1,
620                                 },
621                         ],
622                         cost => 75,
623                         duration => 21,
624                 },
625         ],
626 },
627
628 $unit{battlecruiser},
629
630 # zerg
631
632 $unit{drone},
633
634 {
635         %{ $unit{queen} },
636         attack => [
637                 $unit{queen}->{attack}->[0], # claws
638                 {
639                         %{ $unit{queen}->{attack}->[1] }, # acid spines
640                         range => 8,
641                 },
642         ],
643         range => 8,
644 },
645
646 {
647         %{ $unit{overlord} },
648         speed => .902, # changed in 4.0.0
649         upgrade => [
650                 {
651                         %{ $unit{overlord}->{upgrade}->[0] }, # carapace
652                         speed => 2.63-.902,
653                 },
654                 $unit{overlord}->{upgrade}->[1], # sacs
655         ],
656 },
657
658 $unit{overseer},
659
660 $unit{larva},
661 $unit{spine_crawler},
662
663 {
664         %{ $unit{spore_crawler} },
665         attack => [
666                 {
667                         %{ $unit{spore_crawler}->{attack}->[0] }, # seeker spores
668                         bonus => {
669                                 organic => 15,
670                         },
671                 },
672         ],
673         speed => (1.5),
674         creep => 2.6,
675 },
676
677 $unit{zergling},
678
679 {
680         %{ $unit{baneling} },
681         min => 25,
682         upgrade => [
683                 {
684                         %{ $unit{baneling}->{upgrade}->[0] }, # centrifugal hooks
685                         hp => 5,
686                 },
687         ],
688 },
689
690 $unit{roach},
691
692 {
693         race => 'zerg',
694         cat => 'hatchery',
695         name => 'Ravager',
696         base => ['Roach'],
697         pop => 3,
698         min => 25,
699         gas => 75,
700         build => 9,
701         size => 1.5,
702         cargo => 4,
703         armor => 1,
704         hp => 120,
705         attr => {
706                 organic => 1,
707         },
708         attack => [
709                 {
710                         anti => 1,
711                         name => '?',
712                         damage => 16,
713                         upgrade => 2,
714                         type => 'projectile',
715                         cooldown => 1.14,
716                         range => 6,
717                 },
718         ],
719         speed => 3.85,
720         creep => 1.3,
721         sight => 9,
722 },
723
724 {
725         %{ $unit{hydralisk} },
726         hp => 90,
727         upgrade => [
728                 {
729                         %{ $unit{hydralisk}->{upgrade}->[0] }, # grooved spines
730                         attack => [
731                                 {
732                                         range => 2,
733                                 },
734                         ],
735                 },
736                 $unit{hydralisk}->{upgrade}->[1], # muscular augments
737         ],
738 },
739
740 {
741         race => 'zerg',
742         cat => 'lair',
743         name => 'Lurker',
744         base => ['Hydralisk'],
745         pop => 3,
746         min => 50,
747         gas => 100,
748         build => 18,
749         cargo => 4,
750         armor => 1,
751         hp => 200,
752         attr => {
753                 armored => 1,
754                 organic => 1,
755         },
756         attack => [
757                 {
758                         anti => 1,
759                         name => '?',
760                         damage => 20,
761                         upgrade => 2,
762                         splash => 'line',
763                         cooldown => 1.43,
764                         range => 9,
765                         bonus => {
766                                 armored => 10,
767                                 -armored => 1,
768                         },
769                 },
770         ],
771         speed => 4.13,
772         creep => 1.3,
773         sight => 10,
774 },
775
776 $unit{infestor},
777 $unit{nydus_worm},
778
779 {
780         %{ $unit{swarm_host} },
781         gas => 75,
782         special => [
783                 {
784                         %{ $unit{swarm_host}->{special}->[0] }, # locust
785                         hp => 50,
786                         upgrade => [], # no flying
787                 },
788         ],
789         upgrade => [],
790 },
791
792 $unit{mutalisk},
793 $unit{corruptor},
794 $unit{brood_lord},
795 $unit{viper},
796
797 {
798         %{ $unit{ultralisk} },
799         armor => 2,
800 },
801
802 ]