-
Notifications
You must be signed in to change notification settings - Fork 6
/
player_ship_upgrade_downgrade_path_scenario_utility.lua
9595 lines (9595 loc) · 453 KB
/
player_ship_upgrade_downgrade_path_scenario_utility.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
function addShipUpgradeInfoToScienceDatabase(template)
local ship_yard_key = _("scienceDB","Ship Yard")
local ship_yard_db = queryScienceDatabase(ship_yard_key)
if ship_yard_db == nil then
ship_yard_db = ScienceDatabase():setName(ship_yard_key)
ship_yard_db = queryScienceDatabase(ship_yard_key)
ship_yard_db:setLongDescription(_("scienceDB","A ship yard is where starships are built, maintained and enhanced. They typically get built in to stations to facilitate services such as energy recharging, hull repair, probe and ordnance replenishment, etc. This section of the science database shows ship types that might get upgraded by ship yards in the area and the details around potentially available upgrades."))
end
local template_db = queryScienceDatabase(ship_yard_key,template)
if template_db == nil and upgrade_path[template] ~= nil then
local template_descriptions = {
["MP52 Hornet"] = {image = "radar/fighter.png", model = "WespeScoutYellow", desc = _("scienceDB","The MP52 Hornet is a significantly upgraded version of MU52 Hornet, with nearly twice the hull strength, nearly three times the shielding, better acceleration, impulse boosters, and a second laser cannon."),},
["ZX-Lindworm"] = {image = "radar/fighter.png", model = "LindwurmFighterBlue", desc = _("scienceDB","The ZX model is an improvement on the WX-Lindworm with stronger hull and shields, faster impulse and tubes, more missiles and a single weak, turreted beam. The 'Worm' as it's often called, is a bomber-class starfighter. While one of the least-shielded starfighters in active duty, the Worm's launchers can pack quite a punch. Its goal is to fly in, destroy its target, and fly out or be destroyed."),},
["Phobos M3P"] = {image = "radar/cruiser.png", model = "AtlasHeavyFighterYellow", desc = _("scienceDB","Player variant of the Phobos M3. Not as strong as the Atlantis, but has front firing tubes, making it an easier to use ship in some scenarios."),},
["Hathcock"] = {image = "radar/piranha.png", model = "HeavyCorvetteGreen", desc = _("scienceDB","Long range narrow beam and some point defense beams, broadside missiles. Agile for a frigate"),},
["Piranha"] = {image = "radar/piranha.png", model = "HeavyCorvetteRed", desc = _("scienceDB","This combat-specialized Piranha F12 adds mine-laying tubes, combat maneuvering systems, and a jump drive."),},
["Flavia P.Falcon"] = {image = "radar/tug.png", model = "LightCorvetteGrey", desc = _("scienceDB","Popular among traders and smugglers, the Flavia is a small cargo and passenger transport. It's cheaper than a freighter for small loads and short distances, and is often used to carry high-value cargo discreetly.\n\nThe Flavia Falcon is a Flavia transport modified for faster flight, and adds rear-mounted lasers to keep enemies off its back.\n\nThe Flavia P.Falcon has a nuclear-capable rear-facing weapon tube and a warp drive."),},
["Repulse"] = {image = "radar/tug.png", model = "LightCorvetteRed", desc = _("scienceDB","A Flavia P. Falcon with better hull and shields, a jump drive, two turreted beams covering both sides and a forward and rear tube. The nukes and mines are gone"),},
["Atlantis"] = {image = "radar/dread.png", model = "battleship_destroyer_1_upgraded", desc = _("scienceDB","A refitted Atlantis X23 for more general tasks. The large shield system has been replaced with an advanced combat maneuvering systems and improved impulse engines. Its missile loadout is also more diverse. Mistaking the modified Atlantis for an Atlantis X23 would be a deadly mistake."),},
["Crucible"] = {image = "radar/laser.png", model = "LaserCorvetteRed", desc = _("scienceDB","A number of missile tubes range around this ship. Beams were deemed lower priority, though they are still present. Stronger defenses than a frigate, but not as strong as the Atlantis"),},
["Maverick"] = {image = "radar/laser.png", model = "LaserCorvetteGreen", desc = _("scienceDB","A number of beams bristle from various points on this gunner. Missiles were deemed lower priority, though they are still present. Stronger defenses than a frigate, but not as strong as the Atlantis"),},
["Benedict"] = {image = "radar/transport.png", model = "transport_4_2", desc = _("scienceDB","Benedict is an improved version of the Jump Carrier"),},
["Kiriya"] = {image = "radar/transport.png", model = "transport_4_2", desc = _("scienceDB","Kiriya is Warp Carrier based on the jump carrier with stronger shields and hull and with minimal armament"),},
["Player Cruiser"] = {image = "radar/cruiser.png", model = "battleship_destroyer_5_upgraded", desc = _("scienceDB","A fairly standard cruiser. Stronger than average beams, weaker than average shields, farther than average jump drive range"),},
["Player Missile Cr."] ={image = "radar/missile_cruiser.png", model = "space_cruiser_4", desc = _("scienceDB","It's all about the missiles for this model. Broadside tubes shoot homing missiles (30!), front, homing, EMP and nuke. Comparatively weak shields, especially in the rear. Sluggish impulse drive."),},
["Ender"] = {image = "radar/battleship.png", model = "Ender Battlecruiser", desc = _("scienceDB","The Ender battle station is a huge ship with many defensive features. It can be docked by smaller ships."),},
["Nautilus"] = {image = "radar/tug.png", model = "space_tug", desc = _("scienceDB","Small mine laying vessel with minimal armament, shields and hull."),},
["Striker"] = {image = "radar/adv_striker.png", model = "dark_fighter_6", desc = _("scienceDB","The Striker is the predecessor to the advanced striker, slow but agile, but does not do an extreme amount of damage, and lacks in shields."),},
["Player Fighter"] = {image = "radar/fighter.png", model = "small_fighter_1", desc = _("scienceDB","One of the first and smallest starfighters ever manufactured. It's a favorite for collectors now. Strong beams, though they are mounted awkwardly. A bit slower than modern starfighters. Stronger hull and shields than today's Hornet."),},
}
ship_yard_db:addEntry(template)
template_db = queryScienceDatabase(ship_yard_key,template)
if template_db ~= nil and template_descriptions[template] ~= nil then
template_db:setLongDescription(template_descriptions[template].desc)
template_db:setModelDataName(template_descriptions[template].model)
template_db:setImage(template_descriptions[template].image)
-- add beam upgrade info
local beam_key = _("scienceDB","Beam Weapons")
template_db:addEntry(beam_key)
local beam_db = queryScienceDatabase(ship_yard_key,template,beam_key)
beam_db:setLongDescription(string.format(_("scienceDB","These are the beam upgrade level progressions for the %s"),template))
beam_db:setModelDataName(template_descriptions[template].model)
beam_db:setImage(template_descriptions[template].image)
for i,beam in ipairs(upgrade_path[template]["beam"]) do
local level_key = string.format(_("scienceDB","Level %2i"),i)
beam_db:addEntry(level_key)
local level_db = queryScienceDatabase(ship_yard_key,template,beam_key,level_key)
level_db:setModelDataName(template_descriptions[template].model)
level_db:setImage(template_descriptions[template].image)
local out = string.format(_("scienceDB","%s beam weapon characteristics."),level_key)
if i ~= #upgrade_path[template]["beam"] then
out = string.format(_("scienceDB","%s An upgrade to level %i would %s."),out,i+1,upgrade_path[template]["beam"][i+1].desc)
end
level_db:setLongDescription(out)
for j,emplacement in ipairs(beam) do
local dir_key = string.format(_("scienceDB","Beam %i Direction"),j)
local arc_rng_key = string.format(_("scienceDB","%i Arc, Range"),j)
local cyc_dmg_key = string.format(_("scienceDB","%i Cycle, Damage"),j)
level_db:setKeyValue(dir_key,string.format(_("scienceDB","%s degrees"),emplacement.dir))
level_db:setKeyValue(arc_rng_key,string.format(_("scienceDB","%s degrees, %.2fu"),emplacement.arc,emplacement.rng/1000))
level_db:setKeyValue(cyc_dmg_key,string.format(_("scienceDB","%.1f seconds, %.1f"),emplacement.cyc,emplacement.dmg))
if emplacement.tar ~= nil then
local tur_key = string.format(_("scienceDB","%i Turret Arc, Turn"),j)
level_db:setKeyValue(tur_key,string.format(_("scienceDB","%s degrees, %.1f"),emplacement.tar,emplacement.trt))
end
end
end
-- add missile upgrade info
local missile_key = _("scienceDB","Missile systems")
template_db:addEntry(missile_key)
local missile_db = queryScienceDatabase(ship_yard_key,template,missile_key)
missile_db:setLongDescription(string.format(_("scienceDB","These are the missile systems level progressions for the %s"),template))
missile_db:setModelDataName(template_descriptions[template].model)
missile_db:setImage(template_descriptions[template].image)
for i,missile in ipairs(upgrade_path[template]["missiles"]) do
local level_key = string.format(_("scienceDB","Level %2i"),i)
missile_db:addEntry(level_key)
local level_db = queryScienceDatabase(ship_yard_key,template,missile_key,level_key)
level_db:setModelDataName(template_descriptions[template].model)
level_db:setImage(template_descriptions[template].image)
local out = string.format(_("scienceDB","%s missile system characteristics.\n S = Small size\n M = Medium size\n L = Large size"),level_key)
if i ~= #upgrade_path[template]["missiles"] then
out = string.format(_("scienceDB","%s\nAn upgrade to level %i would %s."),out,i+1,upgrade_path[template]["missiles"][i+1].desc)
end
level_db:setLongDescription(out)
for j,tub in ipairs(upgrade_path[template]["tube"][missile.tube]) do
local dir_siz_key = string.format(_("scienceDB","Tube %i %i degrees %s"),j,tub.dir,tub.siz)
level_db:setKeyValue(dir_siz_key,string.format(_("scienceDB","%.1f seconds load time"),tub.spd))
local type_count = 0
local type_list = ""
if tub.hom then
type_count = type_count + 1
type_list = _("scienceDB","Homing")
end
if tub.nuk then
type_count = type_count + 1
if type_list == "" then
type_list = _("scienceDB","Nuke")
else
type_list = string.format(_("scienceDB","%s, Nuke"),type_list)
end
end
if tub.emp then
type_count = type_count + 1
if type_list == "" then
type_list = _("scienceDB","EMP")
else
type_list = string.format(_("scienceDB","%s, EMP"),type_list)
end
end
if tub.min then
type_count = type_count + 1
if type_list == "" then
type_list = _("scienceDB","Mine")
else
type_list = string.format(_("scienceDB","%s, Mine"),type_list)
end
end
if tub.hvl then
type_count = type_count + 1
if type_list == "" then
type_list = _("scienceDB","HVLI")
else
type_list = string.format(_("scienceDB","%s, HVLI"),type_list)
end
end
local type_key = string.format(_("scienceDB","Tube %i missile type"),j)
if type_count > 1 then
type_key = string.format(_("scienceDB","Tube %i missile types"),j)
end
level_db:setKeyValue(type_key,type_list)
end
if upgrade_path[template]["ordnance"][missile.ord].hom > 0 then
local homing_key = _("scienceDB","Homing capacity")
level_db:setKeyValue(homing_key,upgrade_path[template]["ordnance"][missile.ord].hom)
end
if upgrade_path[template]["ordnance"][missile.ord].nuk > 0 then
local nuke_key = _("scienceDB","Nuke capacity")
level_db:setKeyValue(nuke_key,upgrade_path[template]["ordnance"][missile.ord].nuk)
end
if upgrade_path[template]["ordnance"][missile.ord].emp > 0 then
local emp_key = _("scienceDB","EMP capacity")
level_db:setKeyValue(emp_key,upgrade_path[template]["ordnance"][missile.ord].emp)
end
if upgrade_path[template]["ordnance"][missile.ord].min > 0 then
local min_key = _("scienceDB","Mine capacity")
level_db:setKeyValue(min_key,upgrade_path[template]["ordnance"][missile.ord].min)
end
if upgrade_path[template]["ordnance"][missile.ord].hvl > 0 then
local hvl_key = _("scienceDB","HVLI capacity")
level_db:setKeyValue(hvl_key,upgrade_path[template]["ordnance"][missile.ord].hvl)
end
end
-- add shield upgrade info
local shield_key = _("scienceDB","Shield system")
template_db:addEntry(shield_key)
local shield_db = queryScienceDatabase(ship_yard_key,template,shield_key)
shield_db:setLongDescription(string.format(_("scienceDB","These are the shield system level progressions for the %s"),template))
shield_db:setModelDataName(template_descriptions[template].model)
shield_db:setImage(template_descriptions[template].image)
for i,shield in ipairs(upgrade_path[template]["shield"]) do
local level_key = string.format(_("scienceDB","Level %2i"),i)
shield_db:addEntry(level_key)
local level_db = queryScienceDatabase(ship_yard_key,template,shield_key,level_key)
level_db:setModelDataName(template_descriptions[template].model)
level_db:setImage(template_descriptions[template].image)
local out = string.format(_("scienceDB","%s shield system characteristics."),level_key)
if i ~= #upgrade_path[template]["shield"] then
out = string.format(_("scienceDB","%s An upgrade to level %i would %s."),out,i+1,upgrade_path[template]["shield"][i+1].desc)
end
level_db:setLongDescription(out)
local shield_arc_key = _("scienceDB","Shield strength")
if #shield == 1 then
level_db:setKeyValue(shield_arc_key,shield[1].max)
else
shield_arc_key = _("scienceDB","Front shield strength")
level_db:setKeyValue(shield_arc_key,shield[1].max)
shield_arc_key = _("scienceDB","Rear shield strength")
level_db:setKeyValue(shield_arc_key,shield[2].max)
end
end
-- add hull upgrade info
local hull_key = _("scienceDB","Hull")
template_db:addEntry(hull_key)
local hull_db = queryScienceDatabase(ship_yard_key,template,hull_key)
hull_db:setLongDescription(string.format(_("scienceDB","These are the hull level progressions for the %s"),template))
hull_db:setModelDataName(template_descriptions[template].model)
hull_db:setImage(template_descriptions[template].image)
for i,hull in ipairs(upgrade_path[template]["hull"]) do
local level_key = string.format(_("scienceDB","Level %2i"),i)
hull_db:addEntry(level_key)
local level_db = queryScienceDatabase(ship_yard_key,template,hull_key,level_key)
level_db:setModelDataName(template_descriptions[template].model)
level_db:setImage(template_descriptions[template].image)
local out = string.format(_("scienceDB","%s hull characteristics."),level_key)
if i ~= #upgrade_path[template]["hull"] then
out = string.format(_("scienceDB","%s An upgrade to level %i would %s."),out,i+1,upgrade_path[template]["hull"][i+1].desc)
end
level_db:setLongDescription(out)
level_db:setKeyValue(_("scienceDB","Hull strength"),hull.max)
end
-- add impulse upgrade info
local impulse_key = _("scienceDB","Impulse systems")
template_db:addEntry(impulse_key)
local impulse_db = queryScienceDatabase(ship_yard_key,template,impulse_key)
impulse_db:setLongDescription(string.format(_("scienceDB","These are the impulse systems level progressions for the %s"),template))
impulse_db:setModelDataName(template_descriptions[template].model)
impulse_db:setImage(template_descriptions[template].image)
for i,impulse in ipairs(upgrade_path[template]["impulse"]) do
local level_key = string.format(_("scienceDB","Level %2i"),i)
impulse_db:addEntry(level_key)
local level_db = queryScienceDatabase(ship_yard_key,template,impulse_key,level_key)
level_db:setModelDataName(template_descriptions[template].model)
level_db:setImage(template_descriptions[template].image)
local out = string.format(_("scienceDB","%s impulse system characteristics."),level_key)
if i ~= #upgrade_path[template]["impulse"] then
out = string.format(_("scienceDB","%s An upgrade to level %i would %s."),out,i+1,upgrade_path[template]["impulse"][i+1].desc)
end
level_db:setLongDescription(out)
level_db:setKeyValue(_("scienceDB","Forward speed"),string.format(_("scienceDB","%.1f units/minute"),impulse.max_front*60/1000))
level_db:setKeyValue(_("scienceDB","Reverse speed"),string.format(_("scienceDB","%.1f units/minute"),impulse.max_back*60/1000))
level_db:setKeyValue(_("scienceDB","Forward acceleration"),impulse.accel_front)
level_db:setKeyValue(_("scienceDB","Reverse acceleration"),impulse.accel_back)
level_db:setKeyValue(_("scienceDB","Turn speed"),string.format(_("scienceDB","%.1f degrees per second"),impulse.turn))
if impulse.boost ~= 0 or impulse.strafe ~= 0 then
level_db:setKeyValue(_("scienceDB","Combat maneuver boost"),string.format(_("scienceDB","%i (forward)"),impulse.boost))
level_db:setKeyValue(_("scienceDB","Combat maneuver strafe"),string.format(_("scienceDB","%i (sideways)"),impulse.strafe))
end
end
-- add ftl upgrade info
local ftl_key = _("scienceDB","FTL system")
template_db:addEntry(ftl_key)
local ftl_db = queryScienceDatabase(ship_yard_key,template,ftl_key)
ftl_db:setLongDescription(string.format(_("scienceDB","These are the Faster Than Light (FTL) drive system level progressions for the %s"),template))
ftl_db:setModelDataName(template_descriptions[template].model)
ftl_db:setImage(template_descriptions[template].image)
for i,ftl in ipairs(upgrade_path[template]["ftl"]) do
local level_key = string.format(_("scienceDB","Level %2i"),i)
ftl_db:addEntry(level_key)
local level_db = queryScienceDatabase(ship_yard_key,template,ftl_key,level_key)
level_db:setModelDataName(template_descriptions[template].model)
level_db:setImage(template_descriptions[template].image)
local out = string.format(_("scienceDB","%s Faster Than Light (FTL) drive system characteristics."),level_key)
if i ~= #upgrade_path[template]["ftl"] then
out = string.format(_("scienceDB","%s An upgrade to level %i would %s."),out,i+1,upgrade_path[template]["ftl"][i+1].desc)
end
level_db:setLongDescription(out)
if ftl.jump_long > 0 then
level_db:setKeyValue(_("scienceDB","Jump drive long range"),string.format(_("scienceDB","%.1f units"),ftl.jump_long/1000))
level_db:setKeyValue(_("scienceDB","Short range"),string.format(_("scienceDB","%.1f units"),ftl.jump_short/1000))
end
if ftl.warp > 0 then
level_db:setKeyValue(_("scienceDB","Warp drive speed"),string.format(_("scienceDB","%.1f units/minute"),ftl.warp*60/1000))
end
if ftl.jump_long == 0 and ftl.warp == 0 then
level_db:setKeyValue(_("scienceDB","FTL state"),_("scienceDB","No jump or warp drive"))
end
end
-- add sensor upgrade info
local sensor_key = _("scienceDB","Sensor system")
template_db:addEntry(sensor_key)
local sensor_db = queryScienceDatabase(ship_yard_key,template,sensor_key)
sensor_db:setLongDescription(string.format(_("scienceDB","These are the sensor system level progressions for the %s"),template))
sensor_db:setModelDataName(template_descriptions[template].model)
sensor_db:setImage(template_descriptions[template].image)
for i,sensor in ipairs(upgrade_path[template]["sensors"]) do
local level_key = string.format(_("scienceDB","Level %2i"),i)
sensor_db:addEntry(level_key)
local level_db = queryScienceDatabase(ship_yard_key,template,sensor_key,level_key)
level_db:setModelDataName(template_descriptions[template].model)
level_db:setImage(template_descriptions[template].image)
local out = string.format(_("scienceDB","%s sensor system characteristics."),level_key)
if i ~= #upgrade_path[template]["sensors"] then
out = string.format(_("scienceDB","%s An upgrade to level %i would %s."),out,i+1,upgrade_path[template]["sensors"][i+1].desc)
end
level_db:setLongDescription(out)
level_db:setKeyValue(_("scienceDB","Short range sensors"),string.format(_("scienceDB","%.1f units (Helm, Weapons)"),sensor.short/1000))
level_db:setKeyValue(_("scienceDB","Long range sensors"),string.format(_("scienceDB","%.1f units (Science)"),sensor.long/1000))
if sensor.prox_scan > 0 then
if sensor.prox_scan <= 1 then
level_db:setKeyValue(_("scienceDB","Automated scan"),string.format(_("scienceDB","Within %.1f unit"),sensor.prox_scan))
else
level_db:setKeyValue(_("scienceDB","Automated scan"),string.format(_("scienceDB","Within %.1f units"),sensor.prox_scan))
end
end
end
end
end
end
function playerShipUpgradeDowngradeData()
if base_upgrade_cost == nil then
base_upgrade_cost = 5
end
upgrade_path = { --one path per player ship
["Atlantis"] = { --10 + beam(7) + missile(10) + shield(9) + hull(8) + impulse(16) + ftl(10) + sensors(10) = 80
["beam"] = {
{ --1
{idx = 0, arc = 60, dir = -20, rng = 1000, cyc = 6, dmg = 6},
{idx = 1, arc = 60, dir = 20, rng = 1000, cyc = 6, dmg = 6},
["downgrade"] = _("downgrade-comms","reduced range by 20%"),
},
{ --2
{idx = 0, arc = 60, dir = -20, rng = 1250, cyc = 6, dmg = 6},
{idx = 1, arc = 60, dir = 20, rng = 1250, cyc = 6, dmg = 6},
["desc"] = _("upgrade-comms","increase range by 25%"),
["downgrade"] = _("downgrade-comms","decreased arc by 25%"),
},
{ --3
{idx = 0, arc = 80, dir = -20, rng = 1250, cyc = 6, dmg = 6},
{idx = 1, arc = 80, dir = 20, rng = 1250, cyc = 6, dmg = 6},
["desc"] = _("upgrade-comms","increase arc by 1/3"),
["downgrade"] = _("downgrade-comms","decreased damage by 25%"),
},
{ --4
{idx = 0, arc = 80, dir = -20, rng = 1250, cyc = 6, dmg = 8},
{idx = 1, arc = 80, dir = 20, rng = 1250, cyc = 6, dmg = 8},
["desc"] = _("upgrade-comms","increase damage by 1/3"),
["downgrade"] = _("downgrade-comms","removed beams"),
},
{ --5
{idx = 0, arc = 80, dir = -20, rng = 1250, cyc = 6, dmg = 8},
{idx = 1, arc = 80, dir = 20, rng = 1250, cyc = 6, dmg = 8},
{idx = 2, arc = 80, dir = -40, rng = 1250, cyc = 6, dmg = 8},
{idx = 3, arc = 80, dir = 40, rng = 1250, cyc = 6, dmg = 8},
["desc"] = _("upgrade-comms","add beams"),
["downgrade"] = _("downgrade-comms","decreased arc by 20%"),
},
{ --6
{idx = 0, arc = 100, dir = -20, rng = 1250, cyc = 6, dmg = 8},
{idx = 1, arc = 100, dir = 20, rng = 1250, cyc = 6, dmg = 8},
{idx = 2, arc = 100, dir = -40, rng = 1250, cyc = 6, dmg = 8},
{idx = 3, arc = 100, dir = 40, rng = 1250, cyc = 6, dmg = 8},
["desc"] = _("upgrade-comms","increase arc by 25%"),
["downgrade"] = _("downgrade-comms","decreased range by ~17%"),
},
{ --7
{idx = 0, arc = 100, dir = -20, rng = 1500, cyc = 6, dmg = 8},
{idx = 1, arc = 100, dir = 20, rng = 1500, cyc = 6, dmg = 8},
{idx = 2, arc = 100, dir = -40, rng = 1500, cyc = 6, dmg = 8},
{idx = 3, arc = 100, dir = 40, rng = 1500, cyc = 6, dmg = 8},
["desc"] = _("upgrade-comms","increase range by 20%"),
["downgrade"] = _("downgrade-comms","increased cycle time by 20%"),
},
{ --8
{idx = 0, arc = 100, dir = -20, rng = 1500, cyc = 5, dmg = 8},
{idx = 1, arc = 100, dir = 20, rng = 1500, cyc = 5, dmg = 8},
{idx = 2, arc = 100, dir = -40, rng = 1500, cyc = 5, dmg = 8},
{idx = 3, arc = 100, dir = 40, rng = 1500, cyc = 5, dmg = 8},
["desc"] = _("upgrade-comms","decrease cycle time by 1/6"),
},
["stock"] = {
{idx = 0, arc = 100, dir = -20, rng = 1500, cyc = 6, dmg = 8},
{idx = 1, arc = 100, dir = 20, rng = 1500, cyc = 6, dmg = 8},
},
["start"] = 5,
},
["missiles"] = {
{tube = 1, ord = 1, downgrade = _("downgrade-comms","decreased missile stock capacity")}, --1
{tube = 1, ord = 2, desc = _("upgrade-comms","increase missile stock capacity"), downgrade = _("downgrade-comms","decreased homing missile capacity")}, --2
{tube = 1, ord = 3, desc = _("upgrade-comms","increase homing missile capacity"), downgrade = _("downgrade-comms","removed mine tube")}, --3
{tube = 2, ord = 4, desc = _("upgrade-comms","add a mine tube"), downgrade = _("downgrade-comms","increased tube load times")}, --4
{tube = 3, ord = 4, desc = _("upgrade-comms","decrease tube load times"), downgrade = _("downgrade-comms","removed mines, EMPs and nukes")}, --5
{tube = 3, ord = 5, desc = _("upgrade-comms","add mines, emps and nukes"), downgrade = _("downgrade-comms","removed two medium sized side tubes")}, --6
{tube = 4, ord = 5, desc = _("upgrade-comms","add two medium sized side tubes"), downgrade = _("downgrade-comms","reduced EMP capacity")}, --7
{tube = 4, ord = 6, desc = _("upgrade-comms","increase EMP capacity"), downgrade = _("downgrade-comms","reduced nuke capacity capacity")}, --8
{tube = 4, ord = 7, desc = _("upgrade-comms","increase nuke capacity"), downgrade = _("downgrade-comms","reduced tube sizes")}, --9
{tube = 5, ord = 7, desc = _("upgrade-comms","increase tube sizes"), downgrade = _("downgrade-comms","reduced mine load speed, removed front tube")}, --10
{tube = 6, ord = 7, desc = _("upgrade-comms","decrease mine load speed, add front tube")}, --11
["start"] = 4,
},
["tube"] = {
{ --1
{idx = 0, dir = -90, siz = "S", spd = 10, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 1, dir = 90, siz = "S", spd = 10, hom = true, nuk = true, emp = true, min = false, hvl = true },
},
{ --2
{idx = 0, dir = -90, siz = "S", spd = 10, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 1, dir = 90, siz = "S", spd = 10, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 2, dir = 180, siz = "M", spd = 10, hom = false, nuk = false, emp = false, min = true, hvl = false},
},
{ --3
{idx = 0, dir = -90, siz = "S", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 1, dir = 90, siz = "S", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 2, dir = 180, siz = "M", spd = 10, hom = false, nuk = false, emp = false, min = true, hvl = false},
},
{ --4
{idx = 0, dir = -90, siz = "S", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 1, dir = 90, siz = "S", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 2, dir = -90, siz = "M", spd = 10, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 3, dir = 90, siz = "M", spd = 10, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 4, dir = 180, siz = "M", spd = 10, hom = false, nuk = false, emp = false, min = true, hvl = false},
},
{ --5
{idx = 0, dir = -90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 1, dir = 90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 2, dir = -90, siz = "L", spd = 10, hom = true, nuk = false, emp = false, min = false, hvl = true },
{idx = 3, dir = 90, siz = "L", spd = 10, hom = true, nuk = false, emp = false, min = false, hvl = true },
{idx = 4, dir = 180, siz = "M", spd = 10, hom = false, nuk = false, emp = false, min = true, hvl = false},
},
{ --6
{idx = 0, dir = 0, siz = "S", spd = 6, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 1, dir = -90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 2, dir = 90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 3, dir = -90, siz = "L", spd = 10, hom = true, nuk = false, emp = false, min = false, hvl = true },
{idx = 4, dir = 90, siz = "L", spd = 10, hom = true, nuk = false, emp = false, min = false, hvl = true },
{idx = 5, dir = 180, siz = "M", spd = 8, hom = false, nuk = false, emp = false, min = true, hvl = false},
},
["stock"] = {
{idx = 0, dir = -90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 1, dir = -90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 2, dir = 90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 3, dir = 90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 4, dir = 180, siz = "M", spd = 8, hom = false, nuk = false, emp = false, min = true, hvl = false},
},
["start"] = 2,
},
["ordnance"] = {
{hom = 4, nuk = 0, emp = 0, min = 0, hvl = 10}, --1
{hom = 6, nuk = 0, emp = 0, min = 0, hvl = 20}, --2
{hom = 12, nuk = 0, emp = 0, min = 0, hvl = 20}, --3
{hom = 12, nuk = 0, emp = 0, min = 4, hvl = 20}, --4
{hom = 12, nuk = 2, emp = 4, min = 8, hvl = 20}, --5
{hom = 12, nuk = 2, emp = 6, min = 8, hvl = 20}, --6
{hom = 12, nuk = 4, emp = 6, min = 8, hvl = 20}, --7
["stock"] = {hom = 12, nuk = 4, emp = 6, min = 8, hvl = 20},
["start"] = 4,
},
["shield"] = {
{ --1
{idx = 0, max = 80},
["downgrade"] = _("downgrade-comms","reduced shield charge capacity by 20%"),
},
{ --2
{idx = 0, max = 100},
["desc"] = _("upgrade-comms","increase shield charge capacity by 25%"),
["downgrade"] = _("downgrade-comms","reduced shield charge capacity by 1/3"),
},
{ --3
{idx = 0, max = 150},
["desc"] = _("upgrade-comms","increase shield charge capacity by 50%"),
["downgrade"] = _("downgrade-comms","removed rear shield arc"),
},
{ --4
{idx = 0, max = 80},
{idx = 1, max = 80},
["desc"] = _("upgrade-comms","add rear shield arc"),
["downgrade"] = _("downgrade-comms","reduced front shield charge capacity by 20%"),
},
{ --5
{idx = 0, max = 100},
{idx = 1, max = 80},
["desc"] = _("upgrade-comms","increase front shield charge capacity by 25%"),
["downgrade"] = _("downgrade-comms","reduced rear shield charge capacity by 20%"),
},
{ --6
{idx = 0, max = 100},
{idx = 1, max = 100},
["desc"] = _("upgrade-comms","increase rear shield charge capacity by 25%"),
["downgrade"] = _("downgrade-comms","reduced shield charge capacity by 1/3"),
},
{ --7
{idx = 0, max = 150},
{idx = 1, max = 150},
["desc"] = _("upgrade-comms","increase shield charge capacity by 50%"),
["downgrade"] = _("downgrade-comms","reduced shield charge capacity by 25%"),
},
{ --8
{idx = 0, max = 200},
{idx = 1, max = 200},
["desc"] = _("upgrade-comms","increase shield charge capacity by 1/3"),
["downgrade"] = _("downgrade-comms","reduced shield charge capacity by ~13%"),
},
{ --9
{idx = 0, max = 230},
{idx = 1, max = 230},
["desc"] = _("upgrade-comms","increase shield charge capacity by 15%"),
["downgrade"] = _("downgrade-comms","reduced shield charge capacity by 8%"),
},
{ --10
{idx = 0, max = 250},
{idx = 1, max = 250},
["desc"] = _("upgrade-comms","increase shield charge capacity by ~13%"),
},
["stock"] = {
{idx = 0, max = 200},
{idx = 1, max = 200},
},
["start"] = 5,
},
["hull"] = {
{max = 100, ["downgrade"] = _("downgrade-comms","decreased hull max by 20%")}, --1
{max = 120, ["desc"] = _("upgrade-comms","increase hull max by 25%"), ["downgrade"] = _("downgrade-comms","decreased hull max by ~14%")}, --2
{max = 140, ["desc"] = _("upgrade-comms","increase hull max by ~17%"), ["downgrade"] = _("downgrade-comms","decreased hull max by ~22%")}, --3
{max = 180, ["desc"] = _("upgrade-comms","increase hull max by ~29%"), ["downgrade"] = _("downgrade-comms","decreased hull max by 10%")}, --4
{max = 200, ["desc"] = _("upgrade-comms","increase hull max by ~11%"), ["downgrade"] = _("downgrade-comms","decreased hull max by 20%")}, --5
{max = 250, ["desc"] = _("upgrade-comms","increase hull max by 25%"), ["downgrade"] = _("downgrade-comms","decreased hull max by ~17%")}, --6
{max = 300, ["desc"] = _("upgrade-comms","increase hull max by 20%")}, --7
["stock"] = {max = 250},
["start"] = 3,
},
["impulse"] = {
{ --1
max_front = 70, max_back = 70,
accel_front = 20, accel_back = 20,
turn = 10,
boost = 0, strafe = 0,
downgrade = _("downgrade-comms","reduced max forward impulse speed by 12.5%"),
},
{ --2
max_front = 80, max_back = 70,
accel_front = 20, accel_back = 20,
turn = 10,
boost = 0, strafe = 0,
desc = _("upgrade-comms","increase max forward impulse speed by ~14%"),
downgrade = _("downgrade-comms","removed combat maneuver"),
},
{ --3
max_front = 80, max_back = 70,
accel_front = 20, accel_back = 20,
turn = 10,
boost = 200, strafe = 0,
desc = _("upgrade-comms","add combat maneuver forward boost"),
downgrade = _("downgrade-comms","decreased max reverse impulse speed by 12.5%"),
},
{ --4
max_front = 80, max_back = 80,
accel_front = 20, accel_back = 20,
turn = 10,
boost = 200, strafe = 0,
desc = _("upgrade-comms","increase max reverse impulse speed by ~14%"),
downgrade = _("downgrade-comms","removed combat maneuver strafe"),
},
{ --5
max_front = 80, max_back = 80,
accel_front = 20, accel_back = 20,
turn = 10,
boost = 200, strafe = 125,
desc = _("upgrade-comms","add combat maneuver strafe"),
downgrade = _("downgrade-comms","decreased maneuverability by ~17%"),
},
{ --6
max_front = 80, max_back = 80,
accel_front = 20, accel_back = 20,
turn = 12,
boost = 200, strafe = 125,
desc = _("upgrade-comms","increase maneuverability by 20%"),
downgrade = _("downgrade-comms","decreased max forward impulse speed by ~11%"),
},
{ --7
max_front = 90, max_back = 80,
accel_front = 20, accel_back = 20,
turn = 12,
boost = 200, strafe = 125,
desc = _("upgrade-comms","increase max forward impulse speed by 12.5%"),
downgrade = _("downgrade-comms","decreased combat maneuver forward boost by 1/3"),
},
{ --8
max_front = 90, max_back = 80,
accel_front = 20, accel_back = 20,
turn = 12,
boost = 300, strafe = 125,
desc = _("upgrade-comms","increase combat maneuver forward boost by 50%"),
downgrade = _("downgrade-comms","decreased impulse forward acceleration by 20%"),
},
{ --9
max_front = 90, max_back = 80,
accel_front = 25, accel_back = 20,
turn = 12,
boost = 300, strafe = 125,
desc = _("upgrade-comms","increase impulse forward acceleration by 25%"),
downgrade = _("downgrade-comms","decreased combat maneuver strafe by 37.5%"),
},
{ --10
max_front = 90, max_back = 80,
accel_front = 25, accel_back = 20,
turn = 12,
boost = 300, strafe = 200,
desc = _("upgrade-comms","increase combat maneuver strafe by 60%"),
downgrade = _("downgrade-comms","decreased maneuverability by 20%"),
},
{ --11
max_front = 90, max_back = 80,
accel_front = 25, accel_back = 20,
turn = 15,
boost = 300, strafe = 200,
desc = _("upgrade-comms","increase maneuverability by 25%"),
downgrade = _("downgrade-comms","decreased combat maneuver forward boost by 25%"),
},
{ --12
max_front = 90, max_back = 80,
accel_front = 25, accel_back = 20,
turn = 15,
boost = 400, strafe = 200,
desc = _("upgrade-comms","increase combat maneuver forward boost by 1/3"),
downgrade = _("downgrade-comms","decreased max forward impulse speed by 10%"),
},
{ --13
max_front = 100, max_back = 80,
accel_front = 25, accel_back = 20,
turn = 15,
boost = 400, strafe = 200,
desc = _("upgrade-comms","increase max forward impulse speed by ~11%"),
downgrade = _("downgrade-comms","decreased combat maneuver strafe by 20%"),
},
{ --14
max_front = 100, max_back = 80,
accel_front = 25, accel_back = 20,
turn = 15,
boost = 400, strafe = 250,
desc = _("upgrade-comms","increase combat maneuver strafe by 25%"),
downgrade = _("downgrade-comms","decreased max reverse impulse speed by ~11%"),
},
{ --14
max_front = 100, max_back = 90,
accel_front = 25, accel_back = 20,
turn = 15,
boost = 400, strafe = 250,
desc = _("upgrade-comms","increase max reverse impulse speed by 12.5%"),
downgrade = _("downgrade-comms","decreased forward acceleration by ~17%"),
},
{ --15
max_front = 100, max_back = 90,
accel_front = 30, accel_back = 20,
turn = 15,
boost = 400, strafe = 250,
desc = _("upgrade-comms","increase impulse forward acceleration by 20%"),
downgrade = _("downgrade-comms","decreased combat maneuver strafe by ~17%"),
},
{ --16
max_front = 100, max_back = 90,
accel_front = 30, accel_back = 20,
turn = 15,
boost = 400, strafe = 300,
desc = _("upgrade-comms","increase combat maneuver strafe by 20%"),
downgrade = _("downgrade-comms","decreased maneuverability by 25%"),
},
{ --17
max_front = 100, max_back = 90,
accel_front = 30, accel_back = 20,
turn = 20,
boost = 400, strafe = 300,
desc = _("upgrade-comms","increase maneuverability by 1/3"),
},
["stock"] = {
{max_front = 90, turn = 10, accel_front = 20, max_back = 90, accel_back = 20, boost = 400, strafe = 250},
},
["start"] = 5,
},
["ftl"] = {
{ --1
jump_long = 0, jump_short = 0, warp = 0,
downgrade = _("downgrade-comms","removed jump drive"),
},
{ --2
jump_long = 20000, jump_short = 2000, warp = 0,
desc = _("upgrade-comms","add 20u jump drive"),
downgrade = _("downgrade-comms","reduced jump range by 20%"),
},
{ --3
jump_long = 25000, jump_short = 2500, warp = 0,
desc = _("upgrade-comms","increase jump range by 25%"),
downgrade = _("downgrade-comms","reduced jump range by ~17%"),
},
{ --4
jump_long = 30000, jump_short = 3000, warp = 0,
desc = _("upgrade-comms","increase jump range by 20%"),
downgrade = _("downgrade-comms","reduced jump range by 25%"),
},
{ --5
jump_long = 40000, jump_short = 4000, warp = 0,
desc = _("upgrade-comms","increase jump range by 1/3"),
downgrade = _("downgrade-comms","reduced jump range by 20%"),
},
{ --6
jump_long = 50000, jump_short = 5000, warp = 0,
desc = _("upgrade-comms","increase jump range by 25%"),
downgrade = _("downgrade-comms","reduced jump range by ~9%"),
},
{ --7
jump_long = 55000, jump_short = 5500, warp = 0,
desc = _("upgrade-comms","increase jump range by 10%"),
downgrade = _("downgrade-comms","removed warp drive"),
},
{ --8
jump_long = 55000, jump_short = 5500, warp = 400,
desc = _("upgrade-comms","add warp drive"),
downgrade = _("downgrade-comms","reduced warp speed by 20%"),
},
{ --9
jump_long = 55000, jump_short = 5500, warp = 500,
desc = _("upgrade-comms","increase warp speed by 25%"),
downgrade = _("downgrade-comms","reduced jump range by ~8%"),
},
{ --10
jump_long = 60000, jump_short = 6000, warp = 500,
desc = _("upgrade-comms","increase jump range by ~9%"),
downgrade = _("downgrade-comms","reduced warp speed by ~17%"),
},
{ --11
jump_long = 60000, jump_short = 6000, warp = 600,
desc = _("upgrade-comms","increase warp speed by 20%"),
},
["stock"] = {
{jump_long = 50000, jump_short = 5000, warp = 0},
},
["start"] = 4
},
["sensors"] = {
{ --1
short = 4000, long = 15000, prox_scan = 0,
downgrade = _("downgrade-comms","reduced long range sensors by 25%"),
},
{ --2
short = 4000, long = 20000, prox_scan = 0,
desc = _("upgrade-comms","increase long range sensors by 1/3"),
downgrade = _("downgrade-comms","removed automated proximity scanner"),
},
{ --3
short = 4000, long = 20000, prox_scan = 2,
desc = _("upgrade-comms","add 2 unit automated proximity scanner"),
downgrade = _("downgrade-comms","reduced long range sensors by ~9%"),
},
{ --4
short = 4000, long = 22000, prox_scan = 2,
desc = _("upgrade-comms","increase long range sensors by 10%"),
downgrade = _("downgrade-comms","reduced short range sensors by ~11%"),
},
{ --5
short = 4500, long = 22000, prox_scan = 2,
desc = _("upgrade-comms","increase short range sensors by 12.5%"),
downgrade = _("downgrade-comms","reduced long range sensors by 12%"),
},
{ --6
short = 4500, long = 25000, prox_scan = 2,
desc = _("upgrade-comms","increase long range sensors by ~14%"),
downgrade = _("downgrade-comms","reduced long range sensors by ~17%"),
},
{ --7
short = 4500, long = 30000, prox_scan = 2,
desc = _("upgrade-comms","increase long range sensors by 20%"),
downgrade = _("downgrade-comms","reduced short range sensors by 10%"),
},
{ --8
short = 5000, long = 30000, prox_scan = 2,
desc = _("upgrade-comms","increase short range sensors by ~11%"),
downgrade = _("downgrade-comms","reduced long range sensors by ~14%"),
},
{ --9
short = 5000, long = 35000, prox_scan = 2,
desc = _("upgrade-comms","increase long range sensors by ~17%"),
downgrade = _("downgrade-comms","reduced long range sensors by 12.5%"),
},
{ --10
short = 5000, long = 40000, prox_scan = 2,
desc = _("upgrade-comms","increase long range sensors by ~14%"),
downgrade = _("downgrade-comms","reduced automated proximity scanner by 1/3"),
},
{ --11
short = 5000, long = 40000, prox_scan = 3,
desc = _("upgrade-comms","increase automated proximity scanner by 50%"),
},
["stock"] = {
{short = 5000, long = 30000}, prox_scan = 0,
},
["start"] = 4,
},
["providers"] = false,
["score"] = 33,
},
["Crucible"] = { --9 + beam(7) + missile(10) + shield(9) + hull(6) + impulse(17) + ftl(10) + sensors(11) = 79
["beam"] = {
{ --1
{idx = 0, arc = 60, dir = -20, rng = 900, cyc = 7, dmg = 4},
{idx = 1, arc = 60, dir = 20, rng = 900, cyc = 7, dmg = 4},
["downgrade"] = _("downgrade-comms","reduced range by ~5%"),
},
{ --2
{idx = 0, arc = 60, dir = -20, rng = 950, cyc = 7, dmg = 4},
{idx = 1, arc = 60, dir = 20, rng = 950, cyc = 7, dmg = 4},
["desc"] = _("upgrade-comms","increase range by ~6%"),
["downgrade"] = _("downgrade-comms","increased cycle time by by ~8%"),
},
{ --3
{idx = 0, arc = 60, dir = -20, rng = 950, cyc = 6.5, dmg = 4},
{idx = 1, arc = 60, dir = 20, rng = 950, cyc = 6.5, dmg = 4},
["desc"] = _("upgrade-comms","decrease cycle time by ~7%"),
["downgrade"] = _("downgrade-comms","decreased damage by 20%"),
},
{ --4
{idx = 0, arc = 60, dir = -20, rng = 950, cyc = 6.5, dmg = 5},
{idx = 1, arc = 60, dir = 20, rng = 950, cyc = 6.5, dmg = 5},
["desc"] = _("upgrade-comms","increase damage by 25%"),
["downgrade"] = _("downgrade-comms","decreased range by 5%"),
},
{ --5
{idx = 0, arc = 60, dir = -20, rng = 1000, cyc = 6.5, dmg = 5},
{idx = 1, arc = 60, dir = 20, rng = 1000, cyc = 6.5, dmg = 5},
["desc"] = _("upgrade-comms","increase range by ~5%"),
["downgrade"] = _("downgrade-comms","increased cycle time by ~8%"),
},
{ --6
{idx = 0, arc = 60, dir = -20, rng = 1000, cyc = 6, dmg = 5},
{idx = 1, arc = 60, dir = 20, rng = 1000, cyc = 6, dmg = 5},
["desc"] = _("upgrade-comms","decrease cycle time by 8%"),
["downgrade"] = _("downgrade-comms","decreased range by ~9%"),
},
{ --7
{idx = 0, arc = 60, dir = -20, rng = 1100, cyc = 6, dmg = 5},
{idx = 1, arc = 60, dir = 20, rng = 1100, cyc = 6, dmg = 5},
["desc"] = _("upgrade-comms","increase range by 10%"),
["downgrade"] = _("downgrade-comms","decreased damage by ~17%"),
},
{ --8
{idx = 0, arc = 60, dir = -20, rng = 1100, cyc = 6, dmg = 6},
{idx = 1, arc = 60, dir = 20, rng = 1100, cyc = 6, dmg = 6},
["desc"] = _("upgrade-comms","increase damage by 20%"),
},
["stock"] = {
{idx = 0, arc = 70, dir = -30, rng = 1000, cyc = 6, dmg = 5},
{idx = 1, arc = 70, dir = 30, rng = 1000, cyc = 6, dmg = 5},
},
["start"] = 3
},
["missiles"] = {
{tube = 1, ord = 1, downgrade = _("downgrade-comms","removed medium tube")}, --1
{tube = 2, ord = 1, desc = _("upgrade-comms","add medium tube"), downgrade = _("downgrade-comms","reduced HVLI missile capacity")}, --2
{tube = 2, ord = 2, desc = _("upgrade-comms","increase HVLI missile capacity"), downgrade = _("downgrade-comms","removed large tube and reduced HVLI capacity")}, --3
{tube = 3, ord = 3, desc = _("upgrade-comms","add large tube and increase HVLI capacity"), downgrade = _("downgrade-comms","increased tube load times")}, --4
{tube = 4, ord = 3, desc = _("upgrade-comms","decrease tube load times"), downgrade = _("downgrade-comms","removed broadside tubes and homing missiles")}, --5
{tube = 5, ord = 4, desc = _("upgrade-comms","add broadside tubes and homing missiles"), downgrade = _("downgrade-comms","removed mining tube")}, --6
{tube = 6, ord = 5, desc = _("upgrade-comms","add mining tube"), downgrade = _("downgrade-comms","removed nukes and EMPs from broadside tubes")}, --7
{tube = 7, ord = 6, desc = _("upgrade-comms","add nukes and EMPs to broadside tubes"), downgrade = _("downgrade-comms","decreased heavy missile capacity")}, --8
{tube = 7, ord = 7, desc = _("upgrade-comms","increase heavy missile capacity"), downgrade = _("downgrade-comms","increased tube load times")}, --9
{tube = 8, ord = 7, desc = _("upgrade-comms","decrease tube load times"), downgrade = _("downgrade-comms","decreased missile capacity")}, --10
{tube = 8, ord = 8, desc = _("upgrade-comms","increase missile capacity")}, --11
["start"] = 4,
},
["tube"] = {
{ --1
{idx = 0, dir = 0, siz = "S", spd = 10, hom = false, nuk = false, emp = false, min = false, hvl = true },
},
{ --2
{idx = 0, dir = 0, siz = "S", spd = 10, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 1, dir = 0, siz = "M", spd = 12, hom = false, nuk = false, emp = false, min = false, hvl = true },
},
{ --3
{idx = 0, dir = 0, siz = "S", spd = 10, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 1, dir = 0, siz = "M", spd = 12, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 2, dir = 0, siz = "L", spd = 14, hom = false, nuk = false, emp = false, min = false, hvl = true },
},
{ --4
{idx = 0, dir = 0, siz = "S", spd = 8, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 1, dir = 0, siz = "M", spd = 10, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 2, dir = 0, siz = "L", spd = 12, hom = false, nuk = false, emp = false, min = false, hvl = true },
},
{ --5
{idx = 0, dir = 0, siz = "S", spd = 8, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 1, dir = 0, siz = "M", spd = 10, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 2, dir = 0, siz = "L", spd = 12, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 3, dir = -90, siz = "M", spd = 10, hom = true, nuk = false, emp = false, min = false, hvl = true },
{idx = 4, dir = 90, siz = "M", spd = 10, hom = true, nuk = false, emp = false, min = false, hvl = true },
},
{ --6
{idx = 0, dir = 0, siz = "S", spd = 8, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 1, dir = 0, siz = "M", spd = 10, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 2, dir = 0, siz = "L", spd = 12, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 3, dir = -90, siz = "M", spd = 10, hom = true, nuk = false, emp = false, min = false, hvl = true },
{idx = 4, dir = 90, siz = "M", spd = 10, hom = true, nuk = false, emp = false, min = false, hvl = true },
{idx = 5, dir = 180, siz = "M", spd = 10, hom = false, nuk = false, emp = false, min = true, hvl = false},
},
{ --7
{idx = 0, dir = 0, siz = "S", spd = 8, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 1, dir = 0, siz = "M", spd = 10, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 2, dir = 0, siz = "L", spd = 12, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 3, dir = -90, siz = "M", spd = 10, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 4, dir = 90, siz = "M", spd = 10, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 5, dir = 180, siz = "M", spd = 10, hom = false, nuk = false, emp = false, min = true, hvl = false},
},
{ --8
{idx = 0, dir = 0, siz = "S", spd = 6, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 1, dir = 0, siz = "M", spd = 8, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 2, dir = 0, siz = "L", spd = 10, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 3, dir = -90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 4, dir = 90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 5, dir = 180, siz = "M", spd = 8, hom = false, nuk = false, emp = false, min = true, hvl = false},
},
["stock"] = {
{idx = 0, dir = 0, siz = "S", spd = 8, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 1, dir = 0, siz = "M", spd = 8, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 2, dir = 0, siz = "L", spd = 8, hom = false, nuk = false, emp = false, min = false, hvl = true },
{idx = 3, dir = -90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 4, dir = 90, siz = "M", spd = 8, hom = true, nuk = true, emp = true, min = false, hvl = true },
{idx = 5, dir = 180, siz = "M", spd = 8, hom = false, nuk = false, emp = false, min = true, hvl = false},
},
},
["ordnance"] = {
{hom = 0, nuk = 0, emp = 0, min = 0, hvl = 12}, --1
{hom = 0, nuk = 0, emp = 0, min = 0, hvl = 18}, --2
{hom = 0, nuk = 0, emp = 0, min = 0, hvl = 24}, --3
{hom = 6, nuk = 0, emp = 0, min = 0, hvl = 24}, --4
{hom = 6, nuk = 0, emp = 0, min = 4, hvl = 24}, --5
{hom = 8, nuk = 2, emp = 4, min = 4, hvl = 24}, --6
{hom = 8, nuk = 4, emp = 6, min = 6, hvl = 24}, --7
{hom = 12, nuk = 6, emp = 9, min = 8, hvl = 30}, --8
["stock"] = {hom = 8, nuk = 4, emp = 6, min = 6, hvl = 24},
},
["shield"] = {
{ --1
{idx = 0, max = 80},
["downgrade"] = _("downgrade-comms","decreased shield charge capacity by 20%"),
},
{ --2
{idx = 0, max = 100},
["desc"] = _("upgrade-comms","increase shield charge capacity by 25%"),
["downgrade"] = _("downgrade-comms","decreased shield charge capacity by ~17%"),
},
{ --3
{idx = 0, max = 120},
["desc"] = _("upgrade-comms","increase shield charge capacity by 20%"),
["downgrade"] = _("downgrade-comms","removed rear shield arc"),
},
{ --4
{idx = 0, max = 60},
{idx = 1, max = 60},
["desc"] = _("upgrade-comms","add rear shield arc"),
["downgrade"] = _("downgrade-comms","decreased front shield charge capacity by 25%"),
},
{ --5
{idx = 0, max = 80},
{idx = 1, max = 60},
["desc"] = _("upgrade-comms","increase front shield charge capacity by 1/3"),
["downgrade"] = _("downgrade-comms","decreased rear shield charge capacity by 25%"),
},
{ --6
{idx = 0, max = 80},
{idx = 1, max = 80},
["desc"] = _("upgrade-comms","increase rear shield charge capacity by 1/3"),
["downgrade"] = _("downgrade-comms","decreased shield charge capacity by 20%"),
},
{ --7
{idx = 0, max = 100},
{idx = 1, max = 100},
["desc"] = _("upgrade-comms","increase shield charge capacity by 25%"),
["downgrade"] = _("downgrade-comms","decreased shield charge capacity by 1/3"),
},
{ --8
{idx = 0, max = 150},
{idx = 1, max = 150},
["desc"] = _("upgrade-comms","increase shield charge capacity by 50%"),
["downgrade"] = _("downgrade-comms","decreased shield charge capacity by ~17%"),
},
{ --9
{idx = 0, max = 180},
{idx = 1, max = 180},
["desc"] = _("upgrade-comms","increase shield charge capacity by 20%"),
["downgrade"] = _("downgrade-comms","decreased shield charge capacity by 10%"),
},
{ --10
{idx = 0, max = 200},
{idx = 1, max = 200},
["desc"] = _("upgrade-comms","increase shield charge capacity by ~11%"),
},
["stock"] = {
{idx = 0, max = 160},
{idx = 1, max = 160},
},
["start"] = 5,
},
["hull"] = {
{max = 100, downgrade = _("downgrade-comms","decreased hull max by ~17%")}, --1
{max = 120, ["desc"] = _("upgrade-comms","increase hull max by 20%"), downgrade = _("downgrade-comms","decreased hull max by 1/7")}, --2
{max = 140, ["desc"] = _("upgrade-comms","increase hull max by ~17%"), downgrade = _("downgrade-comms","decreased hull max by 1/8")}, --3
{max = 160, ["desc"] = _("upgrade-comms","increase hull max by ~14%"), downgrade = _("downgrade-comms","decreased hull max by 1/9")}, --4
{max = 180, ["desc"] = _("upgrade-comms","increase hull max by 12.5%"), downgrade = _("downgrade-comms","decreased hull max by 10%")}, --5
{max = 200, ["desc"] = _("upgrade-comms","increase hull max by ~11%"), downgrade = _("downgrade-comms","decreased hull max by 1/11")}, --6
{max = 220, ["desc"] = _("upgrade-comms","increase hull max by 10%")}, --7
["stock"] = {max = 160},
["start"] = 3,
},
["impulse"] = {
{ --1
max_front = 70, max_back = 70,
accel_front = 25, accel_back = 25,
turn = 15,
boost = 0, strafe = 0,
downgrade = _("downgrade-comms","decreased max forward impulse speed by ~7%"),
},
{ --2
max_front = 75, max_back = 70,
accel_front = 25, accel_back = 25,
turn = 15,
boost = 0, strafe = 0,
desc = _("upgrade-comms","increase max forward impulse speed by ~7%"),
downgrade = _("downgrade-comms","removed combat maneuver forward boost"),
},
{ --3
max_front = 75, max_back = 70,
accel_front = 25, accel_back = 25,
turn = 15,
boost = 200, strafe = 0,