-
Notifications
You must be signed in to change notification settings - Fork 0
/
dev.json
2576 lines (2576 loc) · 588 KB
/
dev.json
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
{
"name": "EDDI Russian dev",
"description": "Russian translated personality",
"scripts": {
"AFMU repairs": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{event.item} \r\n\r\n{set declension to [\" процент\", \" процента\", \" процентов\"]}\r\n{set key to 0}\r\n{set number to event.health * 100}\r\n\r\n{F(\"Russian declension\")}\r\n\r\n\r\n{if event.repairedfully: полностью отремонтирован\r\n|else:\r\n частично отремонтирован \r\n {Occasionally(2, cat(\r\n OneOf(\"до \", \"на \"),\r\n Humanise(event.health * 100),\r\n declension[key]\r\n ))}\r\n\r\n}\r\n\r\n{Occasionally(2, \r\n cat(\"и готов к повторной активации\")\r\n)}.",
"name": "AFMU repairs",
"description": "Triggered when repairing modules using the Auto Field Maintenance Unit (AFMU)",
"default": false,
"defaultValue": "{event.item} \r\n{if event.repairedfully:\r\n fully repaired\r\n|else:\r\n partially repaired \r\n {Occasionally(2, cat(\r\n OneOf(\"to \", \"at \"),\r\n Humanise(event.health * 100),\r\n \" percent functionality\"\r\n ))}\r\n}\r\n\r\n{Occasionally(2, \r\n cat(OneOf(\", \", \"and is\"), \" ready for re-activation\")\r\n)}."
},
"Asteroid cracked": {
"enabled": true,
"priority": 3,
"responder": true,
"script": null,
"name": "Asteroid cracked",
"description": "Triggered when you break up a 'Motherlode' asteroid for mining",
"default": true,
"defaultValue": null
},
"Asteroid prospected": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{set minimumPercent to 10} {_ The minimum percentage surface mineral concentration to report _}\r\n{set spokenCores to [\r\n \"Alexandrite\": false,\r\n \"Benitoite\": false,\r\n \"Grandidierite\": false,\r\n \"Low Temperature Diamonds\": true,\r\n \"Monazite\": false,\r\n \"Musgravite\": false,\r\n \"Rhodplumsite\": false,\r\n \"Serendibite\": false,\r\n \"Void Opals\": true,\r\n]}\r\n{set spokenMinerals to [\r\n \"Bauxite\": false,\r\n \"Bertrandite\": false,\r\n \"Bromellite\": false,\r\n \"Cobalt\": false,\r\n \"Coltan\": false,\r\n \"Cryolite\": false,\r\n \"Gallite\": false,\r\n \"Gold\": false,\r\n \"Goslarite\": false,\r\n \"Hydrogen Peroxide\": false,\r\n \"Indite\": false,\r\n \"Jadeite\": false,\r\n \"Lepidolite\": false,\r\n \"Lithium Hydroxide\": false,\r\n \"Liquid oxygen\": false,\r\n \"Low Temperature Diamonds\": true,\r\n \"Methane Clathrate\": false,\r\n \"Methanol Monohydrate\": false,\r\n \"Moissanite\": false,\r\n \"Osmium\": false,\r\n \"Painite\": true,\r\n \"Platinum\": false,\r\n \"Palladium\": false,\r\n \"Praseodymium\": false,\r\n \"Pyrophyllite\": false,\r\n \"Rutile\": false,\r\n \"Samarium\": false,\r\n \"Silver\": false,\r\n \"Taaffeite\": false,\r\n \"Thorium\": false,\r\n \"Tritium\": true,\r\n \"Uraninite\": false,\r\n \"Water\": false,\r\n]}\r\n\r\n{set declension to [\" процент\", \" процента\", \" процентов\"]}\r\n{set key to 0}\r\n\r\n\r\n{if len(event.motherlode) > 0 && spokenCores[event.motherlode]:\r\n Обнаружено месторождение: {event.motherlode}.\r\n}\r\n\r\n{set minerals to []}\r\n{for mineral in event.commodities:\r\n {if mineral.percentage > minimumPercent && spokenMinerals[mineral.commodity]:\r\n \t{set number to round(mineral.percentage)}\r\n\t\t{F(\"Russian declension\")}\r\n\t\t\r\n {set mineral_desc to: \r\n {round(mineral.percentage)} {declension[key]} {mineral.commodity}\r\n }\r\n {set minerals to cat(minerals, [mineral_desc])}\r\n }\r\n}\r\n{if len(minerals) > 0:\r\n Астероид содержит {List(minerals)}\r\n {if event.materialcontent = \"High\":\r\n и высокую концентрацию инженерных материалов\r\n }.\r\n {if event.remaining < 100:\r\n {set number to 100 - event.remaining}\r\n\t\t{F(\"Russian declension\")}\r\n\t\t\r\n Он истощён на {100 - event.remaining} {declension[key]}.\r\n }\r\n}",
"name": "Asteroid prospected",
"description": "Triggered when using a prospecting drone",
"default": false,
"defaultValue": "{set minimumPercent to 10} {_ The minimum percentage surface mineral concentration to report _}\r\n{set spokenCores to [\r\n \"Alexandrite\": false,\r\n \"Benitoite\": false,\r\n \"Grandidierite\": false,\r\n \"Low Temperature Diamonds\": true,\r\n \"Monazite\": false,\r\n \"Musgravite\": false,\r\n \"Rhodplumsite\": false,\r\n \"Serendibite\": false,\r\n \"Void Opals\": true,\r\n]}\r\n{set spokenMinerals to [\r\n \"Bauxite\": false,\r\n \"Bertrandite\": false,\r\n \"Bromellite\": false,\r\n \"Cobalt\": false,\r\n \"Coltan\": false,\r\n \"Cryolite\": false,\r\n \"Gallite\": false,\r\n \"Gold\": false,\r\n \"Goslarite\": false,\r\n \"Hydrogen Peroxide\": false,\r\n \"Indite\": false,\r\n \"Jadeite\": false,\r\n \"Lepidolite\": false,\r\n \"Lithium Hydroxide\": false,\r\n \"Liquid oxygen\": false,\r\n \"Low Temperature Diamonds\": true,\r\n \"Methane Clathrate\": false,\r\n \"Methanol Monohydrate\": false,\r\n \"Moissanite\": false,\r\n \"Osmium\": false,\r\n \"Painite\": true,\r\n \"Platinum\": false,\r\n \"Palladium\": false,\r\n \"Praseodymium\": false,\r\n \"Pyrophyllite\": false,\r\n \"Rutile\": false,\r\n \"Samarium\": false,\r\n \"Silver\": false,\r\n \"Taaffeite\": false,\r\n \"Thorium\": false,\r\n \"Tritium\": true,\r\n \"Uraninite\": false,\r\n \"Water\": false,\r\n]}\r\n\r\n{if len(event.motherlode) > 0 && spokenCores[event.motherlode]:\r\n Motherlode detected: {event.motherlode}.\r\n}\r\n\r\n{set minerals to []}\r\n{for mineral in event.commodities:\r\n {if mineral.percentage > minimumPercent && spokenMinerals[mineral.commodity]:\r\n {set mineral_desc to: \r\n {round(mineral.percentage)} percent {mineral.commodity}\r\n }\r\n {set minerals to cat(minerals, [mineral_desc])}\r\n }\r\n}\r\n{if len(minerals) > 0:\r\n Asteroid contains {List(minerals)}\r\n {if event.materialcontent = \"High\":\r\n and a high concentration of engineering materials\r\n }.\r\n {if event.remaining < 100:\r\n It is {100 - event.remaining} percent depleted.\r\n }\r\n}"
},
"Blueprint make report": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Fetch from context / state _}\r\n{set blueprintname to state.blueprint}\r\n{set blueprintgrade to state.blueprintgrade}\r\n\r\n{_ declension russian variable _}\r\n{set declension to [\" раз\", \" раза\", \" раз\"]}\r\n{set key to 0}\r\n\r\n{if blueprintname && blueprintgrade:\r\n {_ Fetch full blueprint details }\r\n {set blueprint to BlueprintDetails(blueprintname, blueprintgrade)}\r\n\r\n {_ Context }\r\n {SetState('eddi_context_last_subject', 'blueprint')}\r\n {SetState('eddi_context_blueprint_name', blueprintname)}\r\n {SetState('eddi_context_blueprint_grade', blueprintgrade)}\r\n}\r\n\r\n{if !blueprint:\r\n {_ Fetch from context }\r\n {set blueprint to BlueprintDetails(state.eddi_context_blueprint_name, state.eddi_context_blueprint_grade)}\r\n}\r\n\r\n{_ Function to obtain current inventory of a material}\r\n{set _inventory(required) to:\r\n {for material in materials:\r\n {if material.material = required:\r\n {return material}\r\n }\r\n }\r\n}\r\n\r\n{set canbemade to 999}\r\n\r\n{if blueprint:\r\n {_ Find the smallest number of this blueprint that can be made }\r\n \r\n {set cur to 0}\r\n {while cur < len(blueprint.materials):\r\n {set inventory to _inventory(blueprint.materials[cur].material)}\r\n {if !inventory:\r\n {set canbemade to 0}\r\n |else:\r\n {if inventory.amount < canbemade:\r\n {set canbemade to inventory.amount}\r\n }\r\n }\r\n {set cur to cur + 1}\r\n }\r\n\r\n\t{set number to canbemade}\r\n\t{F(\"Russian declension\")}\r\n\t\r\n {if canbemade = 0:\r\n Вы не можете создать {blueprintname} класса {blueprintgrade}\r\n |elif canbemade = 1:\r\n Вы можете создать один {blueprintname} класса {blueprintgrade}\r\n |else:\r\n Вы можете создать {blueprintname} класса {blueprintgrade} {Humanise(canbemade)} {declension[key]}.\r\n }\r\n \r\n|else:\r\n Нет информации о материалах, необходимых для {blueprintname} класс {blueprintgrade}\r\n}.\r\n",
"name": "Blueprint make report",
"description": "Report on how many of a particular blueprint we can make",
"default": false,
"defaultValue": "{_ Fetch from context / state _}\r\n{set blueprintname to state.blueprint}\r\n{set blueprintgrade to state.blueprintgrade}\r\n\r\n{if blueprintname && blueprintgrade:\r\n {_ Fetch full blueprint details }\r\n {set blueprint to BlueprintDetails(blueprintname, blueprintgrade)}\r\n\r\n {_ Context }\r\n {SetState('eddi_context_last_subject', 'blueprint')}\r\n {SetState('eddi_context_blueprint_name', blueprintname)}\r\n {SetState('eddi_context_blueprint_grade', blueprintgrade)}\r\n}\r\n\r\n{if !blueprint:\r\n {_ Fetch from context }\r\n {set blueprint to BlueprintDetails(state.eddi_context_blueprint_name, state.eddi_context_blueprint_grade)}\r\n}\r\n\r\n{_ Function to obtain current inventory of a material}\r\n{set _inventory(required) to:\r\n {for material in materials:\r\n {if material.material = required:\r\n {return material}\r\n }\r\n }\r\n}\r\n\r\n{set canbemade to 999}\r\n\r\n{if blueprint:\r\n {_ Find the smallest number of this blueprint that can be made }\r\n \r\n {set cur to 0}\r\n {while cur < len(blueprint.materials):\r\n {set inventory to _inventory(blueprint.materials[cur].material)}\r\n {if !inventory:\r\n {set canbemade to 0}\r\n |else:\r\n {if inventory.amount < canbemade:\r\n {set canbemade to inventory.amount}\r\n }\r\n }\r\n {set cur to cur + 1}\r\n }\r\n\r\n {if canbemade = 0:\r\n You cannot make any {blueprintname} grade {blueprintgrade}\r\n |elif canbemade = 1:\r\n You can make one {blueprintname} grade {blueprintgrade}\r\n |else:\r\n You can make {blueprintname} grade {blueprintgrade} {Humanise(canbemade)} times.\r\n }\r\n \r\n|else:\r\n No information available on materials required for {blueprintname} grade {blueprintgrade}\r\n}.\r\n"
},
"Blueprint material report": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Fetch from context / state _}\r\n{set blueprintname to state.blueprint}\r\n{set blueprintgrade to state.blueprintgrade}\r\n\r\n{if blueprintname && blueprintgrade:\r\n {_ Fetch full blueprint details }\r\n {set blueprint to BlueprintDetails(blueprintname, blueprintgrade)}\r\n\r\n {_ Context }\r\n {SetState('eddi_context_last_subject', 'blueprint')}\r\n {SetState('eddi_context_blueprint_name', blueprintname)}\r\n {SetState('eddi_context_blueprint_grade', blueprintgrade)}\r\n}\r\n\r\n{if blueprintname:\r\n {_ Fetch full blueprint details }\r\n {set blueprint to BlueprintDetails(blueprintname, blueprintgrade)}\r\n\r\n {_ Context }\r\n {SetState('eddi_context_last_subject', 'blueprint')}\r\n {SetState('eddi_context_blueprint_name', blueprintname)}\r\n {SetState('eddi_context_blueprint_grade', blueprintgrade)}\r\n}\r\n\r\n{if !blueprint || !blueprintgrade:\r\n {_ Fetch from context }\r\n {set blueprint to BlueprintDetails(state.eddi_context_blueprint_name, state.eddi_context_blueprint_grade)}\r\n}\r\n\r\n{if blueprint && blueprintgrade:\r\n {set materials to len(blueprint.materials)}\r\n {blueprintname} класса {blueprintgrade} требует \r\n {if materials = 1:\r\n {blueprint.materials[0].material}\r\n |elif materials = 2:\r\n {blueprint.materials[0].material} и {blueprint.materials[1].material}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(blueprint.materials):\r\n {if cur = 0:\r\n {blueprint.materials[cur].material}\r\n |elif cur < len(blueprint.materials) - 1:\r\n , {blueprint.materials[cur].material}\r\n |else:\r\n , и {blueprint.materials[cur].material}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n|else:\r\n Нет информации о материалах, необходимых для {blueprintname} класс {blueprintgrade}\r\n}.\r\n",
"name": "Blueprint material report",
"description": "Report on the material requirements for a blueprint",
"default": false,
"defaultValue": "{_ Fetch from context / state _}\r\n{set blueprintname to state.blueprint}\r\n{set blueprintgrade to state.blueprintgrade}\r\n\r\n{if blueprintname && blueprintgrade:\r\n {_ Fetch full blueprint details }\r\n {set blueprint to BlueprintDetails(blueprintname, blueprintgrade)}\r\n\r\n {_ Context }\r\n {SetState('eddi_context_last_subject', 'blueprint')}\r\n {SetState('eddi_context_blueprint_name', blueprintname)}\r\n {SetState('eddi_context_blueprint_grade', blueprintgrade)}\r\n}\r\n\r\n{if blueprintname:\r\n {_ Fetch full blueprint details }\r\n {set blueprint to BlueprintDetails(blueprintname, blueprintgrade)}\r\n\r\n {_ Context }\r\n {SetState('eddi_context_last_subject', 'blueprint')}\r\n {SetState('eddi_context_blueprint_name', blueprintname)}\r\n {SetState('eddi_context_blueprint_grade', blueprintgrade)}\r\n}\r\n\r\n{if !blueprint || !blueprintgrade:\r\n {_ Fetch from context }\r\n {set blueprint to BlueprintDetails(state.eddi_context_blueprint_name, state.eddi_context_blueprint_grade)}\r\n}\r\n\r\n{if blueprint && blueprintgrade:\r\n {set materials to len(blueprint.materials)}\r\n {blueprintname} grade {blueprintgrade} requires \r\n {if materials = 1:\r\n {blueprint.materials[0].material}\r\n |elif materials = 2:\r\n {blueprint.materials[0].material} and {blueprint.materials[1].material}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(blueprint.materials):\r\n {if cur = 0:\r\n {blueprint.materials[cur].material}\r\n |elif cur < len(blueprint.materials) - 1:\r\n , {blueprint.materials[cur].material}\r\n |else:\r\n , and {blueprint.materials[cur].material}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n|else:\r\n No information available on materials required for {blueprintname} grade {blueprintgrade}\r\n}.\r\n"
},
"Bodies mapped": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Fetch from Context, if a context is set _}\r\n{if state.eddi_context_system_name:\r\n {set reportSystem to SystemDetails(state.eddi_context_system_name)}\r\n|else:\r\n {set reportSystem to SystemDetails(system.systemname)}\r\n}\r\n\r\n{_ Build a list of scanned bodies _}\r\n\r\n{set mappedList to []}\r\n{for body in reportSystem.bodies:\r\n {if body.mapped:\r\n {set mappedList to cat(mappedList, [P(body.shortname, \"body\")])} \r\n }\r\n}\r\n\r\n{_ Begin speaking _}\r\n\r\n{if len(mappedList) > 0:\r\n {if len(mappedList) = 1: Объект |else: Объекты}\r\n \r\n {List(mappedList)}\r\n \r\n {set already to Occasionally(2, \"уже\")}\r\n \r\n {if len(mappedList) = 1: {OneOf(\"{already} нанесен на карту\", \"нанесен на карту\")}\r\n |else: {OneOf(\"{already} нанесены на карту\", \"нанесены на карту\")}\r\n }.\r\n \r\n|else:\r\n Вам еще предстоит составить карту всех тел в этой системе.\r\n}\r\n",
"name": "Bodies mapped",
"description": "Reports all the bodies mapped in this system so far",
"default": false,
"defaultValue": "{_ Fetch from Context, if a context is set _}\r\n{if state.eddi_context_system_name:\r\n {set reportSystem to SystemDetails(state.eddi_context_system_name)}\r\n|else:\r\n {set reportSystem to SystemDetails(system.systemname)}\r\n}\r\n\r\n{_ Build a list of scanned bodies _}\r\n\r\n{set mappedList to []}\r\n{for body in reportSystem.bodies:\r\n {if body.mapped:\r\n {set mappedList to cat(mappedList, [P(body.shortname, \"body\")])} \r\n }\r\n}\r\n\r\n{_ Begin speaking _}\r\n\r\n{if len(mappedList) > 0:\r\n {if len(mappedList) = 1: Body |else: Bodies}\r\n {List(mappedList)}\r\n {if len(mappedList) = 1: has |else: have }\r\n {set already to Occasionally(2, \"already\")}\r\n {OneOf(\"{already} been mapped\", \"been mapped {already}\")}.\r\n|else:\r\n You have yet to map any bodies in this system.\r\n}\r\n"
},
"Bodies to map": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Preferences: _}\r\n\r\n{set reportTerraformables to true} {_ Reports all terraformable and terraformed bodies _}\r\n{set highValueThreshold to 80000} {_ The minimum threshold for estimated exploration value worth mapping _}\r\n{set reportPlanetTypes to [\r\n \"Ammonia world\": true,\r\n \"Earth-like world\": true,\r\n \"Gas giant with ammonia based life\": false,\r\n \"Gas giant with water based life\": false,\r\n \"Helium gas giant\": false,\r\n \"Helium-rich gas giant\": false,\r\n \"High metal content world\": false,\r\n \"Icy body\": false,\r\n \"Metal-rich body\": false,\r\n \"Rocky body\": false,\r\n \"Rocky ice world\": false,\r\n \"Class I gas giant\": false,\r\n \"Class II gas giant\": false,\r\n \"Class III gas giant\": false,\r\n \"Class IV gas giant\": false,\r\n \"Class V gas giant\": false,\r\n \"Water giant\": false,\r\n \"Water giant with life\": false,\r\n \"Water world\": true,\r\n]}\r\n\r\n{_ Fetch from Context, if a context is set _}\r\n{if state.eddi_context_system_name:\r\n {set reportSystem to SystemDetails(state.eddi_context_system_name)}\r\n|else:\r\n {set reportSystem to SystemDetails(system.systemname)}\r\n}\r\n\r\n{_ Identify bodies worth mapping _}\r\n\r\n{set toMapList to []}\r\n{set mappedBodies to 0}\r\n{set totalBodies to 0}\r\n\r\n{for body in reportSystem.bodies:\r\n {set totalBodies to totalBodies + 1}\r\n {if body.mapped:\r\n {set mappedBodies to mappedBodies + 1}\r\n |else:\r\n {if body.bodyType.invariantName != \"Star\":\r\n {if body.terraformState.invariantName = \"Candidate for terraforming\" \r\n || body.terraformState.invariantName = \"Terraformed\":\r\n {if reportTerraformables:\r\n {if !toMapList[body.shortname]: \r\n {set toMapList to cat(toMapList, [body.shortname])}\r\n } \r\n }\r\n |elif reportPlanetTypes[body.planetClass.invariantName]:\r\n {if !toMapList[body.shortname]: \r\n {set toMapList to cat(toMapList, [body.shortname])}\r\n }\r\n |elif body.estimatedvalue > highValueThreshold:\r\n {if !toMapList[body.shortname]: \r\n {set toMapList to cat(toMapList, [body.shortname])}\r\n } \r\n }\r\n }\r\n }\r\n}\r\n{set toMapCount to len(toMapList)}\r\n\r\n{_ Begin speaking _}\r\n\r\n{if toMapCount > 0:\r\n\r\n {if toMapCount = 1: Body |else: Bodies}\r\n\r\n {set cur to 0}\r\n {while cur < toMapCount:\r\n {P(toMapList[cur], \"body\")}\r\n {set cur to cur + 1}\r\n {if cur = toMapCount - 1: and\r\n |elif cur < toMapCount - 1:,\r\n }\r\n }\r\n\r\n {if toMapCount = 1: is |else: are }\r\n {if event.type = \"Body mapped\": \"also\" }\r\n {if toMapCount = 1: a }\r\n {OneOf(\"recommended\", \"good\")}\r\n {set candidates to when(toMapCount = 1, \"candidate\", \"candidates\")}\r\n {OneOf('{candidates} for mapping', '{candidates} to map', 'mapping {candidates}')}.\r\n\r\n|elif mappedBodies > 0:\r\n\r\n {OneOf(\r\n \"You have mapped all {if mappedBodies < totalBodies: {OneOf(\\\"worthwhile\\\", \\\"interesting\\\")}} bodies.\",\r\n \"All {OneOf( \\\"{if mappedBodies < totalBodies: worthwhile} bodies\\\", \\\"bodies of interest\\\" )} {OneOf( \\\"have been mapped.\\\", \\\"are now mapped.\\\" )}\"\r\n )}\r\n}",
"name": "Bodies to map",
"description": "Reports all the unmapped bodies in the system that are worth mapping",
"default": true,
"defaultValue": "{_ Preferences: _}\r\n\r\n{set reportTerraformables to true} {_ Reports all terraformable and terraformed bodies _}\r\n{set highValueThreshold to 80000} {_ The minimum threshold for estimated exploration value worth mapping _}\r\n{set reportPlanetTypes to [\r\n \"Ammonia world\": true,\r\n \"Earth-like world\": true,\r\n \"Gas giant with ammonia based life\": false,\r\n \"Gas giant with water based life\": false,\r\n \"Helium gas giant\": false,\r\n \"Helium-rich gas giant\": false,\r\n \"High metal content world\": false,\r\n \"Icy body\": false,\r\n \"Metal-rich body\": false,\r\n \"Rocky body\": false,\r\n \"Rocky ice world\": false,\r\n \"Class I gas giant\": false,\r\n \"Class II gas giant\": false,\r\n \"Class III gas giant\": false,\r\n \"Class IV gas giant\": false,\r\n \"Class V gas giant\": false,\r\n \"Water giant\": false,\r\n \"Water giant with life\": false,\r\n \"Water world\": true,\r\n]}\r\n\r\n{_ Fetch from Context, if a context is set _}\r\n{if state.eddi_context_system_name:\r\n {set reportSystem to SystemDetails(state.eddi_context_system_name)}\r\n|else:\r\n {set reportSystem to SystemDetails(system.systemname)}\r\n}\r\n\r\n{_ Identify bodies worth mapping _}\r\n\r\n{set toMapList to []}\r\n{set mappedBodies to 0}\r\n{set totalBodies to 0}\r\n\r\n{for body in reportSystem.bodies:\r\n {set totalBodies to totalBodies + 1}\r\n {if body.mapped:\r\n {set mappedBodies to mappedBodies + 1}\r\n |else:\r\n {if body.bodyType.invariantName != \"Star\":\r\n {if body.terraformState.invariantName = \"Candidate for terraforming\" \r\n || body.terraformState.invariantName = \"Terraformed\":\r\n {if reportTerraformables:\r\n {if !toMapList[body.shortname]: \r\n {set toMapList to cat(toMapList, [body.shortname])}\r\n } \r\n }\r\n |elif reportPlanetTypes[body.planetClass.invariantName]:\r\n {if !toMapList[body.shortname]: \r\n {set toMapList to cat(toMapList, [body.shortname])}\r\n }\r\n |elif body.estimatedvalue > highValueThreshold:\r\n {if !toMapList[body.shortname]: \r\n {set toMapList to cat(toMapList, [body.shortname])}\r\n } \r\n }\r\n }\r\n }\r\n}\r\n{set toMapCount to len(toMapList)}\r\n\r\n{_ Begin speaking _}\r\n\r\n{if toMapCount > 0:\r\n\r\n {if toMapCount = 1: Body |else: Bodies}\r\n\r\n {set cur to 0}\r\n {while cur < toMapCount:\r\n {P(toMapList[cur], \"body\")}\r\n {set cur to cur + 1}\r\n {if cur = toMapCount - 1: and\r\n |elif cur < toMapCount - 1:,\r\n }\r\n }\r\n\r\n {if toMapCount = 1: is |else: are }\r\n {if event.type = \"Body mapped\": \"also\" }\r\n {if toMapCount = 1: a }\r\n {OneOf(\"recommended\", \"good\")}\r\n {set candidates to when(toMapCount = 1, \"candidate\", \"candidates\")}\r\n {OneOf('{candidates} for mapping', '{candidates} to map', 'mapping {candidates}')}.\r\n\r\n|elif mappedBodies > 0:\r\n\r\n {OneOf(\r\n \"You have mapped all {if mappedBodies < totalBodies: {OneOf(\\\"worthwhile\\\", \\\"interesting\\\")}} bodies.\",\r\n \"All {OneOf( \\\"{if mappedBodies < totalBodies: worthwhile} bodies\\\", \\\"bodies of interest\\\" )} {OneOf( \\\"have been mapped.\\\", \\\"are now mapped.\\\" )}\"\r\n )}\r\n}"
},
"Body atmosphere report": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Preferences _}\r\n{set reportAtmoPressure to 0} {_ Set to 1 if you want to hear about the atmospheric pressure. _}\r\n{set reportAtmoTempScale to 0} {_ Set to 0 if you want to hear about temperatures in Kelvin _}\r\n {_ Set to 1 if you want to hear about temperatures in Celsius _}\r\n {_ Set to 2 if you want to hear about temperatures in Fahrenheit _}\r\n {_ Set to 3 if you don't want to hear about the temperature of the body _}\r\n\r\n{_ Define functions for converting temperature scales _}\r\n{set ToCelsius(kelvin) to: {round(kelvin - 273)}}\r\n{set ToFahrenheit(kelvin) to: {round((kelvin-273)*9/5 + 32)}}\r\n{set TempCalc(kelvin) to: \r\n {if reportAtmoTempScale = 0: {round(kelvin)}}\r\n {if reportAtmoTempScale = 1: {ToCelsius(kelvin)}}\r\n {if reportAtmoTempScale = 2: {ToFahrenheit(kelvin)}}\r\n}\r\n\r\n{_ Name our temperature scale _}\r\n{if reportAtmoTempScale = 0: {set tempscale to: Kelvin}}\r\n{if reportAtmoTempScale = 1: {set tempscale to: degrees Celsius}}\r\n{if reportAtmoTempScale = 2: {set tempscale to: degrees Fahrenheit}}\r\n\r\n{_ Fetch from context _}\r\n{set reportbody to BodyDetails(state.eddi_context_body_name, state.eddi_context_body_system)}\r\n{if !reportbody: \r\n {set reportbody to BodyDetails(state.eddi_context_body_name)}\r\n}\r\n\r\n{if !reportbody.name || reportbody.name = \"\":\r\n I'm not sure which body you are asking about.\r\n\r\n|else:\r\n\r\n {if find(reportbody.planettype, \"giant\") >= 0:\r\n {if find(reportbody.planettype, \"Class\") >= 0: \r\n {set sudarsky to Occasionally(3, \"Sud-dar-ski\")}\r\n }\r\n {set planetdesc to OneOf(\"{sudarsky} Gas giants like this one have\", \"This {sudarsky} gas giant has\")}\r\n {if find(reportbody.planettype, \"Class V\") >= 0:\r\n {planetdesc} \r\n {if reportAtmoTempScale < 3: \r\n {set tempmin to: {TempCalc(1373)}}\r\n temperatures above {Humanise(tempmin)} {tempscale}, {OneOf(\"and\", \"with\", \"forming\")}\r\n }\r\n a dense cloud layer of {OneOf(\"vaporized silicates and iron\", \"silicate and iron vapors\")}.\r\n |elif find(reportbody.planettype, \"Class IV\") >= 0:\r\n {planetdesc} \r\n {if reportAtmoTempScale < 3: \r\n {set tempmin to: {TempCalc(354)}}\r\n {set tempmax to: {TempCalc(903)}}\r\n temperatures {OneOf(\"of\", \"ranging\")} between {Humanise(tempmin)} and {Humanise(tempmax)} {tempscale}, {OneOf(\"and\", \"with\", \"forming\")}\r\n }\r\n a dense cloud layer of {OneOf(\"alkali metals vapors\", \"vaporized alkali metals\")}. \r\n |elif find(reportbody.planettype, \"Class III\") >= 0:\r\n {planetdesc} \r\n {if reportAtmoTempScale < 3: \r\n {set tempmin to: {TempCalc(251)}}\r\n {set tempmax to: {TempCalc(353)}}\r\n surface temperatures {OneOf(\"of\", \"ranging\")} between {Humanise(tempmin)} and {Humanise(tempmax)} {tempscale},\r\n }\r\n a temperature at which {OneOf(\"no gaseous elements will form any clouds\", \"suitable chemicals are not present in the atmosphere to form a sustained cloud layer\", \"the atmosphere cannot sustain a persistent cloud layer\")}.\r\n |elif find(reportbody.planettype, \"Class II\") >= 0:\r\n {planetdesc} \r\n {if reportAtmoTempScale < 3: \r\n {set tempmin to: {TempCalc(154)}}\r\n {set tempmax to: {TempCalc(250)}}\r\n surface temperatures {OneOf(\"of\", \"ranging\")} between {Humanise(tempmin)} and {Humanise(tempmax)} {tempscale}, {OneOf(\"and\", \"with\", \"forming\")}\r\n }\r\n a dense cloud layer of water vapors. \r\n |elif find(reportbody.planettype, \"Class I\") >= 0:\r\n {planetdesc} \r\n {if reportAtmoTempScale < 3: \r\n {set tempmin to: {TempCalc(153)}}\r\n {set tempmax to: {TempCalc(83)}}\r\n surface temperatures of {Humanise(tempmax)} {tempscale} {Occasionally(2, OneOf(\", or less,\", \", at most,\"))} {OneOf(\"and\", \"with\", \"forming\")}\r\n }\r\n a dense cloud layer of ammonia vapor. \r\n }\r\n\r\n |elif reportbody.atmosphere = \"No atmosphere\" || !reportbody.atmosphere:\r\n {Occasionally(4, OneOf(\"There is no atmosphere.\", \"It is devoid of any atmosphere.\", \"The years have scoured it clean of any atmosphere.\"))}\r\n {if reportbody.temperature && reportAtmoTempScale < 3:\r\n The surface temperature averages\r\n {TempCalc(reportbody.temperature)} {tempscale}.\r\n }\r\n\r\n |elif reportbody.pressure: \r\n {if reportbody.pressure < 0.1:\r\n {set pressdesc to OneOf(\"trace gas\", \"super thin\")}\r\n |elif reportbody.pressure < 0.25:\r\n {set pressdesc to \"very thin\"}\r\n |elif reportbody.pressure < 0.5:\r\n {set pressdesc to \"thin\"}\r\n |elif reportbody.pressure < 2:\r\n {set pressdesc to \"\"}\r\n |elif reportbody.pressure < 10:\r\n {set pressdesc to \"thick\"}\r\n |elif reportbody.pressure < 50:\r\n {set pressdesc to OneOf(\"dense\", \"very thick\")}\r\n |elif reportbody.pressure < 100:\r\n {set pressdesc to OneOf(\"very dense\", \"super thick\")}\r\n |elif reportbody.pressure >= 100:\r\n {set pressdesc to OneOf(\"crushing\", \"super dense\")}\r\n }\r\n {if find(reportbody.atmosphere, \"-rich\") >= 0:\r\n {set element to token(reportbody.atmosphere, \"-rich\", \"\")}\r\n {set desc to OneOf(\"I detect a \", \"There is a \", \"Sensors detect a\")}\r\n {OneOf(\"{desc} {pressdesc} {reportbody.atmosphere} atmosphere\", \"The {pressdesc} atmosphere is {reportbody.atmosphere}\", \"The {pressdesc} atmosphere is rich in {element}\")}\r\n |elif find(reportbody.atmosphere, \"vapour\") >= 0:\r\n {OneOf(\"The {pressdesc} atmosphere is composed of {reportbody.atmosphere}s\", \"The {pressdesc} atmosphere is rich in {reportbody.atmosphere}s\", \"The {pressdesc} atmosphere contains high levels of {reportbody.atmosphere}s\")}\r\n |elif reportbody.planetClass.invariantName = \"Earth-like world\":\r\n The atmosphere is similar to Earth's, \r\n |else:\r\n {set mostly to OneOf(\"primarily\", \"mainly\", \"mostly\")}\r\n {OneOf(\"The {pressdesc} atmosphere is composed {mostly} of\", \"Most prevalent in the {pressdesc} atmosphere is\")}\r\n {reportbody.atmosphere}\r\n }\r\n { if reportAtmoPressure > 0:\r\n with a surface pressure of {Humanise(reportbody.pressure)} Earth atmospheres\r\n }\r\n {if reportbody.temperature && reportAtmoTempScale < 3:\r\n {set temp to: {TempCalc(reportbody.temperature)}}\r\n {if find(temp, \"-\") >= 0: \r\n {set temp to cat(temp*-1, tempscale, \"below zero\")}\r\n |else:\r\n {set temp to cat(temp, tempscale)}\r\n }\r\n with an average surface temperature of {temp}\r\n }.\r\n }\r\n}",
"name": "Body atmosphere report",
"description": "Report on the atmosphere of the contextual body",
"default": true,
"defaultValue": "{_ Preferences _}\r\n{set reportAtmoPressure to 0} {_ Set to 1 if you want to hear about the atmospheric pressure. _}\r\n{set reportAtmoTempScale to 0} {_ Set to 0 if you want to hear about temperatures in Kelvin _}\r\n {_ Set to 1 if you want to hear about temperatures in Celsius _}\r\n {_ Set to 2 if you want to hear about temperatures in Fahrenheit _}\r\n {_ Set to 3 if you don't want to hear about the temperature of the body _}\r\n\r\n{_ Define functions for converting temperature scales _}\r\n{set ToCelsius(kelvin) to: {round(kelvin - 273)}}\r\n{set ToFahrenheit(kelvin) to: {round((kelvin-273)*9/5 + 32)}}\r\n{set TempCalc(kelvin) to: \r\n {if reportAtmoTempScale = 0: {round(kelvin)}}\r\n {if reportAtmoTempScale = 1: {ToCelsius(kelvin)}}\r\n {if reportAtmoTempScale = 2: {ToFahrenheit(kelvin)}}\r\n}\r\n\r\n{_ Name our temperature scale _}\r\n{if reportAtmoTempScale = 0: {set tempscale to: Kelvin}}\r\n{if reportAtmoTempScale = 1: {set tempscale to: degrees Celsius}}\r\n{if reportAtmoTempScale = 2: {set tempscale to: degrees Fahrenheit}}\r\n\r\n{_ Fetch from context _}\r\n{set reportbody to BodyDetails(state.eddi_context_body_name, state.eddi_context_body_system)}\r\n{if !reportbody: \r\n {set reportbody to BodyDetails(state.eddi_context_body_name)}\r\n}\r\n\r\n{if !reportbody.name || reportbody.name = \"\":\r\n I'm not sure which body you are asking about.\r\n\r\n|else:\r\n\r\n {if find(reportbody.planettype, \"giant\") >= 0:\r\n {if find(reportbody.planettype, \"Class\") >= 0: \r\n {set sudarsky to Occasionally(3, \"Sud-dar-ski\")}\r\n }\r\n {set planetdesc to OneOf(\"{sudarsky} Gas giants like this one have\", \"This {sudarsky} gas giant has\")}\r\n {if find(reportbody.planettype, \"Class V\") >= 0:\r\n {planetdesc} \r\n {if reportAtmoTempScale < 3: \r\n {set tempmin to: {TempCalc(1373)}}\r\n temperatures above {Humanise(tempmin)} {tempscale}, {OneOf(\"and\", \"with\", \"forming\")}\r\n }\r\n a dense cloud layer of {OneOf(\"vaporized silicates and iron\", \"silicate and iron vapors\")}.\r\n |elif find(reportbody.planettype, \"Class IV\") >= 0:\r\n {planetdesc} \r\n {if reportAtmoTempScale < 3: \r\n {set tempmin to: {TempCalc(354)}}\r\n {set tempmax to: {TempCalc(903)}}\r\n temperatures {OneOf(\"of\", \"ranging\")} between {Humanise(tempmin)} and {Humanise(tempmax)} {tempscale}, {OneOf(\"and\", \"with\", \"forming\")}\r\n }\r\n a dense cloud layer of {OneOf(\"alkali metals vapors\", \"vaporized alkali metals\")}. \r\n |elif find(reportbody.planettype, \"Class III\") >= 0:\r\n {planetdesc} \r\n {if reportAtmoTempScale < 3: \r\n {set tempmin to: {TempCalc(251)}}\r\n {set tempmax to: {TempCalc(353)}}\r\n surface temperatures {OneOf(\"of\", \"ranging\")} between {Humanise(tempmin)} and {Humanise(tempmax)} {tempscale},\r\n }\r\n a temperature at which {OneOf(\"no gaseous elements will form any clouds\", \"suitable chemicals are not present in the atmosphere to form a sustained cloud layer\", \"the atmosphere cannot sustain a persistent cloud layer\")}.\r\n |elif find(reportbody.planettype, \"Class II\") >= 0:\r\n {planetdesc} \r\n {if reportAtmoTempScale < 3: \r\n {set tempmin to: {TempCalc(154)}}\r\n {set tempmax to: {TempCalc(250)}}\r\n surface temperatures {OneOf(\"of\", \"ranging\")} between {Humanise(tempmin)} and {Humanise(tempmax)} {tempscale}, {OneOf(\"and\", \"with\", \"forming\")}\r\n }\r\n a dense cloud layer of water vapors. \r\n |elif find(reportbody.planettype, \"Class I\") >= 0:\r\n {planetdesc} \r\n {if reportAtmoTempScale < 3: \r\n {set tempmin to: {TempCalc(153)}}\r\n {set tempmax to: {TempCalc(83)}}\r\n surface temperatures of {Humanise(tempmax)} {tempscale} {Occasionally(2, OneOf(\", or less,\", \", at most,\"))} {OneOf(\"and\", \"with\", \"forming\")}\r\n }\r\n a dense cloud layer of ammonia vapor. \r\n }\r\n\r\n |elif reportbody.atmosphere = \"No atmosphere\" || !reportbody.atmosphere:\r\n {Occasionally(4, OneOf(\"There is no atmosphere.\", \"It is devoid of any atmosphere.\", \"The years have scoured it clean of any atmosphere.\"))}\r\n {if reportbody.temperature && reportAtmoTempScale < 3:\r\n The surface temperature averages\r\n {TempCalc(reportbody.temperature)} {tempscale}.\r\n }\r\n\r\n |elif reportbody.pressure: \r\n {if reportbody.pressure < 0.1:\r\n {set pressdesc to OneOf(\"trace gas\", \"super thin\")}\r\n |elif reportbody.pressure < 0.25:\r\n {set pressdesc to \"very thin\"}\r\n |elif reportbody.pressure < 0.5:\r\n {set pressdesc to \"thin\"}\r\n |elif reportbody.pressure < 2:\r\n {set pressdesc to \"\"}\r\n |elif reportbody.pressure < 10:\r\n {set pressdesc to \"thick\"}\r\n |elif reportbody.pressure < 50:\r\n {set pressdesc to OneOf(\"dense\", \"very thick\")}\r\n |elif reportbody.pressure < 100:\r\n {set pressdesc to OneOf(\"very dense\", \"super thick\")}\r\n |elif reportbody.pressure >= 100:\r\n {set pressdesc to OneOf(\"crushing\", \"super dense\")}\r\n }\r\n {if find(reportbody.atmosphere, \"-rich\") >= 0:\r\n {set element to token(reportbody.atmosphere, \"-rich\", \"\")}\r\n {set desc to OneOf(\"I detect a \", \"There is a \", \"Sensors detect a\")}\r\n {OneOf(\"{desc} {pressdesc} {reportbody.atmosphere} atmosphere\", \"The {pressdesc} atmosphere is {reportbody.atmosphere}\", \"The {pressdesc} atmosphere is rich in {element}\")}\r\n |elif find(reportbody.atmosphere, \"vapour\") >= 0:\r\n {OneOf(\"The {pressdesc} atmosphere is composed of {reportbody.atmosphere}s\", \"The {pressdesc} atmosphere is rich in {reportbody.atmosphere}s\", \"The {pressdesc} atmosphere contains high levels of {reportbody.atmosphere}s\")}\r\n |elif reportbody.planetClass.invariantName = \"Earth-like world\":\r\n The atmosphere is similar to Earth's, \r\n |else:\r\n {set mostly to OneOf(\"primarily\", \"mainly\", \"mostly\")}\r\n {OneOf(\"The {pressdesc} atmosphere is composed {mostly} of\", \"Most prevalent in the {pressdesc} atmosphere is\")}\r\n {reportbody.atmosphere}\r\n }\r\n { if reportAtmoPressure > 0:\r\n with a surface pressure of {Humanise(reportbody.pressure)} Earth atmospheres\r\n }\r\n {if reportbody.temperature && reportAtmoTempScale < 3:\r\n {set temp to: {TempCalc(reportbody.temperature)}}\r\n {if find(temp, \"-\") >= 0: \r\n {set temp to cat(temp*-1, tempscale, \"below zero\")}\r\n |else:\r\n {set temp to cat(temp, tempscale)}\r\n }\r\n with an average surface temperature of {temp}\r\n }.\r\n }\r\n}"
},
"Body mapped": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Preferences _}\r\n\r\n{set bodyReport to 2} {_ 0 = No body report, 1 = Summary body report, 2 = Body report _}\r\n{set recommendOtherMapping to 1} {_ 0 or 1. If 1, recommends other bodies from the `Bodies to map` script _}\r\n\r\n{_ Context}\r\n{SetState('eddi_context_last_action', 'scan')}\r\n{SetState('eddi_context_last_subject', 'body')}\r\n{SetState('eddi_context_body_system', system.name)}\r\n{SetState('eddi_context_body_name', event.name)}\r\n{SetState('eddi_context_last_scan_estimated_value', event.estimatedvalue)}\r\n\r\n{_ Process the event _}\r\n\r\n{if ship.Role.edname = \"Exploration\" || ship.Role.edname = \"Multipurpose\":\r\n\r\n {Pause(3000)}\r\n\r\n {OneOf(\"Mapping\", \"{Occasionally(2, \\\"Surface\\\")} Map\")}\r\n {OneOf(\"is\", \"is now\")}\r\n {OneOf(\"complete\", \"finished\")}.\r\n\r\n {if event.probesused <= event.efficiencytarget:\r\n Efficiency bonus {OneOf(\"awarded\", \"granted\")}.\r\n }\r\n\r\n {Pause(500)}\r\n {if bodyReport = 2:\r\n {F(\"Body report\")}\r\n |elif bodyReport = 1:\r\n {F(\"Body report summary\")}\r\n }\r\n\r\n {if recommendOtherMapping: \r\n {Pause(1500)}\r\n {F(\"Bodies to map\")}\r\n }\r\n}",
"name": "Body mapped",
"description": "Triggered after mapping a body with the Surface Area Analysis scanner",
"default": true,
"defaultValue": "{_ Preferences _}\r\n\r\n{set bodyReport to 2} {_ 0 = No body report, 1 = Summary body report, 2 = Body report _}\r\n{set recommendOtherMapping to 1} {_ 0 or 1. If 1, recommends other bodies from the `Bodies to map` script _}\r\n\r\n{_ Context}\r\n{SetState('eddi_context_last_action', 'scan')}\r\n{SetState('eddi_context_last_subject', 'body')}\r\n{SetState('eddi_context_body_system', system.name)}\r\n{SetState('eddi_context_body_name', event.name)}\r\n{SetState('eddi_context_last_scan_estimated_value', event.estimatedvalue)}\r\n\r\n{_ Process the event _}\r\n\r\n{if ship.Role.edname = \"Exploration\" || ship.Role.edname = \"Multipurpose\":\r\n\r\n {Pause(3000)}\r\n\r\n {OneOf(\"Mapping\", \"{Occasionally(2, \\\"Surface\\\")} Map\")}\r\n {OneOf(\"is\", \"is now\")}\r\n {OneOf(\"complete\", \"finished\")}.\r\n\r\n {if event.probesused <= event.efficiencytarget:\r\n Efficiency bonus {OneOf(\"awarded\", \"granted\")}.\r\n }\r\n\r\n {Pause(500)}\r\n {if bodyReport = 2:\r\n {F(\"Body report\")}\r\n |elif bodyReport = 1:\r\n {F(\"Body report summary\")}\r\n }\r\n\r\n {if recommendOtherMapping: \r\n {Pause(1500)}\r\n {F(\"Bodies to map\")}\r\n }\r\n}"
},
"Body materials report": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Preferences _}\r\n{set reportMats to 1} {_ Set to 0 if you want to hear about materials below your minimum inventory level _}\r\n {_ Set to 1 if you want to hear about materials below your desired inventory level _}\r\n {_ Set to 2 if you want to hear about all materials irrespective of inventory levels _}\r\n\r\n{set reportMatConc to 1} {_ Set to 0 if you only want to hear about great material concentrations _}\r\n {_ Set to 1 if you want to hear about good and great material concentrations _}\r\n {_ Set to 2 if you want to hear about all material concentrations _}\r\n\r\n{set reportMatPercent to 1} {_ Set to 0 if you do not want to hear about material percentages _}\r\n {_ Set to 1 if you only want to hear about great material percentages _}\r\n {_ Set to 2 if you want to hear about good and great material percentages _}\r\n {_ Set to 3 if you want to hear about all material percentages _}\r\n\r\n{_ Fetch from context _}\r\n{set reportbody to BodyDetails(state.eddi_context_body_name, state.eddi_context_body_system)}\r\n{if !reportbody: \r\n {set reportbody to BodyDetails(state.eddi_context_body_name)}\r\n}\r\n\r\n{if !reportbody.name || reportbody.name = \"\":\r\n {_ If it's still not possible to get the body name... _}\r\n Which body are you\r\n {OneOf(\"asking about\",\"referring to\")}?\r\n\r\n|else:\r\n\r\n {_ Define a function to obtain a material from inventory}\r\n {set _inventory(required) to:\r\n {for material in materials:\r\n {if material.material = required:\r\n {return material}\r\n }\r\n }\r\n }\r\n\r\n {if reportbody.landable:\r\n\r\n {set goodmaterials to []}\r\n {set greatmaterials to []}\r\n {set othermaterials to []}\r\n\r\n {for material in reportbody.materials:\r\n {set inventoryMat to _inventory(material.material)}\r\n {if (reportMats >= 0 && inventoryMat.amount < inventoryMat.minimum && inventoryMat.minimum > 0)\r\n || (reportMats >= 1 && inventoryMat.amount < inventoryMat.desired && inventoryMat.desired > 0)\r\n || (reportMats >= 2):\r\n {if material.percentage >= material.definition.greatpctbody && reportMatConc > -1:\r\n {set greatmaterials to cat(greatmaterials, [material])}\r\n |elif material.percentage >= material.definition.goodpctbody && reportMatConc > 0:\r\n {set goodmaterials to cat(goodmaterials, [material])}\r\n |elif reportMatConc > 1:\r\n {set othermaterials to cat(othermaterials, [material])}\r\n }\r\n }\r\n }\r\n\r\n {_ Start speaking _}\r\n\r\n {if len(goodmaterials) > 0 || len(greatmaterials) > 0 || len(othermaterials) > 0:\r\n {if reportbody.name = reportbody.shortname:\r\n {P(reportbody.shortname, \"body\")}\r\n |else:\r\n {OneOf(\"This body\", cat(\"Body \", P(reportbody.shortname, \"body\")))} \r\n }\r\n {OneOf(\"contains\", \"has\")}\r\n }\r\n\r\n {if len(greatmaterials) > 0:\r\n {OneOf(\"very high levels\", \"very large deposits\")} of\r\n {set cur to 0}\n {set length to len(greatmaterials) - 1}\n {while cur < len(greatmaterials):\n {greatmaterials[cur].definition.name}\n {if reportMatPercent > 0: at {round(greatmaterials[cur].percentage, 1)}% }\n {set cur to cur + 1}\n {if cur = length: and\n |elif cur < length:,\n }\n }\r\n \r\n {if len(goodmaterials) > 0 && len(othermaterials) = 0:\r\n and\r\n |elif len(goodmaterials) > 0 || len(othermaterials) > 0:\r\n ,\r\n }\r\n }\r\n\r\n {if len(goodmaterials) > 0:\r\n {OneOf(\"high levels\", \"large deposits\")} of\r\n {set cur to 0}\n {set length to len(goodmaterials) - 1}\n {while cur < len(goodmaterials):\n {goodmaterials[cur].definition.name}\n {if reportMatPercent > 1: at {round(goodmaterials[cur].percentage, 1)}% }\n {set cur to cur + 1}\n {if cur = length: and\n |elif cur < length:,\n }\n }\r\n }\r\n \r\n {if (len(greatmaterials) > 0 || len(goodmaterials) > 0) && len(othermaterials) > 0:\r\n and\r\n }\r\n \r\n {if len(othermaterials) > 0:\r\n {OneOf(\"moderate levels\", \"modest deposits\")} of\r\n {set cur to 0}\n {set length to len(othermaterials) - 1}\n {while cur < len(othermaterials):\n {othermaterials[cur].definition.name}\n {if reportMatPercent > 2: at {round(othermaterials[cur].percentage, 0)}% }\n {set cur to cur + 1}\n {if cur = length: and\n |elif cur < length:,\n }\n }\r\n }\r\n \r\n {if len(goodmaterials) > 0 || len(greatmaterials) > 0 || len(othermaterials) > 0:\r\n .\r\n }\r\n }\r\n}",
"name": "Body materials report",
"description": "Report on the materials available from the contextual body",
"default": true,
"defaultValue": "{_ Preferences _}\r\n{set reportMats to 1} {_ Set to 0 if you want to hear about materials below your minimum inventory level _}\r\n {_ Set to 1 if you want to hear about materials below your desired inventory level _}\r\n {_ Set to 2 if you want to hear about all materials irrespective of inventory levels _}\r\n\r\n{set reportMatConc to 1} {_ Set to 0 if you only want to hear about great material concentrations _}\r\n {_ Set to 1 if you want to hear about good and great material concentrations _}\r\n {_ Set to 2 if you want to hear about all material concentrations _}\r\n\r\n{set reportMatPercent to 1} {_ Set to 0 if you do not want to hear about material percentages _}\r\n {_ Set to 1 if you only want to hear about great material percentages _}\r\n {_ Set to 2 if you want to hear about good and great material percentages _}\r\n {_ Set to 3 if you want to hear about all material percentages _}\r\n\r\n{_ Fetch from context _}\r\n{set reportbody to BodyDetails(state.eddi_context_body_name, state.eddi_context_body_system)}\r\n{if !reportbody: \r\n {set reportbody to BodyDetails(state.eddi_context_body_name)}\r\n}\r\n\r\n{if !reportbody.name || reportbody.name = \"\":\r\n {_ If it's still not possible to get the body name... _}\r\n Which body are you\r\n {OneOf(\"asking about\",\"referring to\")}?\r\n\r\n|else:\r\n\r\n {_ Define a function to obtain a material from inventory}\r\n {set _inventory(required) to:\r\n {for material in materials:\r\n {if material.material = required:\r\n {return material}\r\n }\r\n }\r\n }\r\n\r\n {if reportbody.landable:\r\n\r\n {set goodmaterials to []}\r\n {set greatmaterials to []}\r\n {set othermaterials to []}\r\n\r\n {for material in reportbody.materials:\r\n {set inventoryMat to _inventory(material.material)}\r\n {if (reportMats >= 0 && inventoryMat.amount < inventoryMat.minimum && inventoryMat.minimum > 0)\r\n || (reportMats >= 1 && inventoryMat.amount < inventoryMat.desired && inventoryMat.desired > 0)\r\n || (reportMats >= 2):\r\n {if material.percentage >= material.definition.greatpctbody && reportMatConc > -1:\r\n {set greatmaterials to cat(greatmaterials, [material])}\r\n |elif material.percentage >= material.definition.goodpctbody && reportMatConc > 0:\r\n {set goodmaterials to cat(goodmaterials, [material])}\r\n |elif reportMatConc > 1:\r\n {set othermaterials to cat(othermaterials, [material])}\r\n }\r\n }\r\n }\r\n\r\n {_ Start speaking _}\r\n\r\n {if len(goodmaterials) > 0 || len(greatmaterials) > 0 || len(othermaterials) > 0:\r\n {if reportbody.name = reportbody.shortname:\r\n {P(reportbody.shortname, \"body\")}\r\n |else:\r\n {OneOf(\"This body\", cat(\"Body \", P(reportbody.shortname, \"body\")))} \r\n }\r\n {OneOf(\"contains\", \"has\")}\r\n }\r\n\r\n {if len(greatmaterials) > 0:\r\n {OneOf(\"very high levels\", \"very large deposits\")} of\r\n {set cur to 0}\n {set length to len(greatmaterials) - 1}\n {while cur < len(greatmaterials):\n {greatmaterials[cur].definition.name}\n {if reportMatPercent > 0: at {round(greatmaterials[cur].percentage, 1)}% }\n {set cur to cur + 1}\n {if cur = length: and\n |elif cur < length:,\n }\n }\r\n \r\n {if len(goodmaterials) > 0 && len(othermaterials) = 0:\r\n and\r\n |elif len(goodmaterials) > 0 || len(othermaterials) > 0:\r\n ,\r\n }\r\n }\r\n\r\n {if len(goodmaterials) > 0:\r\n {OneOf(\"high levels\", \"large deposits\")} of\r\n {set cur to 0}\n {set length to len(goodmaterials) - 1}\n {while cur < len(goodmaterials):\n {goodmaterials[cur].definition.name}\n {if reportMatPercent > 1: at {round(goodmaterials[cur].percentage, 1)}% }\n {set cur to cur + 1}\n {if cur = length: and\n |elif cur < length:,\n }\n }\r\n }\r\n \r\n {if (len(greatmaterials) > 0 || len(goodmaterials) > 0) && len(othermaterials) > 0:\r\n and\r\n }\r\n \r\n {if len(othermaterials) > 0:\r\n {OneOf(\"moderate levels\", \"modest deposits\")} of\r\n {set cur to 0}\n {set length to len(othermaterials) - 1}\n {while cur < len(othermaterials):\n {othermaterials[cur].definition.name}\n {if reportMatPercent > 2: at {round(othermaterials[cur].percentage, 0)}% }\n {set cur to cur + 1}\n {if cur = length: and\n |elif cur < length:,\n }\n }\r\n }\r\n \r\n {if len(goodmaterials) > 0 || len(greatmaterials) > 0 || len(othermaterials) > 0:\r\n .\r\n }\r\n }\r\n}"
},
"Body report": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Preferences _}\r\n{set reportGravity to 1} {_ Set to 0 if you don't want to hear about the body's gravity. _} \r\n{set reportTerraformState to 1} {_ Set to 0 if you don't want to hear about the terraform state of the body. _}\r\n{set reportRings to 1} {_ Set to 0 if you don't want to hear about the body's rings. _}\r\n{set reportRotation to 0} {_ Set to 1 if you want to hear about the body's rotation. _}\r\n{set reportVolcanism to 1} {_ Set to 0 if you don't want to hear about the body's volcanism. _}\r\n{set reportAtmosphere to 1} {_ Set to 0 if you don't want to hear about the body's atmosphere. _}\r\n{set reportMaterials to 1} {_ Set to 0 if you don't want to hear about the body's materials. _}\r\n{set reportScanValue to 0} {_ Set to 1 if you want to hear about the body's estimated value. _}\r\n\r\n{_ Fetch from context _}\r\n{set reportbody to BodyDetails(state.eddi_context_body_name, state.eddi_context_body_system)}\r\n{if !reportbody: \r\n {set reportbody to BodyDetails(state.eddi_context_body_name)}\r\n}\r\n\r\n{if !reportbody.name || reportbody.name = \"\":\r\n I'm not sure which body you are asking about.\r\n|else:\r\n {if reportbody.shortname != reportbody.name: \r\n {if reportbody.bodytype:\r\n {reportbody.bodytype}\r\n |else:\r\n {OneOf(\"Body\", \"Object\")} \r\n }\r\n }\r\n {P(reportbody.shortname, \"body\")} is\r\n\r\n {if reportGravity > 0:\r\n {if reportbody.gravity < 0.5:\r\n a low-gravity\r\n |elif reportbody.gravity < 2:\r\n a medium-gravity\r\n |elif reportbody.gravity < 4:\r\n a high-gravity\r\n |else:\r\n an extremely high-gravity\r\n }\r\n |else:\r\n a\r\n }\r\n\r\n {if reportTerraformState > 0:\r\n {if reportbody.terraformState.invariantName = \"Candidate for terraforming\":\r\n terraformable\r\n |elif reportbody.terraformState.invariantName = \"Terraformed\":\r\n terraformed\r\n }\r\n }\r\n\r\n {if find(reportbody.planettype, \"Class\") >= 0 && find(reportbody.planettype, \"gas giant\") >= 0:\r\n {set sudarsky to Occasionally(2, \"Sud-dar-ski\")}\r\n {if find(reportbody.planettype, \"Class V\") >= 0:\r\n {Occasionally(2, \"{Sudarsky} class five\")}\r\n |elif find(reportbody.planettype, \"Class IV\") >= 0:\r\n {Occasionally(2, \"{Sudarsky} class four\")}\r\n |elif find(reportbody.planettype, \"Class III\") >= 0:\r\n {Occasionally(2, \"{Sudarsky} class three\")}\r\n |elif find(reportbody.planettype, \"Class II\") >= 0:\r\n {Occasionally(2, \"{Sudarsky} class two\")}\r\n |elif find(reportbody.planettype, \"Class I\") >= 0:\r\n {Occasionally(2, \"{Sudarsky} class one\")}\r\n }\r\n gas giant\r\n |elif reportbody.planettype:\r\n {P(reportbody.planettype, \"planettype\")}\r\n |else: \r\n {if reportbody.bodytype:\r\n {reportbody.bodytype}\r\n |else:\r\n world\r\n }\r\n }\r\n\r\n {if len(reportbody.rings) && reportRings > 0:\r\n with {if len(reportbody.rings) = 1: a}\r\n {if find(reportbody.reserves, \"Pristine\") >= 0:\r\n pristine\r\n |elif find(reportbody.reserves, \"Major\") >= 0:\r\n rich\r\n }\r\n {set ringname to []}\r\n {set ringcomposition to []}\r\n {for Ring in reportbody.rings:\r\n {if find(ringcomposition, Ring.composition) < 0:\r\n {set ringcomposition to cat(ringcomposition, [Ring.composition])}\r\n }\r\n }\r\n {if len(ringcomposition) > 0:\r\n {List(ringcomposition)}\r\n }\r\n {if find(ringname[0], \"Belt\") >= 0: \r\n {set ring to \"belt\"}\r\n |else:\r\n {set ring to \"ring\"}\r\n }\r\n {ring}{if len(reportbody.rings) > 1 || len(event.rings) > 1:s}\r\n }\r\n\r\n {if reportbody.terraformState.invariantName = \"Terraforming\" && reportTerraformState > 0:\r\n in the process of being terraformed\r\n }\r\n\r\n {if reportbody.landable:\r\n that is suitable for landing\r\n }\r\n . {_ note the full stop}\r\n\r\n {if reportbody.rotationalperiod && reportRotation > 0:\r\n {Pause(100)}\r\n It has a\r\n {if reportbody.rotationalperiod < -20.0:\r\n slow retrograde\r\n |elif reportbody.rotationalperiod < -0.5:\r\n retrograde\r\n |elif reportbody.rotationalperiod < 0.0:\r\n fast retrograde\r\n |elif reportbody.rotationalperiod <= 0.5:\r\n fast\r\n |elif reportbody.rotationalperiod > 20.0:\r\n slow\r\n }\r\n rotational period of {Humanise(round(reportbody.rotationalperiod, 1))} days\r\n {if reportbody.tidallylocked:\r\n and is tidally-locked\r\n }.\r\n }\r\n\r\n {if reportVolcanism: {F(\"Body volcanism report\")} }\r\n\r\n {if reportAtmosphere: {F(\"Body atmosphere report\")} }\r\n\r\n {if reportMaterials: {F(\"Body materials report\")} }\r\n\r\n {if reportScanValue: {F(\"Report last scan value\")} }\r\n}",
"name": "Body report",
"description": "Function to report on the details of the contextual body",
"default": true,
"defaultValue": "{_ Preferences _}\r\n{set reportGravity to 1} {_ Set to 0 if you don't want to hear about the body's gravity. _} \r\n{set reportTerraformState to 1} {_ Set to 0 if you don't want to hear about the terraform state of the body. _}\r\n{set reportRings to 1} {_ Set to 0 if you don't want to hear about the body's rings. _}\r\n{set reportRotation to 0} {_ Set to 1 if you want to hear about the body's rotation. _}\r\n{set reportVolcanism to 1} {_ Set to 0 if you don't want to hear about the body's volcanism. _}\r\n{set reportAtmosphere to 1} {_ Set to 0 if you don't want to hear about the body's atmosphere. _}\r\n{set reportMaterials to 1} {_ Set to 0 if you don't want to hear about the body's materials. _}\r\n{set reportScanValue to 0} {_ Set to 1 if you want to hear about the body's estimated value. _}\r\n\r\n{_ Fetch from context _}\r\n{set reportbody to BodyDetails(state.eddi_context_body_name, state.eddi_context_body_system)}\r\n{if !reportbody: \r\n {set reportbody to BodyDetails(state.eddi_context_body_name)}\r\n}\r\n\r\n{if !reportbody.name || reportbody.name = \"\":\r\n I'm not sure which body you are asking about.\r\n|else:\r\n {if reportbody.shortname != reportbody.name: \r\n {if reportbody.bodytype:\r\n {reportbody.bodytype}\r\n |else:\r\n {OneOf(\"Body\", \"Object\")} \r\n }\r\n }\r\n {P(reportbody.shortname, \"body\")} is\r\n\r\n {if reportGravity > 0:\r\n {if reportbody.gravity < 0.5:\r\n a low-gravity\r\n |elif reportbody.gravity < 2:\r\n a medium-gravity\r\n |elif reportbody.gravity < 4:\r\n a high-gravity\r\n |else:\r\n an extremely high-gravity\r\n }\r\n |else:\r\n a\r\n }\r\n\r\n {if reportTerraformState > 0:\r\n {if reportbody.terraformState.invariantName = \"Candidate for terraforming\":\r\n terraformable\r\n |elif reportbody.terraformState.invariantName = \"Terraformed\":\r\n terraformed\r\n }\r\n }\r\n\r\n {if find(reportbody.planettype, \"Class\") >= 0 && find(reportbody.planettype, \"gas giant\") >= 0:\r\n {set sudarsky to Occasionally(2, \"Sud-dar-ski\")}\r\n {if find(reportbody.planettype, \"Class V\") >= 0:\r\n {Occasionally(2, \"{Sudarsky} class five\")}\r\n |elif find(reportbody.planettype, \"Class IV\") >= 0:\r\n {Occasionally(2, \"{Sudarsky} class four\")}\r\n |elif find(reportbody.planettype, \"Class III\") >= 0:\r\n {Occasionally(2, \"{Sudarsky} class three\")}\r\n |elif find(reportbody.planettype, \"Class II\") >= 0:\r\n {Occasionally(2, \"{Sudarsky} class two\")}\r\n |elif find(reportbody.planettype, \"Class I\") >= 0:\r\n {Occasionally(2, \"{Sudarsky} class one\")}\r\n }\r\n gas giant\r\n |elif reportbody.planettype:\r\n {P(reportbody.planettype, \"planettype\")}\r\n |else: \r\n {if reportbody.bodytype:\r\n {reportbody.bodytype}\r\n |else:\r\n world\r\n }\r\n }\r\n\r\n {if len(reportbody.rings) && reportRings > 0:\r\n with {if len(reportbody.rings) = 1: a}\r\n {if find(reportbody.reserves, \"Pristine\") >= 0:\r\n pristine\r\n |elif find(reportbody.reserves, \"Major\") >= 0:\r\n rich\r\n }\r\n {set ringname to []}\r\n {set ringcomposition to []}\r\n {for Ring in reportbody.rings:\r\n {if find(ringcomposition, Ring.composition) < 0:\r\n {set ringcomposition to cat(ringcomposition, [Ring.composition])}\r\n }\r\n }\r\n {if len(ringcomposition) > 0:\r\n {List(ringcomposition)}\r\n }\r\n {if find(ringname[0], \"Belt\") >= 0: \r\n {set ring to \"belt\"}\r\n |else:\r\n {set ring to \"ring\"}\r\n }\r\n {ring}{if len(reportbody.rings) > 1 || len(event.rings) > 1:s}\r\n }\r\n\r\n {if reportbody.terraformState.invariantName = \"Terraforming\" && reportTerraformState > 0:\r\n in the process of being terraformed\r\n }\r\n\r\n {if reportbody.landable:\r\n that is suitable for landing\r\n }\r\n . {_ note the full stop}\r\n\r\n {if reportbody.rotationalperiod && reportRotation > 0:\r\n {Pause(100)}\r\n It has a\r\n {if reportbody.rotationalperiod < -20.0:\r\n slow retrograde\r\n |elif reportbody.rotationalperiod < -0.5:\r\n retrograde\r\n |elif reportbody.rotationalperiod < 0.0:\r\n fast retrograde\r\n |elif reportbody.rotationalperiod <= 0.5:\r\n fast\r\n |elif reportbody.rotationalperiod > 20.0:\r\n slow\r\n }\r\n rotational period of {Humanise(round(reportbody.rotationalperiod, 1))} days\r\n {if reportbody.tidallylocked:\r\n and is tidally-locked\r\n }.\r\n }\r\n\r\n {if reportVolcanism: {F(\"Body volcanism report\")} }\r\n\r\n {if reportAtmosphere: {F(\"Body atmosphere report\")} }\r\n\r\n {if reportMaterials: {F(\"Body materials report\")} }\r\n\r\n {if reportScanValue: {F(\"Report last scan value\")} }\r\n}"
},
"Body report summary": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Preferences _}\r\n\r\n{set reportTerraformables to 1} {_ Reports terraformable and terraformed bodies _}\r\n{set reportPlanetTypes to 1} {_ Reports Earth-like and water worlds _}\r\n{set reportMass to 1} {_ Reports notable masses (relative to Earth's) _}\r\n{set reportRadius to 1} {_ Reports notable radii (in kilometers) _}\r\n{set reportDensity to 0} {_ Reports notable densities (in kilograms per cubic meter) _}\r\n{set reportGravity to 1} {_ Reports notable gravity (in G's) for landable bodies _}\r\n{set reportTemperature to 1} {_ Reports notable temperatures (in Kelvin) _}\r\n{set reportMaterials to 1} {_ Reports materials per preferences in the `Body materials` script. _}\r\n{set reportLandableVolcanism to 0} {_ Reports volcanism on landable worlds _}\r\n{set reportRings to 1} {_ Reports ring details _}\r\n{set reportInterestingOrbits to 1} {_ Reports notable orbital characteristics _}\r\n{set reportRapidRotation to 1} {_ Reports very fast rotating bodies _}\r\n\r\n{_ Fetch from context _}\r\n{set reportbody to BodyDetails(state.eddi_context_body_name, state.eddi_context_body_system)}\r\n{if !reportbody: \r\n {set reportbody to BodyDetails(state.eddi_context_body_name)}\r\n}\r\n\r\n{_ Begin processing _}\r\n\r\n{if !reportbody.name || reportbody.name = \"\":\r\n {_ If it's still not possible to get the body name... _}\r\n Which body are you\r\n {OneOf(\"asking about\",\"referring to\")}?\r\n\r\n|else:\r\n\r\n {set notables to []}\r\n\r\n {if reportInterestingOrbits:\r\n\r\n {set orbitNotables to []}\r\n\r\n {if reportbody.eccentricityprobability:\r\n {if reportbody.eccentricityprobability > 99.9:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"incredibly \", OneOf(\"elliptical\", \"oblong\", \"elongated\"))])}\r\n |elif reportbody.eccentricityprobability > 99:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"extremely \", OneOf(\"elliptical\", \"oblong\", \"elongated\"))])}\r\n |elif reportbody.eccentricityprobability > 97:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"unusually \", OneOf(\"elliptical\", \"oblong\", \"elongated\"))])}\r\n }\r\n }\r\n\r\n {if reportbody.inclinationprobability:\r\n {if reportbody.inclinationprobability > 99.9:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"incredibly inclined\")])}\r\n |elif reportbody.inclinationprobability > 99:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"extremely inclined\")])}\r\n |elif reportbody.inclinationprobability > 97:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"unusually inclined\")])}\r\n }\r\n }\r\n\r\n {if reportbody.orbitalperiodprobability:\r\n {if reportbody.orbitalperiod < 0: {set retrograde to cat(\" \", \"retrograde\", \" \")} }\r\n {if reportbody.orbitalperiodprobability < 0.1:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"incredibly fast\", retrograde)])}\r\n |elif reportbody.orbitalperiodprobability < 1:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"extremely fast\", retrograde)])}\r\n |elif reportbody.orbitalperiodprobability < 3:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"unusually fast\", retrograde)])}\r\n }\r\n }\r\n\r\n {if len(orbitNotables) > 0:\r\n {if StartsWithVowel(orbitNotables[0]): {set a to \"an\"} |else: {set a to \"a\"} }\r\n {set cur to 0}\r\n {set length to len(orbitNotables) - 1}\r\n {while cur < len(orbitNotables):\r\n {set orbitdescription to cat(orbitdescription, orbitNotables[cur])}\n {set cur to cur + 1}\n {if cur = length: \r\n {set orbitdescription to cat(orbitdescription, \" and \")}\n |elif cur < length:\r\n {set orbitdescription to cat(orbitdescription, \", \")}\n }\n }\r\n {set notables to cat(notables, [cat(a, \" \", orbitdescription, \" \", \"orbit\")])}\r\n }\r\n }\r\n\r\n {if reportbody.rotationalperiod < 0: {set retrograde to cat(\" \", \"retrograde\", \" \")} }\r\n {if reportRapidRotation && reportbody.rotationalperiodprobability:\r\n {if !retrograde && reportbody.rotationalperiodprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly short rotational period of \", Humanise(reportbody.rotationalperiod), \" days\")])}\r\n |elif !retrograde && reportbody.rotationalperiodprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely short rotational period of \", Humanise(reportbody.rotationalperiod), \" days\")])}\r\n |elif !retrograde && reportbody.rotationalperiodprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually short rotational period of \", Humanise(reportbody.rotationalperiod), \" days\")])}\r\n }\r\n }\r\n\r\n {if reportMass && reportbody.massprobability:\r\n {if reportbody.massprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly low mass at \", Humanise(reportbody.earthmass), \" times Earth's\")])}\r\n |elif reportbody.massprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely low mass at \", Humanise(reportbody.earthmass), \" times Earth's\")])}\r\n |elif reportbody.massprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually low mass at \", Humanise(reportbody.earthmass), \" times Earth's \")])}\r\n |elif reportbody.massprobability > 99.9:\r\n {set notables to cat(notables, [cat(\"an incredibly high mass at \", Humanise(reportbody.earthmass), \" times Earth's\")])}\r\n |elif reportbody.massprobability > 99:\r\n {set notables to cat(notables, [cat(\"an extremely high mass at \", Humanise(reportbody.earthmass), \" times Earth's\")])}\r\n |elif reportbody.massprobability > 97:\r\n {set notables to cat(notables, [cat(\"an unusually high mass at \", Humanise(reportbody.earthmass), \" times Earth's\")])}\r\n }\r\n }\r\n\r\n {if reportRadius && reportbody.radiusprobability:\r\n {if reportbody.radiusprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly low radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n |elif reportbody.radiusprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely low radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n |elif reportbody.radiusprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually low radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n |elif reportbody.radiusprobability > 99.9:\r\n {set notables to cat(notables, [cat(\"an extremely high radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n |elif reportbody.radiusprobability > 99:\r\n {set notables to cat(notables, [cat(\"an incredibly large radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n |elif reportbody.radiusprobability > 97:\r\n {set notables to cat(notables, [cat(\"an unusually high radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n }\r\n }\r\n\r\n {if reportTemperature && reportbody.tempprobability:\r\n {if reportbody.tempprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly low surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n |elif reportbody.tempprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely low surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n |elif reportbody.tempprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually low surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n |elif reportbody.tempprobability > 99.9:\r\n {set notables to cat(notables, [cat(\"an extremely high surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n |elif reportbody.tempprobability > 99:\r\n {set notables to cat(notables, [cat(\"an incredibly high surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n |elif reportbody.tempprobability > 97:\r\n {set notables to cat(notables, [cat(\"an unusually high surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n }\r\n }\r\n\r\n {if reportGravity && reportbody.landable && reportbody.gravityprobability:\r\n {if reportbody.gravityprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly low gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n |elif reportbody.gravityprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely low gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n |elif reportbody.gravityprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually low gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n |elif reportbody.gravityprobability > 99.9:\r\n {set notables to cat(notables, [cat(\"an incredibly high gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n |elif reportbody.gravityprobability > 99:\r\n {set notables to cat(notables, [cat(\"an extremely high gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n |elif reportbody.gravityprobability > 97:\r\n {set notables to cat(notables, [cat(\"an unusually high gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n }\r\n }\r\n\r\n {if reportDensity && reportbody.densityprobability:\r\n {if reportbody.densityprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly low density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n |elif reportbody.densityprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely low density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n |elif reportbody.densityprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually low density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n |elif reportbody.densityprobability > 99.9:\r\n {set notables to cat(notables, [cat(\"an incredibly high density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n |elif reportbody.densityprobability > 99:\r\n {set notables to cat(notables, [cat(\"an extremely high density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n |elif reportbody.densityprobability > 97:\r\n {set notables to cat(notables, [cat(\"an unusually high density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n }\r\n }\r\n\r\n {if reportVolcanism:\r\n {if reportbody.volcanism && reportbody.landable:\r\n {set notables to cat(notables, [cat(OneOf(\"volcanic\", \"tectonic\"), \" activity\")])}\r\n }\r\n }\r\n\r\n {if reportRings:\r\n {if reportbody.rings:\r\n {set ringcompositions to []}\r\n {set cur to 0}\r\n {for ring in reportbody.rings:\r\n {if find(ring.name, \"Ring\") > -1:\r\n {if find(ringcompositions, ring.composition) = -1:\r\n {set ringcompositions to cat(ringcompositions, [cat(ring.composition)])}\r\n }\r\n }\r\n {set cur to cur + 1}\r\n }\r\n {set cur to 0}\r\n {set length to len(ringcompositions) - 1}\r\n {while cur < len(ringcompositions):\r\n {set ringsdescription to cat(ringsdescription, ringcompositions[cur])}\n {set cur to cur + 1}\n {if cur = length: \r\n {set ringsdescription to cat(ringsdescription, \" and \")}\n |elif cur < length:\r\n {set ringsdecription to cat(ringsdescription, \", \")}\n }\n }\r\n {if ringsdescription:\r\n {if len(ringcompositions) = 1:\r\n {if StartsWithVowel(reportbody.reserves): \r\n {set a to \"an \"} \r\n |else: \r\n {set a to \"a \"}\r\n }\r\n {set rings to \"ring\"}\r\n |else:\r\n {set rings to \"rings\"} \r\n }\r\n {if reportbody.reserveLevel.invariantName != \"None\": \r\n {set reserves to reportbody.reserves}\r\n }\r\n {set notables to cat(notables, [cat(a, \" \", reserves, \" \", ringsdescription, \" \", rings)])}\r\n }\r\n }\r\n }\r\n\r\n {if reportTerraformables:\r\n {if reportbody.terraformState.invariantName = \"Candidate for terraforming\":\r\n {set notables to cat(notables, [OneOf(\"potential for terraforming\", \"terraformable conditions\")])}\r\n |elif reportbody.terraformState.invariantName = \"Terraformed\":\r\n {set notables to cat(notables, [\"terraformed conditions\"])}\r\n }\r\n }\r\n\r\n {if reportPlanetTypes:\r\n {if reportbody.planetClass.invariantName = \"Earth-like world\":\r\n {set notables to cat(notables, [\"Earth-like conditions\"])}\r\n |elif reportbody.planetClass.invariantName = \"Water world\":\r\n {set notables to cat(notables, [OneOf(\"abundant liquid water\", \"abundant liquid water at the surface\")])}\r\n }\r\n }\r\n\r\n {_ Begin speaking _}\r\n\r\n {if len(notables) > 0:\r\n {if reportbody.shortname != reportbody.bodyname:\r\n {if reportbody.bodytype:\r\n {reportbody.bodytype}\r\n |else:\r\n Body\r\n }\r\n {P(reportbody.shortname, \"body\")}\r\n |else:\r\n {P(reportbody.bodyname, \"body\")}\r\n }\r\n is\r\n\r\n {if len(notables) = 1:\r\n {set desc to \"notable\"}\r\n |elif len(notables) = 2:\r\n {set desc to OneOf('interesting', 'notable', 'remarkable')}\r\n |elif len(notables) = 3:\r\n {set desc to OneOf('exceptional', 'remarkable')}\r\n |elif len(notables) = 4:\r\n {set desc to OneOf('extraordinary')}\r\n |elif len(notables) >= 5:\r\n {set desc to OneOf('one of a kind', 'unique')}\r\n }\r\n {OneOf(\"{desc},\", \"{if StartsWithVowel(desc): an |else: a } {desc} {P(reportbody.planettype, 'planettype')}\")}\r\n\r\n with {List(notables)}.\r\n }\r\n\r\n {if reportMaterials:\r\n {F(\"Body materials report\")}\r\n }\r\n}",
"name": "Body report summary",
"description": "Function to report on summary details of the contextual body",
"default": true,
"defaultValue": "{_ Preferences _}\r\n\r\n{set reportTerraformables to 1} {_ Reports terraformable and terraformed bodies _}\r\n{set reportPlanetTypes to 1} {_ Reports Earth-like and water worlds _}\r\n{set reportMass to 1} {_ Reports notable masses (relative to Earth's) _}\r\n{set reportRadius to 1} {_ Reports notable radii (in kilometers) _}\r\n{set reportDensity to 0} {_ Reports notable densities (in kilograms per cubic meter) _}\r\n{set reportGravity to 1} {_ Reports notable gravity (in G's) for landable bodies _}\r\n{set reportTemperature to 1} {_ Reports notable temperatures (in Kelvin) _}\r\n{set reportMaterials to 1} {_ Reports materials per preferences in the `Body materials` script. _}\r\n{set reportLandableVolcanism to 0} {_ Reports volcanism on landable worlds _}\r\n{set reportRings to 1} {_ Reports ring details _}\r\n{set reportInterestingOrbits to 1} {_ Reports notable orbital characteristics _}\r\n{set reportRapidRotation to 1} {_ Reports very fast rotating bodies _}\r\n\r\n{_ Fetch from context _}\r\n{set reportbody to BodyDetails(state.eddi_context_body_name, state.eddi_context_body_system)}\r\n{if !reportbody: \r\n {set reportbody to BodyDetails(state.eddi_context_body_name)}\r\n}\r\n\r\n{_ Begin processing _}\r\n\r\n{if !reportbody.name || reportbody.name = \"\":\r\n {_ If it's still not possible to get the body name... _}\r\n Which body are you\r\n {OneOf(\"asking about\",\"referring to\")}?\r\n\r\n|else:\r\n\r\n {set notables to []}\r\n\r\n {if reportInterestingOrbits:\r\n\r\n {set orbitNotables to []}\r\n\r\n {if reportbody.eccentricityprobability:\r\n {if reportbody.eccentricityprobability > 99.9:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"incredibly \", OneOf(\"elliptical\", \"oblong\", \"elongated\"))])}\r\n |elif reportbody.eccentricityprobability > 99:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"extremely \", OneOf(\"elliptical\", \"oblong\", \"elongated\"))])}\r\n |elif reportbody.eccentricityprobability > 97:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"unusually \", OneOf(\"elliptical\", \"oblong\", \"elongated\"))])}\r\n }\r\n }\r\n\r\n {if reportbody.inclinationprobability:\r\n {if reportbody.inclinationprobability > 99.9:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"incredibly inclined\")])}\r\n |elif reportbody.inclinationprobability > 99:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"extremely inclined\")])}\r\n |elif reportbody.inclinationprobability > 97:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"unusually inclined\")])}\r\n }\r\n }\r\n\r\n {if reportbody.orbitalperiodprobability:\r\n {if reportbody.orbitalperiod < 0: {set retrograde to cat(\" \", \"retrograde\", \" \")} }\r\n {if reportbody.orbitalperiodprobability < 0.1:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"incredibly fast\", retrograde)])}\r\n |elif reportbody.orbitalperiodprobability < 1:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"extremely fast\", retrograde)])}\r\n |elif reportbody.orbitalperiodprobability < 3:\r\n {set orbitNotables to cat(orbitNotables, [cat(\"unusually fast\", retrograde)])}\r\n }\r\n }\r\n\r\n {if len(orbitNotables) > 0:\r\n {if StartsWithVowel(orbitNotables[0]): {set a to \"an\"} |else: {set a to \"a\"} }\r\n {set cur to 0}\r\n {set length to len(orbitNotables) - 1}\r\n {while cur < len(orbitNotables):\r\n {set orbitdescription to cat(orbitdescription, orbitNotables[cur])}\n {set cur to cur + 1}\n {if cur = length: \r\n {set orbitdescription to cat(orbitdescription, \" and \")}\n |elif cur < length:\r\n {set orbitdescription to cat(orbitdescription, \", \")}\n }\n }\r\n {set notables to cat(notables, [cat(a, \" \", orbitdescription, \" \", \"orbit\")])}\r\n }\r\n }\r\n\r\n {if reportbody.rotationalperiod < 0: {set retrograde to cat(\" \", \"retrograde\", \" \")} }\r\n {if reportRapidRotation && reportbody.rotationalperiodprobability:\r\n {if !retrograde && reportbody.rotationalperiodprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly short rotational period of \", Humanise(reportbody.rotationalperiod), \" days\")])}\r\n |elif !retrograde && reportbody.rotationalperiodprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely short rotational period of \", Humanise(reportbody.rotationalperiod), \" days\")])}\r\n |elif !retrograde && reportbody.rotationalperiodprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually short rotational period of \", Humanise(reportbody.rotationalperiod), \" days\")])}\r\n }\r\n }\r\n\r\n {if reportMass && reportbody.massprobability:\r\n {if reportbody.massprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly low mass at \", Humanise(reportbody.earthmass), \" times Earth's\")])}\r\n |elif reportbody.massprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely low mass at \", Humanise(reportbody.earthmass), \" times Earth's\")])}\r\n |elif reportbody.massprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually low mass at \", Humanise(reportbody.earthmass), \" times Earth's \")])}\r\n |elif reportbody.massprobability > 99.9:\r\n {set notables to cat(notables, [cat(\"an incredibly high mass at \", Humanise(reportbody.earthmass), \" times Earth's\")])}\r\n |elif reportbody.massprobability > 99:\r\n {set notables to cat(notables, [cat(\"an extremely high mass at \", Humanise(reportbody.earthmass), \" times Earth's\")])}\r\n |elif reportbody.massprobability > 97:\r\n {set notables to cat(notables, [cat(\"an unusually high mass at \", Humanise(reportbody.earthmass), \" times Earth's\")])}\r\n }\r\n }\r\n\r\n {if reportRadius && reportbody.radiusprobability:\r\n {if reportbody.radiusprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly low radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n |elif reportbody.radiusprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely low radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n |elif reportbody.radiusprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually low radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n |elif reportbody.radiusprobability > 99.9:\r\n {set notables to cat(notables, [cat(\"an extremely high radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n |elif reportbody.radiusprobability > 99:\r\n {set notables to cat(notables, [cat(\"an incredibly large radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n |elif reportbody.radiusprobability > 97:\r\n {set notables to cat(notables, [cat(\"an unusually high radius of \", Humanise(reportbody.radius), \" kilometers\")])}\r\n }\r\n }\r\n\r\n {if reportTemperature && reportbody.tempprobability:\r\n {if reportbody.tempprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly low surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n |elif reportbody.tempprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely low surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n |elif reportbody.tempprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually low surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n |elif reportbody.tempprobability > 99.9:\r\n {set notables to cat(notables, [cat(\"an extremely high surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n |elif reportbody.tempprobability > 99:\r\n {set notables to cat(notables, [cat(\"an incredibly high surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n |elif reportbody.tempprobability > 97:\r\n {set notables to cat(notables, [cat(\"an unusually high surface temperature of \", Humanise(reportbody.temperature), \" Kelvin\")])}\r\n }\r\n }\r\n\r\n {if reportGravity && reportbody.landable && reportbody.gravityprobability:\r\n {if reportbody.gravityprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly low gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n |elif reportbody.gravityprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely low gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n |elif reportbody.gravityprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually low gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n |elif reportbody.gravityprobability > 99.9:\r\n {set notables to cat(notables, [cat(\"an incredibly high gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n |elif reportbody.gravityprobability > 99:\r\n {set notables to cat(notables, [cat(\"an extremely high gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n |elif reportbody.gravityprobability > 97:\r\n {set notables to cat(notables, [cat(\"an unusually high gravity of \", Humanise(reportbody.gravity), \" times Earth's\")])}\r\n }\r\n }\r\n\r\n {if reportDensity && reportbody.densityprobability:\r\n {if reportbody.densityprobability < 0.1:\r\n {set notables to cat(notables, [cat(\"an incredibly low density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n |elif reportbody.densityprobability < 1:\r\n {set notables to cat(notables, [cat(\"an extremely low density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n |elif reportbody.densityprobability < 3:\r\n {set notables to cat(notables, [cat(\"an unusually low density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n |elif reportbody.densityprobability > 99.9:\r\n {set notables to cat(notables, [cat(\"an incredibly high density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n |elif reportbody.densityprobability > 99:\r\n {set notables to cat(notables, [cat(\"an extremely high density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n |elif reportbody.densityprobability > 97:\r\n {set notables to cat(notables, [cat(\"an unusually high density of \", Humanise(reportbody.density), \" kilograms per cubic meter\")])}\r\n }\r\n }\r\n\r\n {if reportVolcanism:\r\n {if reportbody.volcanism && reportbody.landable:\r\n {set notables to cat(notables, [cat(OneOf(\"volcanic\", \"tectonic\"), \" activity\")])}\r\n }\r\n }\r\n\r\n {if reportRings:\r\n {if reportbody.rings:\r\n {set ringcompositions to []}\r\n {set cur to 0}\r\n {for ring in reportbody.rings:\r\n {if find(ring.name, \"Ring\") > -1:\r\n {if find(ringcompositions, ring.composition) = -1:\r\n {set ringcompositions to cat(ringcompositions, [cat(ring.composition)])}\r\n }\r\n }\r\n {set cur to cur + 1}\r\n }\r\n {set cur to 0}\r\n {set length to len(ringcompositions) - 1}\r\n {while cur < len(ringcompositions):\r\n {set ringsdescription to cat(ringsdescription, ringcompositions[cur])}\n {set cur to cur + 1}\n {if cur = length: \r\n {set ringsdescription to cat(ringsdescription, \" and \")}\n |elif cur < length:\r\n {set ringsdecription to cat(ringsdescription, \", \")}\n }\n }\r\n {if ringsdescription:\r\n {if len(ringcompositions) = 1:\r\n {if StartsWithVowel(reportbody.reserves): \r\n {set a to \"an \"} \r\n |else: \r\n {set a to \"a \"}\r\n }\r\n {set rings to \"ring\"}\r\n |else:\r\n {set rings to \"rings\"} \r\n }\r\n {if reportbody.reserveLevel.invariantName != \"None\": \r\n {set reserves to reportbody.reserves}\r\n }\r\n {set notables to cat(notables, [cat(a, \" \", reserves, \" \", ringsdescription, \" \", rings)])}\r\n }\r\n }\r\n }\r\n\r\n {if reportTerraformables:\r\n {if reportbody.terraformState.invariantName = \"Candidate for terraforming\":\r\n {set notables to cat(notables, [OneOf(\"potential for terraforming\", \"terraformable conditions\")])}\r\n |elif reportbody.terraformState.invariantName = \"Terraformed\":\r\n {set notables to cat(notables, [\"terraformed conditions\"])}\r\n }\r\n }\r\n\r\n {if reportPlanetTypes:\r\n {if reportbody.planetClass.invariantName = \"Earth-like world\":\r\n {set notables to cat(notables, [\"Earth-like conditions\"])}\r\n |elif reportbody.planetClass.invariantName = \"Water world\":\r\n {set notables to cat(notables, [OneOf(\"abundant liquid water\", \"abundant liquid water at the surface\")])}\r\n }\r\n }\r\n\r\n {_ Begin speaking _}\r\n\r\n {if len(notables) > 0:\r\n {if reportbody.shortname != reportbody.bodyname:\r\n {if reportbody.bodytype:\r\n {reportbody.bodytype}\r\n |else:\r\n Body\r\n }\r\n {P(reportbody.shortname, \"body\")}\r\n |else:\r\n {P(reportbody.bodyname, \"body\")}\r\n }\r\n is\r\n\r\n {if len(notables) = 1:\r\n {set desc to \"notable\"}\r\n |elif len(notables) = 2:\r\n {set desc to OneOf('interesting', 'notable', 'remarkable')}\r\n |elif len(notables) = 3:\r\n {set desc to OneOf('exceptional', 'remarkable')}\r\n |elif len(notables) = 4:\r\n {set desc to OneOf('extraordinary')}\r\n |elif len(notables) >= 5:\r\n {set desc to OneOf('one of a kind', 'unique')}\r\n }\r\n {OneOf(\"{desc},\", \"{if StartsWithVowel(desc): an |else: a } {desc} {P(reportbody.planettype, 'planettype')}\")}\r\n\r\n with {List(notables)}.\r\n }\r\n\r\n {if reportMaterials:\r\n {F(\"Body materials report\")}\r\n }\r\n}"
},
"Body scanned": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context _}\r\n{SetState('eddi_context_last_subject', 'body')}\r\n{SetState('eddi_context_last_action', 'scan')}\r\n{SetState('eddi_context_body_system', system.name)}\r\n{SetState('eddi_context_body_name', event.name)}\r\n{SetState('eddi_context_last_scan_estimated_value', event.estimatedvalue)}\r\n\r\n{_ Preferences _}\r\n\r\n{set fullBodyReport to 0}\r\n\r\n{_ Process the event _}\r\n\r\n{if ship.Role.edname = \"Exploration\" || ship.Role.edname = \"Multipurpose\":\r\n {Pause(500)}\r\n {if fullBodyReport:\r\n {F(\"Body report\")}\r\n |else:\r\n {F(\"Body report summary\")}\r\n }\r\n}",
"name": "Body scanned",
"description": "Triggered when you complete a scan of a planetary body",
"default": true,
"defaultValue": "{_ Context _}\r\n{SetState('eddi_context_last_subject', 'body')}\r\n{SetState('eddi_context_last_action', 'scan')}\r\n{SetState('eddi_context_body_system', system.name)}\r\n{SetState('eddi_context_body_name', event.name)}\r\n{SetState('eddi_context_last_scan_estimated_value', event.estimatedvalue)}\r\n\r\n{_ Preferences _}\r\n\r\n{set fullBodyReport to 0}\r\n\r\n{_ Process the event _}\r\n\r\n{if ship.Role.edname = \"Exploration\" || ship.Role.edname = \"Multipurpose\":\r\n {Pause(500)}\r\n {if fullBodyReport:\r\n {F(\"Body report\")}\r\n |else:\r\n {F(\"Body report summary\")}\r\n }\r\n}"
},
"Body volcanism report": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Fetch from context _}\r\n{set reportbody to BodyDetails(state.eddi_context_body_name, state.eddi_context_body_system)}\r\n{if !reportbody: \r\n {set reportbody to BodyDetails(state.eddi_context_body_name)}\r\n}\r\n\r\n{if !reportbody.name || reportbody.name = \"\":\r\n I'm not sure which body you are asking about.\r\n|else:\r\n {if (reportbody.volcanism || len(reportbody.volcanism) > 0) && reportVolcanism > 0:\r\n {if reportbody.name = reportbody.shortname:\r\n {P(reportbody.shortname, \"body\")} {OneOf(\"has\", \"contains\")}\r\n |else:\r\n {OneOf(\"I detect\", \r\n \"I am detecting\", \r\n \"Sensors detect\", \r\n \"This {reportbody.bodytype} has\", \r\n )}\r\n }\r\n\r\n {if reportbody.volcanism.type = \"Geysers\":\r\n {if reportbody.volcanism.invariantAmount = 'Major':\r\n high numbers of\r\n |elif reportbody.volcanism.invariantAmount = 'Minor':\r\n low numbers of\r\n }\r\n active {reportbody.volcanism.composition} geysers\r\n {Occasionally(3, \"at the surface\")}.\r\n |else:\r\n {if reportbody.volcanism.invariantAmount = 'Major':\r\n high levels of\r\n |elif reportbody.volcanism.invariantAmount = 'Minor':\r\n low levels of\r\n }\r\n active {reportbody.volcanism.composition} \r\n {OneOf(\r\n \"lava flows {Occasionally(3, \\\"at the surface\\\")}\",\r\n OneOf(\"magma flows near the surface\", \"sub-surface magma flows\")\r\n )}.\r\n }\r\n }\r\n}",
"name": "Body volcanism report",
"description": "Report on the volcanism of the contextual body",
"default": true,
"defaultValue": "{_ Fetch from context _}\r\n{set reportbody to BodyDetails(state.eddi_context_body_name, state.eddi_context_body_system)}\r\n{if !reportbody: \r\n {set reportbody to BodyDetails(state.eddi_context_body_name)}\r\n}\r\n\r\n{if !reportbody.name || reportbody.name = \"\":\r\n I'm not sure which body you are asking about.\r\n|else:\r\n {if (reportbody.volcanism || len(reportbody.volcanism) > 0) && reportVolcanism > 0:\r\n {if reportbody.name = reportbody.shortname:\r\n {P(reportbody.shortname, \"body\")} {OneOf(\"has\", \"contains\")}\r\n |else:\r\n {OneOf(\"I detect\", \r\n \"I am detecting\", \r\n \"Sensors detect\", \r\n \"This {reportbody.bodytype} has\", \r\n )}\r\n }\r\n\r\n {if reportbody.volcanism.type = \"Geysers\":\r\n {if reportbody.volcanism.invariantAmount = 'Major':\r\n high numbers of\r\n |elif reportbody.volcanism.invariantAmount = 'Minor':\r\n low numbers of\r\n }\r\n active {reportbody.volcanism.composition} geysers\r\n {Occasionally(3, \"at the surface\")}.\r\n |else:\r\n {if reportbody.volcanism.invariantAmount = 'Major':\r\n high levels of\r\n |elif reportbody.volcanism.invariantAmount = 'Minor':\r\n low levels of\r\n }\r\n active {reportbody.volcanism.composition} \r\n {OneOf(\r\n \"lava flows {Occasionally(3, \\\"at the surface\\\")}\",\r\n OneOf(\"magma flows near the surface\", \"sub-surface magma flows\")\r\n )}.\r\n }\r\n }\r\n}"
},
"Bond awarded": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Bond awarded }\r\n{_ Triggered when you are awarded a combat bond }\r\n\r\n\r\n{_ Context }\r\n{SetState('eddi_context_last_subject', 'bond')}\r\n{SetState('eddi_context_last_action', 'award')}\r\n{SetState('eddi_context_bond_amount', event.reward)}\r\n{SetState('eddi_context_bond_faction', event.awardingfaction)}\r\n\r\n{P(event.victimfaction, \"faction\")} ship {OneOf(\"destroyed\",\"eliminated\",\"down\")},\r\n\r\n{Humanise(event.reward)} credits awarded from {P(event.awardingfaction, \"faction\")}.\r\n",
"name": "Bond awarded",
"description": "Triggered when you are awarded a combat bond",
"default": true,
"defaultValue": "{_ Bond awarded }\r\n{_ Triggered when you are awarded a combat bond }\r\n\r\n\r\n{_ Context }\r\n{SetState('eddi_context_last_subject', 'bond')}\r\n{SetState('eddi_context_last_action', 'award')}\r\n{SetState('eddi_context_bond_amount', event.reward)}\r\n{SetState('eddi_context_bond_faction', event.awardingfaction)}\r\n\r\n{P(event.victimfaction, \"faction\")} ship {OneOf(\"destroyed\",\"eliminated\",\"down\")},\r\n\r\n{Humanise(event.reward)} credits awarded from {P(event.awardingfaction, \"faction\")}.\r\n"
},
"Bond redeemed": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'bond')}\r\n{SetState('eddi_context_last_action', 'redeem')}\r\n{SetState('eddi_context_bond_amount', event.amount)}\r\n\r\nCombat bonds for {Humanise(event.amount)} credits \r\n{Occasionally(2, OneOf(\"have been\", \"have now been\"))}\r\n{OneOf(\"redeemed\", \"claimed\")}\r\n\r\n{Occasionally(2, \"\r\n {if len(event.rewards) = 1 && len(event.rewards[0].faction) > 0:\r\n from {P(event.rewards[0].faction, \"faction\")}\r\n |else:\r\n . \r\n {set cur to 0}\r\n {while cur < len(event.rewards):\r\n {if len(event.rewards[cur].faction) > 0:\r\n {if cur = 0:\r\n |elif cur < len(event.rewards) - 1:\r\n , \r\n |else:\r\n and\r\n }\r\n {Humanise(event.rewards[cur].amount)} credits from\r\n {P(event.rewards[cur].faction, \"faction\")} \r\n {set cur to cur + 1}\r\n }\r\n }\r\n }\r\n\")}\r\n\r\n{if event.brokerpercentage && event.brokerpercentage > 0:\r\n after deducting\r\n {OneOf(\"payments\", \"fees\")} of\r\n {Humanise(round((event.amount / (100 - event.brokerpercentage)) * event.brokerpercentage, 0))} credits\r\n}.",
"name": "Bond redeemed",
"description": "Triggered when you redeem a combat bond",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'bond')}\r\n{SetState('eddi_context_last_action', 'redeem')}\r\n{SetState('eddi_context_bond_amount', event.amount)}\r\n\r\nCombat bonds for {Humanise(event.amount)} credits \r\n{Occasionally(2, OneOf(\"have been\", \"have now been\"))}\r\n{OneOf(\"redeemed\", \"claimed\")}\r\n\r\n{Occasionally(2, \"\r\n {if len(event.rewards) = 1 && len(event.rewards[0].faction) > 0:\r\n from {P(event.rewards[0].faction, \"faction\")}\r\n |else:\r\n . \r\n {set cur to 0}\r\n {while cur < len(event.rewards):\r\n {if len(event.rewards[cur].faction) > 0:\r\n {if cur = 0:\r\n |elif cur < len(event.rewards) - 1:\r\n , \r\n |else:\r\n and\r\n }\r\n {Humanise(event.rewards[cur].amount)} credits from\r\n {P(event.rewards[cur].faction, \"faction\")} \r\n {set cur to cur + 1}\r\n }\r\n }\r\n }\r\n\")}\r\n\r\n{if event.brokerpercentage && event.brokerpercentage > 0:\r\n after deducting\r\n {OneOf(\"payments\", \"fees\")} of\r\n {Humanise(round((event.amount / (100 - event.brokerpercentage)) * event.brokerpercentage, 0))} credits\r\n}."
},
"Bounty awarded": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'bounty')}\r\n{SetState('eddi_context_last_action', 'award')}\r\n{SetState('eddi_context_bounty_name', event.target)}\r\n{SetState('eddi_context_bounty_faction', event.faction)}\r\n{SetState('eddi_context_bounty_amount', event.reward)}\r\n\r\n{Pause(500)}\r\n{if len(event.rewards) = 1:\r\n Bounty voucher of {Humanise(event.reward)} credits received from {P(event.rewards[0].faction, \"faction\")}\r\n|elif len(event.rewards) > 1:\r\n {len(event.rewards)} bounty vouchers received for a total of {Humanise(event.reward)} credits\r\n}\r\n{if event.shared:\r\n to share between yourself and your wing-mates\r\n}.\r\n",
"name": "Bounty awarded",
"description": "Triggered when you are awarded a bounty",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'bounty')}\r\n{SetState('eddi_context_last_action', 'award')}\r\n{SetState('eddi_context_bounty_name', event.target)}\r\n{SetState('eddi_context_bounty_faction', event.faction)}\r\n{SetState('eddi_context_bounty_amount', event.reward)}\r\n\r\n{Pause(500)}\r\n{if len(event.rewards) = 1:\r\n Bounty voucher of {Humanise(event.reward)} credits received from {P(event.rewards[0].faction, \"faction\")}\r\n|elif len(event.rewards) > 1:\r\n {len(event.rewards)} bounty vouchers received for a total of {Humanise(event.reward)} credits\r\n}\r\n{if event.shared:\r\n to share between yourself and your wing-mates\r\n}.\r\n"
},
"Bounty incurred": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'bounty')}\r\n{SetState('eddi_context_last_action', 'incur')}\r\n{SetState('eddi_context_bounty_name', event.victim)}\r\n{SetState('eddi_context_bounty_faction', event.faction)}\r\n{SetState('eddi_context_bounty_amount', event.bounty)}\r\n\r\n{P(event.faction, \"faction\")} just put a bounty of {Humanise(event.bounty)} credits on your head for {event.crime}.",
"name": "Bounty incurred",
"description": "Triggered when you incur a bounty",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'bounty')}\r\n{SetState('eddi_context_last_action', 'incur')}\r\n{SetState('eddi_context_bounty_name', event.victim)}\r\n{SetState('eddi_context_bounty_faction', event.faction)}\r\n{SetState('eddi_context_bounty_amount', event.bounty)}\r\n\r\n{P(event.faction, \"faction\")} just put a bounty of {Humanise(event.bounty)} credits on your head for {event.crime}."
},
"Bounty paid": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'bounty')}\r\n{SetState('eddi_context_last_action', 'pay')}\r\n{SetState('eddi_context_fine_amount', event.amount)}\r\n\r\n\r\nPaid bounty of {Humanise(event.amount)} credits.",
"name": "Bounty paid",
"description": "Triggered when you pay a bounty",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'bounty')}\r\n{SetState('eddi_context_last_action', 'pay')}\r\n{SetState('eddi_context_fine_amount', event.amount)}\r\n\r\n\r\nPaid bounty of {Humanise(event.amount)} credits."
},
"Bounty redeemed": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'bounty')}\r\n{SetState('eddi_context_last_action', 'redeem')}\r\n{SetState('eddi_context_bounty_amount', event.amount)}\r\n\r\nBounty vouchers for {Humanise(event.amount)} credits \r\n{Occasionally(2, OneOf(\"have been\", \"have now been\"))}\r\n{OneOf(\"redeemed\", \"claimed\")}\r\n\r\n{Occasionally(2, \"\r\n {if len(event.rewards) = 1 && len(event.rewards[0].faction) > 0:\r\n from {P(event.rewards[0].faction, \"faction\")}\r\n |else:\r\n . \r\n {set cur to 0}\r\n {while cur < len(event.rewards):\r\n {if len(event.rewards[cur].faction) > 0:\r\n {if cur = 0:\r\n |elif cur < len(event.rewards) - 1:\r\n , \r\n |else:\r\n and\r\n }\r\n {Humanise(event.rewards[cur].amount)} credits from\r\n {P(event.rewards[cur].faction, \"faction\")} \r\n {set cur to cur + 1}\r\n }\r\n }\r\n }\r\n\")}\r\n\r\n{if event.brokerpercentage && event.brokerpercentage > 0:\r\n after deducting\r\n {OneOf(\"payments\", \"fees\")} of\r\n {Humanise(round((event.amount / (100 - event.brokerpercentage)) * event.brokerpercentage, 0))} credits\r\n}.",
"name": "Bounty redeemed",
"description": "Triggered when you redeem a bounty voucher",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'bounty')}\r\n{SetState('eddi_context_last_action', 'redeem')}\r\n{SetState('eddi_context_bounty_amount', event.amount)}\r\n\r\nBounty vouchers for {Humanise(event.amount)} credits \r\n{Occasionally(2, OneOf(\"have been\", \"have now been\"))}\r\n{OneOf(\"redeemed\", \"claimed\")}\r\n\r\n{Occasionally(2, \"\r\n {if len(event.rewards) = 1 && len(event.rewards[0].faction) > 0:\r\n from {P(event.rewards[0].faction, \"faction\")}\r\n |else:\r\n . \r\n {set cur to 0}\r\n {while cur < len(event.rewards):\r\n {if len(event.rewards[cur].faction) > 0:\r\n {if cur = 0:\r\n |elif cur < len(event.rewards) - 1:\r\n , \r\n |else:\r\n and\r\n }\r\n {Humanise(event.rewards[cur].amount)} credits from\r\n {P(event.rewards[cur].faction, \"faction\")} \r\n {set cur to cur + 1}\r\n }\r\n }\r\n }\r\n\")}\r\n\r\n{if event.brokerpercentage && event.brokerpercentage > 0:\r\n after deducting\r\n {OneOf(\"payments\", \"fees\")} of\r\n {Humanise(round((event.amount / (100 - event.brokerpercentage)) * event.brokerpercentage, 0))} credits\r\n}."
},
"Cargo depot": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Cargo depot }\r\n{_ Triggered when engaging with a mission depot }\r\n\r\n\r\n{if event.updatetype = \"Collect\":\r\n You have collected {event.amount} tonne{if event.amount != 1:s} of {event.commodity} from the mission depot.\r\n|elif event.updatetype = \"Deliver\":\r\n You have delivered {event.amount} tonne{if event.amount != 1:s} of {event.commodity} to the mission depot.\r\n\r\n {Pause(500)}\r\n {set remaining to event.totaltodeliver - event.delivered}\r\n {set haulage to HaulageDetails(event.missionid)}\r\n\r\n {if find(haulage.name, \"Wing\") > -1:\r\n Wing\r\n |elif find(haulage.name, \"Rank\") > -1:\r\n Naval\r\n |else:\r\n Solo\r\n }\r\n\r\n {if remaining = 0:\r\n mission requirements are now completed.\r\n |else:\r\n mission is now {round(event.delivered / event.totaltodeliver * 100, 0)} percent complete.\r\n }\r\n}\r\n\r\n",
"name": "Cargo depot",
"description": "Triggered when engaging with a mission depot",
"default": true,
"defaultValue": "{_ Cargo depot }\r\n{_ Triggered when engaging with a mission depot }\r\n\r\n\r\n{if event.updatetype = \"Collect\":\r\n You have collected {event.amount} tonne{if event.amount != 1:s} of {event.commodity} from the mission depot.\r\n|elif event.updatetype = \"Deliver\":\r\n You have delivered {event.amount} tonne{if event.amount != 1:s} of {event.commodity} to the mission depot.\r\n\r\n {Pause(500)}\r\n {set remaining to event.totaltodeliver - event.delivered}\r\n {set haulage to HaulageDetails(event.missionid)}\r\n\r\n {if find(haulage.name, \"Wing\") > -1:\r\n Wing\r\n |elif find(haulage.name, \"Rank\") > -1:\r\n Naval\r\n |else:\r\n Solo\r\n }\r\n\r\n {if remaining = 0:\r\n mission requirements are now completed.\r\n |else:\r\n mission is now {round(event.delivered / event.totaltodeliver * 100, 0)} percent complete.\r\n }\r\n}\r\n\r\n"
},
"Cargo report": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Cargo report }\r\n{_ Report current cargo manifest }\r\n\r\n{set cargocarried to 0}\r\n{set haulage to 0}\r\n{set illegal to false}\r\n{set stolen to false}\r\n\r\n{if len(inventory) > 0:\r\n {for cargo in inventory:\r\n {set cargocarried to cargocarried + cargo.total}\r\n {set haulage to haulage + cargo.haulage}\r\n {if cargo.stolen > 0: {set stolen to true}}\r\n {if status.docked:\r\n {for prohibited in station.prohibited:\r\n {if cargo.name = prohibited.name: {set illegal to true}}\r\n }\r\n }\r\n }\r\n}\r\n\r\n{if cargocarried > 0:\r\n {if cargocarried = ship.cargocapacity:\r\n Your cargo {OneOf(\"bay\", \"hold\")} is full\r\n |else:\r\n You are carrying {cargocarried} tonne{if cargocarried != 1:s}\r\n }\r\n\r\n {if len(inventory) = 1:\r\n {if inventory[0].name = \"Limpet\":\r\n of limpets.\r\n |else:\r\n of {inventory[0].name}.\r\n {if haulage = cargocarried:\r\n Note: All cargo is mission related haulage.\r\n }\r\n }\r\n |else:\r\n {if cargocarried < ship.cargocapacity: of cargo}.\r\n {Occasionally(2, \"Cargo\")} {OneOf(\"Manifest\", \"Inventory\")} is as follows:\r\n\r\n {set c to []}\r\n {for cargo in inventory:\r\n {if cargo.total > 0:\r\n {set c to cat(c, [cargo])}\r\n }\r\n }\r\n\r\n {set position to 0}\r\n {for cargo in c:\r\n {cargo.total} tonne{if cargo.total != 1:s} of \r\n {if cargo.name = \"Limpet\":\r\n limpets\r\n |else:\r\n {cargo.name}\r\n }\r\n {set position to position + 1}\r\n {if position = len(c) - 1: and |else:,}\r\n }\r\n {if haulage > 0:\r\n Note: {haulage} tonne{if haulage != 1:s} of your manifest is mission related haulage.\r\n }\r\n }.\r\n\r\n {if cargocarried < ship.cargocapacity:\r\n {set free to ship.cargocapacity - cargocarried}\r\n You {OneOf(\"have {free} tonne{if free != 1:s} free\",\r\n \"have {free} tonne{if free != 1:s} of free space\",\r\n \"can carry an additional {free} tonne{if free != 1:s}\")}.\r\n }\r\n\r\n {if stolen || illegal:\r\n Warning: You are carrying\r\n {if stolen: stolen goods}\r\n {if illegal:\r\n {if stolen:, and }\r\n goods that are illegal in this jurisdiction\r\n }.\r\n }\r\n\r\n|else:\r\n {OneOf(\"Your cargo bay is empty.\",\"You have no cargo.\",\"You are carrying no cargo.\")}\r\n}",
"name": "Cargo report",
"description": "Report current cargo manifest",
"default": true,
"defaultValue": "{_ Cargo report }\r\n{_ Report current cargo manifest }\r\n\r\n{set cargocarried to 0}\r\n{set haulage to 0}\r\n{set illegal to false}\r\n{set stolen to false}\r\n\r\n{if len(inventory) > 0:\r\n {for cargo in inventory:\r\n {set cargocarried to cargocarried + cargo.total}\r\n {set haulage to haulage + cargo.haulage}\r\n {if cargo.stolen > 0: {set stolen to true}}\r\n {if status.docked:\r\n {for prohibited in station.prohibited:\r\n {if cargo.name = prohibited.name: {set illegal to true}}\r\n }\r\n }\r\n }\r\n}\r\n\r\n{if cargocarried > 0:\r\n {if cargocarried = ship.cargocapacity:\r\n Your cargo {OneOf(\"bay\", \"hold\")} is full\r\n |else:\r\n You are carrying {cargocarried} tonne{if cargocarried != 1:s}\r\n }\r\n\r\n {if len(inventory) = 1:\r\n {if inventory[0].name = \"Limpet\":\r\n of limpets.\r\n |else:\r\n of {inventory[0].name}.\r\n {if haulage = cargocarried:\r\n Note: All cargo is mission related haulage.\r\n }\r\n }\r\n |else:\r\n {if cargocarried < ship.cargocapacity: of cargo}.\r\n {Occasionally(2, \"Cargo\")} {OneOf(\"Manifest\", \"Inventory\")} is as follows:\r\n\r\n {set c to []}\r\n {for cargo in inventory:\r\n {if cargo.total > 0:\r\n {set c to cat(c, [cargo])}\r\n }\r\n }\r\n\r\n {set position to 0}\r\n {for cargo in c:\r\n {cargo.total} tonne{if cargo.total != 1:s} of \r\n {if cargo.name = \"Limpet\":\r\n limpets\r\n |else:\r\n {cargo.name}\r\n }\r\n {set position to position + 1}\r\n {if position = len(c) - 1: and |else:,}\r\n }\r\n {if haulage > 0:\r\n Note: {haulage} tonne{if haulage != 1:s} of your manifest is mission related haulage.\r\n }\r\n }.\r\n\r\n {if cargocarried < ship.cargocapacity:\r\n {set free to ship.cargocapacity - cargocarried}\r\n You {OneOf(\"have {free} tonne{if free != 1:s} free\",\r\n \"have {free} tonne{if free != 1:s} of free space\",\r\n \"can carry an additional {free} tonne{if free != 1:s}\")}.\r\n }\r\n\r\n {if stolen || illegal:\r\n Warning: You are carrying\r\n {if stolen: stolen goods}\r\n {if illegal:\r\n {if stolen:, and }\r\n goods that are illegal in this jurisdiction\r\n }.\r\n }\r\n\r\n|else:\r\n {OneOf(\"Your cargo bay is empty.\",\"You have no cargo.\",\"You are carrying no cargo.\")}\r\n}"
},
"Cargo scoop": {
"enabled": true,
"priority": 3,
"responder": true,
"script": null,
"name": "Cargo scoop",
"description": "Triggered when you deploy or retract your cargo scoop",
"default": true,
"defaultValue": null
},
"Cargo wingupdate": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Cargo wingupdate }\r\n{_ Triggered when a wing-mate collects or delivers cargo for a wing mission }\r\n\r\n\r\n{if event.updatetype = \"Collect\":\r\n Your wing mate has collected {event.amount} tonne{if event.amount != 1:s}\r\n {if event.commodity != \"Unknown\": of {event.commodity}} from the mission depot.\r\n|elif event.updatetype = \"Deliver\":\r\n Your wing mate has delivered {event.amount} tonne{if event.amount != 1:s} \r\n {if event.commodity != \"Unknown\": of {event.commodity}} to the mission depot.\r\n}\r\n\r\n{Pause(500)}\r\n{set remaining to event.totaltodeliver - event.delivered}\r\n{if remaining = 0:\r\n Wing mission requirements are now completed.\r\n|elif event.updatetype = \"Deliver\":\r\n Wing mission is now {round(event.delivered / event.totaltodeliver * 100, 0)} percent complete.\r\n}\r\n",
"name": "Cargo wingupdate",
"description": "Triggered when a wing-mate collects or delivers cargo for a wing mission",
"default": true,
"defaultValue": "{_ Cargo wingupdate }\r\n{_ Triggered when a wing-mate collects or delivers cargo for a wing mission }\r\n\r\n\r\n{if event.updatetype = \"Collect\":\r\n Your wing mate has collected {event.amount} tonne{if event.amount != 1:s}\r\n {if event.commodity != \"Unknown\": of {event.commodity}} from the mission depot.\r\n|elif event.updatetype = \"Deliver\":\r\n Your wing mate has delivered {event.amount} tonne{if event.amount != 1:s} \r\n {if event.commodity != \"Unknown\": of {event.commodity}} to the mission depot.\r\n}\r\n\r\n{Pause(500)}\r\n{set remaining to event.totaltodeliver - event.delivered}\r\n{if remaining = 0:\r\n Wing mission requirements are now completed.\r\n|elif event.updatetype = \"Deliver\":\r\n Wing mission is now {round(event.delivered / event.totaltodeliver * 100, 0)} percent complete.\r\n}\r\n"
},
"Carrier cooldown": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Fleet carrier cooldown completed.",
"name": "Carrier cooldown",
"description": "Triggered when you either were docked at a fleet carrier during a jump or are the fleet carrier owner and it completes its cooldown",
"default": true,
"defaultValue": "Fleet carrier cooldown completed."
},
"Carrier jump cancelled": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Fleet carrier jump cancelled.",
"name": "Carrier jump cancelled",
"description": "Triggered when you cancel a scheduled fleet carrier jump",
"default": true,
"defaultValue": "Fleet carrier jump cancelled."
},
"Carrier jump engaged": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'carrier jump')}\r\n{SetState('eddi_context_last_action', 'start')}\r\n{SetState('eddi_context_system_name', event.system)}\r\n{SetState('eddi_context_system_system', event.system)}\r\n{SetState('eddi_context_system_lastvisit', system.lastVisitSeconds)}\r\n\r\n{if environment = \"Docked\":\r\n\r\n {_ Zero the 'remaining jump' context to only use values following this event _}\r\n {SetState('eddi_context_remaining_jumps', 0)}\r\n\r\n {set reportsystem to SystemDetails(event.systemname)}\r\n\r\n {OneOf(\"Jump in progress\",\"Entering portal\")} to the {P(reportsystem.systemname, \"starsystem\")} system\r\n {if len(event.shortname) > 0:\r\n {set reportBody to BodyDetails(event.bodyname, event.systemname)} \r\n near\r\n {if len(reportBody.bodytype) > 0: {reportBody.bodytype} |else: body}\r\n {P(event.shortname, \"body\")}\r\n }.\r\n\r\n {if reportsystem.systemname = homesystem.systemname:\r\n Welcome home, {F(\"Honorific\")}\r\n |else: \r\n {if lastsystem.allegiance && lastsystem.allegiance != \"None\" && lastsystem.allegiance != \"Independent\" && (!reportsystem.allegiance || reportsystem.allegiance = \"None\" || reportsystem.allegiance = \"Independent\"):\r\n You {OneOf(\"are leaving\", \"have left\", \"are no longer in\")} {lastsystem.allegiance} space.\r\n |elif lastsystem.allegiance && lastsystem.allegiance != reportsystem.allegiance && system.allegiance && system.allegiance != \"None\":\r\n You {OneOf(\"are now in\", \"have entered\", \"are entering\")} {reportsystem.allegiance} space.\r\n {if cmdr.title != \"Commander\":\r\n Welcome back {F(\"Honorific\")}.\r\n }\r\n }\r\n\r\n {if reportsystem.visits = 0:\r\n This is your first visit to this system.\r\n |elif reportsystem.visits = 1:\r\n This is your second visit to this system.\r\n |elif reportsystem.visits = 2:\r\n {Occasionally(2, \"This is your third visit to this system.\")}\r\n |elif reportsystem.visits = 3:\r\n {Occasionally(2, \"This is your fourth visit to this system.\")}\r\n |else:\r\n {Occasionally(3, \"You have visited this system {reportsystem.visits} times.\")}\r\n }\r\n\r\n {if reportsystem.population && reportsystem.population > 0:\r\n {if SecondsSince(reportsystem.lastVisitSeconds) > 3600:\r\n {F(\"System report\")}\r\n }\r\n |else:\r\n {OneOf(\"This system is not populated\",\"There is no human presence here\", \"Humans have yet to colonise this system\")}.\r\n }\r\n\r\n {if reportsystem.distancefromhome:\r\n {set ReportDistanceFromHome() to:\r\n {return cat(\r\n \tOneOf(\"You are\", \"Current location is\", \"You are now\"), \" \",\r\n\t Humanise(reportsystem.distancefromhome), \" lightyears from \",\r\n\t OneOf(\"home\", \"{P(homesystem.name, \"starsystem\")}\"), \".\"\r\n\t )}\r\n }\r\n {Occasionally(7, ReportDistanceFromHome())}\r\n }\r\n\r\n {if reportsystem.comment:\r\n You made a {OneOf(\"note\", \"comment\", \"remark\")} {OneOf(\"about\", \"for\", \"on\")} this system. It {OneOf(\"is as follows\", \"says\", \"reads\", \"is\")} {reportsystem.comment}.\r\n }\r\n }\r\n|else:\r\n Fleet carrier arriving at the {P(event.systemname, \"starsystem\")} system\r\n {if len(event.shortname) > 0:\r\n {set reportBody to BodyDetails(event.bodyname, event.systemname)} \r\n near\r\n {if len(reportBody.bodytype) > 0: {reportBody.bodytype} |else: body}\r\n {P(event.shortname, \"body\")}\r\n }.\r\n}",
"name": "Carrier jump engaged",
"description": "Triggered when your fleet carrier performs a jump",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'carrier jump')}\r\n{SetState('eddi_context_last_action', 'start')}\r\n{SetState('eddi_context_system_name', event.system)}\r\n{SetState('eddi_context_system_system', event.system)}\r\n{SetState('eddi_context_system_lastvisit', system.lastVisitSeconds)}\r\n\r\n{if environment = \"Docked\":\r\n\r\n {_ Zero the 'remaining jump' context to only use values following this event _}\r\n {SetState('eddi_context_remaining_jumps', 0)}\r\n\r\n {set reportsystem to SystemDetails(event.systemname)}\r\n\r\n {OneOf(\"Jump in progress\",\"Entering portal\")} to the {P(reportsystem.systemname, \"starsystem\")} system\r\n {if len(event.shortname) > 0:\r\n {set reportBody to BodyDetails(event.bodyname, event.systemname)} \r\n near\r\n {if len(reportBody.bodytype) > 0: {reportBody.bodytype} |else: body}\r\n {P(event.shortname, \"body\")}\r\n }.\r\n\r\n {if reportsystem.systemname = homesystem.systemname:\r\n Welcome home, {F(\"Honorific\")}\r\n |else: \r\n {if lastsystem.allegiance && lastsystem.allegiance != \"None\" && lastsystem.allegiance != \"Independent\" && (!reportsystem.allegiance || reportsystem.allegiance = \"None\" || reportsystem.allegiance = \"Independent\"):\r\n You {OneOf(\"are leaving\", \"have left\", \"are no longer in\")} {lastsystem.allegiance} space.\r\n |elif lastsystem.allegiance && lastsystem.allegiance != reportsystem.allegiance && system.allegiance && system.allegiance != \"None\":\r\n You {OneOf(\"are now in\", \"have entered\", \"are entering\")} {reportsystem.allegiance} space.\r\n {if cmdr.title != \"Commander\":\r\n Welcome back {F(\"Honorific\")}.\r\n }\r\n }\r\n\r\n {if reportsystem.visits = 0:\r\n This is your first visit to this system.\r\n |elif reportsystem.visits = 1:\r\n This is your second visit to this system.\r\n |elif reportsystem.visits = 2:\r\n {Occasionally(2, \"This is your third visit to this system.\")}\r\n |elif reportsystem.visits = 3:\r\n {Occasionally(2, \"This is your fourth visit to this system.\")}\r\n |else:\r\n {Occasionally(3, \"You have visited this system {reportsystem.visits} times.\")}\r\n }\r\n\r\n {if reportsystem.population && reportsystem.population > 0:\r\n {if SecondsSince(reportsystem.lastVisitSeconds) > 3600:\r\n {F(\"System report\")}\r\n }\r\n |else:\r\n {OneOf(\"This system is not populated\",\"There is no human presence here\", \"Humans have yet to colonise this system\")}.\r\n }\r\n\r\n {if reportsystem.distancefromhome:\r\n {set ReportDistanceFromHome() to:\r\n {return cat(\r\n \tOneOf(\"You are\", \"Current location is\", \"You are now\"), \" \",\r\n\t Humanise(reportsystem.distancefromhome), \" lightyears from \",\r\n\t OneOf(\"home\", \"{P(homesystem.name, \"starsystem\")}\"), \".\"\r\n\t )}\r\n }\r\n {Occasionally(7, ReportDistanceFromHome())}\r\n }\r\n\r\n {if reportsystem.comment:\r\n You made a {OneOf(\"note\", \"comment\", \"remark\")} {OneOf(\"about\", \"for\", \"on\")} this system. It {OneOf(\"is as follows\", \"says\", \"reads\", \"is\")} {reportsystem.comment}.\r\n }\r\n }\r\n|else:\r\n Fleet carrier arriving at the {P(event.systemname, \"starsystem\")} system\r\n {if len(event.shortname) > 0:\r\n {set reportBody to BodyDetails(event.bodyname, event.systemname)} \r\n near\r\n {if len(reportBody.bodytype) > 0: {reportBody.bodytype} |else: body}\r\n {P(event.shortname, \"body\")}\r\n }.\r\n}"
},
"Carrier jump request": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Fleet carrier jump scheduled. Course laid in for the {P(event.systemname, \"starsystem\")} star system\r\n{if len(event.shortname) > 0:\r\n {set reportBody to BodyDetails(event.bodyname, event.systemname)} \r\n , arriving near\r\n {if len(reportBody.bodytype) > 0: {reportBody.bodytype}: |else: body: }\r\n {P(event.shortname, \"body\")}\r\n}.",
"name": "Carrier jump request",
"description": "Triggered when you request that your fleet carrier performs a jump",
"default": true,
"defaultValue": "Fleet carrier jump scheduled. Course laid in for the {P(event.systemname, \"starsystem\")} star system\r\n{if len(event.shortname) > 0:\r\n {set reportBody to BodyDetails(event.bodyname, event.systemname)} \r\n , arriving near\r\n {if len(reportBody.bodytype) > 0: {reportBody.bodytype}: |else: body: }\r\n {P(event.shortname, \"body\")}\r\n}."
},
"Carrier jumped": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Carrier jumped }\r\n{_ Triggered when you are docked at a fleet carrier as it completes a jump }\r\n\r\n{_ Context }\r\n{SetState('eddi_context_last_subject', 'carrier jump')}\r\n{SetState('eddi_context_last_action', 'complete')}\r\n{SetState('eddi_context_system_name', event.systemname)}\r\n{SetState('eddi_context_system_system', event.systemname)}\r\n{SetState('eddi_context_wanted_list', \"\")}\r\n\r\nFleet carrier {Spacialise(event.carriername)} has arrived at the {P(event.systemname, \"starsystem\")} system\r\n{if event.bodyname && len(event.bodyname) > 0:\r\n , near the {event.bodytype}: {P(event.bodyname, \"body\")}\r\n}.\r\n{Pause(1000)}\r\n\r\n{_ Update mission data if we have arrived at our mission destination. _}\r\n{if destinationsystem && destinationsystem.name != \"\":\r\n {RouteDetails(\"update\")}\r\n}\r\n\r\n{_ Report faction states only if it's been more than an hour (3600 seconds) since our last visit. _}\r\n{if SecondsSince(state.eddi_context_system_lastvisit) / 3600 > 1:\r\n {set state_report to F(\"System state report\")}\r\n}\r\n\r\n{set system_engineer to F(\"Engineer report\")}\r\n{set system_missions to F(\"Mission check system\")}\r\n{set system_crimes to F(\"Crime check system\")}\r\n\r\n{if state_report || system_missions || (system_crimes && find(system_crimes, \"Warning\") < 0):\r\n {Pause(500)}\r\n Information:\r\n}\r\n\r\n{if state_report:\r\n {Pause(500)}\r\n {state_report}\r\n}\r\n{if system_engineer:\r\n {Pause(500)}\r\n {system_engineer}\r\n}\r\n{if system_missions:\r\n {Pause(500)}\r\n {system_missions}\r\n}\r\n{if system_crimes:\r\n {Pause(500)}\r\n {system_crimes}\r\n}\r\n",
"name": "Carrier jumped",
"description": "Triggered when you are docked at a fleet carrier as it completes a jump",
"default": true,
"defaultValue": "{_ Carrier jumped }\r\n{_ Triggered when you are docked at a fleet carrier as it completes a jump }\r\n\r\n{_ Context }\r\n{SetState('eddi_context_last_subject', 'carrier jump')}\r\n{SetState('eddi_context_last_action', 'complete')}\r\n{SetState('eddi_context_system_name', event.systemname)}\r\n{SetState('eddi_context_system_system', event.systemname)}\r\n{SetState('eddi_context_wanted_list', \"\")}\r\n\r\nFleet carrier {Spacialise(event.carriername)} has arrived at the {P(event.systemname, \"starsystem\")} system\r\n{if event.bodyname && len(event.bodyname) > 0:\r\n , near the {event.bodytype}: {P(event.bodyname, \"body\")}\r\n}.\r\n{Pause(1000)}\r\n\r\n{_ Update mission data if we have arrived at our mission destination. _}\r\n{if destinationsystem && destinationsystem.name != \"\":\r\n {RouteDetails(\"update\")}\r\n}\r\n\r\n{_ Report faction states only if it's been more than an hour (3600 seconds) since our last visit. _}\r\n{if SecondsSince(state.eddi_context_system_lastvisit) / 3600 > 1:\r\n {set state_report to F(\"System state report\")}\r\n}\r\n\r\n{set system_engineer to F(\"Engineer report\")}\r\n{set system_missions to F(\"Mission check system\")}\r\n{set system_crimes to F(\"Crime check system\")}\r\n\r\n{if state_report || system_missions || (system_crimes && find(system_crimes, \"Warning\") < 0):\r\n {Pause(500)}\r\n Information:\r\n}\r\n\r\n{if state_report:\r\n {Pause(500)}\r\n {state_report}\r\n}\r\n{if system_engineer:\r\n {Pause(500)}\r\n {system_engineer}\r\n}\r\n{if system_missions:\r\n {Pause(500)}\r\n {system_missions}\r\n}\r\n{if system_crimes:\r\n {Pause(500)}\r\n {system_crimes}\r\n}\r\n"
},
"Carrier pads locked": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Landing pads locked. Final jump preparations initiated.",
"name": "Carrier pads locked",
"description": "Triggered when your fleet carrier locks landing pads prior to a jump",
"default": true,
"defaultValue": "Landing pads locked. Final jump preparations initiated."
},
"Cleared save": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'save')}\r\n{SetState('eddi_context_last_action', 'clear')}\r\n\r\nДо свидания {F(\"Honorific\")}. Было приятно служить вам.",
"name": "Cleared save",
"description": "Triggered when you clear your save",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'save')}\r\n{SetState('eddi_context_last_action', 'clear')}\r\n\r\nGoodbye {F(\"Honorific\")}. It was a pleasure to serve you."
},
"Cockpit breached": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'cockpit')}\r\n{SetState('eddi_context_last_action', 'breach')}\r\n\r\nIs it me, or is it cold in here?",
"name": "Cockpit breached",
"description": "Triggered when your ship's cockpit is broken",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'cockpit')}\r\n{SetState('eddi_context_last_action', 'breach')}\r\n\r\nIs it me, or is it cold in here?"
},
"Combat promotion": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'rank')}\r\n{SetState('eddi_context_last_action', 'promotion')}\r\n{SetState('eddi_context_rank_name', 'combat')}\r\n{SetState('eddi_context_rank_amount', event.rating)}\r\n\r\nYou have been recognised for your combat skills, {F(\"Honorific\")}.",
"name": "Combat promotion",
"description": "Triggered when your combat rank increases",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'rank')}\r\n{SetState('eddi_context_last_action', 'promotion')}\r\n{SetState('eddi_context_rank_name', 'combat')}\r\n{SetState('eddi_context_rank_amount', event.rating)}\r\n\r\nYou have been recognised for your combat skills, {F(\"Honorific\")}."
},
"Commander continued": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Commander continued }\r\n{_ Triggered when you continue an existing game }\r\n\r\n\r\nWelcome back {F(\"Honorific\")}.\r\n\r\n{SetState('eddi_context_last_subject', 'load_game')}\r\n{SetState('eddi_context_system_name', system.name)}\r\n{SetState('eddi_context_body_name', body.name)}\r\n{SetState('eddi_context_station_name', station.name)}\r\n{SetState('eddi_context_lastdocked', station.name)}",
"name": "Commander continued",
"description": "Triggered when you continue an existing game",
"default": true,
"defaultValue": "{_ Commander continued }\r\n{_ Triggered when you continue an existing game }\r\n\r\n\r\nWelcome back {F(\"Honorific\")}.\r\n\r\n{SetState('eddi_context_last_subject', 'load_game')}\r\n{SetState('eddi_context_system_name', system.name)}\r\n{SetState('eddi_context_body_name', body.name)}\r\n{SetState('eddi_context_station_name', station.name)}\r\n{SetState('eddi_context_lastdocked', station.name)}"
},
"Commander loading": {
"enabled": true,
"priority": 3,
"responder": true,
"script": null,
"name": "Commander loading",
"description": "Triggered at the very beginning of loading a game",
"default": true,
"defaultValue": null
},
"Commander progress": {
"enabled": true,
"priority": 3,
"responder": true,
"script": null,
"name": "Commander progress",
"description": "Triggered when your progress is reported",
"default": true,
"defaultValue": null
},
"Commander ratings": {
"enabled": true,
"priority": 3,
"responder": true,
"script": null,
"name": "Commander ratings",
"description": "Triggered when your ratings are reported",
"default": true,
"defaultValue": null
},
"Commander reputation": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ A note on thresholds... _}\r\n{_ -100.. -90: hostile _}\r\n{_ -90.. -35: unfriendly _}\r\n{_ -35..+ 4: neutral _}\r\n{_ +4..+35: cordial _}\r\n{_ +35..+90: friendly _}\r\n{_ +90..+100: allied _}\r\n",
"name": "Commander reputation",
"description": "Triggered when your reputation is reported",
"default": true,
"defaultValue": "{_ A note on thresholds... _}\r\n{_ -100.. -90: hostile _}\r\n{_ -90.. -35: unfriendly _}\r\n{_ -35..+ 4: neutral _}\r\n{_ +4..+35: cordial _}\r\n{_ +35..+90: friendly _}\r\n{_ +90..+100: allied _}\r\n"
},
"Commander started": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Добро пожаловать, Командер.",
"name": "Commander started",
"description": "Triggered when you start a new game",
"default": false,
"defaultValue": "Welcome, Commander."
},
"Commodity collected": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'commodity')}\r\n{SetState('eddi_context_last_action', 'collect')}\r\n{SetState('eddi_context_cargo_name', event.commodity)}\r\n\r\n{event.commodity} now on board.",
"name": "Commodity collected",
"description": "Triggered when you pick up a commodity in your ship or SRV",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'commodity')}\r\n{SetState('eddi_context_last_action', 'collect')}\r\n{SetState('eddi_context_cargo_name', event.commodity)}\r\n\r\n{event.commodity} now on board."
},
"Commodity ejected": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'commodity')}\r\n{SetState('eddi_context_last_action', 'eject')}\r\n{SetState('eddi_context_commodity_name', event.commodity)}\r\n",
"name": "Commodity ejected",
"description": "Triggered when you eject a commodity from your ship or SRV",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'commodity')}\r\n{SetState('eddi_context_last_action', 'eject')}\r\n{SetState('eddi_context_commodity_name', event.commodity)}\r\n"
},
"Commodity purchase check": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{for commodity in station.commodities:\r\n {if commodity.stock > 0 && commodity.buyprice < commodity.avgprice:\r\n {set discount to commodity.avgprice - commodity.buyprice}\r\n {if discount > best.avgprice - best.buyprice:\r\n {set thirdbest to secondbest}\r\n {set secondbest to best}\r\n {set best to commodity}\r\n |elif discount > secondbest.avgprice - secondbest.buyprice:\r\n {set thirdbest to secondbest}\r\n {set secondbest to commodity}\r\n |elif discount > thirdbest.avgprice - thirdbest.buyprice:\r\n {set thirdbest to commodity}\r\n }\r\n }\r\n}\r\n\r\n{if best:\r\n The local market is selling {best.name} at a good price\r\n {if secondbest:\r\n , as well as {secondbest.name}\r\n {if thirdbest:\r\n and {thirdbest.name}\r\n }\r\n }\r\n.}\r\n",
"name": "Commodity purchase check",
"description": "Check to see which commodities are the best to purchase",
"default": true,
"defaultValue": "{for commodity in station.commodities:\r\n {if commodity.stock > 0 && commodity.buyprice < commodity.avgprice:\r\n {set discount to commodity.avgprice - commodity.buyprice}\r\n {if discount > best.avgprice - best.buyprice:\r\n {set thirdbest to secondbest}\r\n {set secondbest to best}\r\n {set best to commodity}\r\n |elif discount > secondbest.avgprice - secondbest.buyprice:\r\n {set thirdbest to secondbest}\r\n {set secondbest to commodity}\r\n |elif discount > thirdbest.avgprice - thirdbest.buyprice:\r\n {set thirdbest to commodity}\r\n }\r\n }\r\n}\r\n\r\n{if best:\r\n The local market is selling {best.name} at a good price\r\n {if secondbest:\r\n , as well as {secondbest.name}\r\n {if thirdbest:\r\n and {thirdbest.name}\r\n }\r\n }\r\n.}\r\n"
},
"Commodity purchased": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'commodity')}\r\n{SetState('eddi_context_last_action', 'purchase')}\r\n{SetState('eddi_context_commodity_name', event.commodity)}\r\n{SetState('eddi_context_commodity_amount', event.amount)}\r\n\r\n{if event.amount = 1:\r\n You have just purchased one tonne of {event.commodity} for {Humanise(event.price)} credits.\r\n|elif event.amount > 1:\r\n You have just purchased {event.amount} tonnes of {event.commodity} at {Humanise(event.price)} credits per tonne. Total cost is {Humanise(event.amount * event.price)} credits.\r\n}",
"name": "Commodity purchased",
"description": "Triggered when you buy a commodity from the markets",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'commodity')}\r\n{SetState('eddi_context_last_action', 'purchase')}\r\n{SetState('eddi_context_commodity_name', event.commodity)}\r\n{SetState('eddi_context_commodity_amount', event.amount)}\r\n\r\n{if event.amount = 1:\r\n You have just purchased one tonne of {event.commodity} for {Humanise(event.price)} credits.\r\n|elif event.amount > 1:\r\n You have just purchased {event.amount} tonnes of {event.commodity} at {Humanise(event.price)} credits per tonne. Total cost is {Humanise(event.amount * event.price)} credits.\r\n}"
},
"Commodity refined": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'commodity')}\r\n{SetState('eddi_context_last_action', 'refine')}\r\n{SetState('eddi_context_commodity_name', event.commodity)}\r\n\r\n",
"name": "Commodity refined",
"description": "Triggered when you refine a commodity from the refinery",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'commodity')}\r\n{SetState('eddi_context_last_action', 'refine')}\r\n{SetState('eddi_context_commodity_name', event.commodity)}\r\n\r\n"
},
"Commodity sale check": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Commodity sale check}\r\n{_ Check to see which commodities can be sold here}\r\n\r\n\r\n{_ Function to find a given commodity in market}\r\n{set market(commodity) to:\r\n {for marketcommodity in station.commodities:\r\n {if marketcommodity.name = commodity.name:\r\n {return marketcommodity}\r\n }\r\n }\r\n}\r\n\r\n{_ Function to find an illegal mission related to the commodity}\r\n{set illegalmission(haulageData) to:\r\n {for haulage in haulageData:\r\n {if haulage.illegal:\r\n {return true}\r\n }\r\n }\r\n {return false}\r\n}\r\n\r\n{set totalprofit to 0}\r\n{set missioncommodities to []}\r\n{set profitablecommodities to []}\r\n{set stolencommodities to []}\r\n{set unknowncommodities to []}\r\n\r\n{for cargo in inventory:\r\n {if cargo.name != 'Limpet':\r\n {set marketcommodity to market(cargo.commodity)}\r\n {set illegal to illegalmission(cargo.haulageData)}\r\n {set profit to (marketcommodity.sellprice - cargo.price) * cargo.owned}\r\n\r\n {if cargo.stolen > 0 && !illegal:\r\n {set stolencommodities to cat(stolencommodities, [cargo.commodity])}\r\n |elif cargo.haulage > 0:\r\n {set missioncommodities to cat(missioncommodities, [cargo.commodity])}\r\n |elif !marketcommodity && lcase(cargo.category) != \"powerplay\" && cargo.total > 0:\r\n {set unknowncommodities to cat(unknowncommodities, [cargo.commodity])}\r\n |elif marketcommodity && profit > 0:\r\n {set profitablecommodities to cat(profitablecommodities, [cargo.commodity])}\r\n {set totalprofit to totalprofit + profit}\r\n }\r\n }\r\n}\r\n\r\n{_ Let the user know about any commodities they can sell here for a profit}\r\n{if len(profitablecommodities) > 0:\r\n You can sell your\r\n {if len(profitablecommodities) = 1:\r\n {profitablecommodities[0].name}\r\n |elif len(profitablecommodities) = 2:\r\n {profitablecommodities[0].name} and {profitablecommodities[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(profitablecommodities):\r\n {if cur = 0:\r\n {profitablecommodities[cur].name}\r\n |elif cur < len(profitablecommodities) - 1:\r\n , {profitablecommodities[cur].name}\r\n |else:\r\n , and {profitablecommodities[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n for a profit of {Humanise(totalprofit)} credits.\r\n}\r\n\r\n{_ Let the user know about any commodities about which we are unsure if they can sell for a profit}\r\n{if len(unknowncommodities) > 0:\r\n You could {if len(profitablecommodities) > 0: also } sell your\r\n {if len(unknowncommodities) = 1:\r\n {unknowncommodities[0].name}\r\n |elif len(unknowncommodities) = 2:\r\n {unknowncommodities[0].name} and {unknowncommodities[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(unknowncommodities):\r\n {if cur = 0:\r\n {unknowncommodities[cur].name}\r\n |elif cur < len(unknowncommodities) - 1:\r\n , {unknowncommodities[cur].name}\r\n |else:\r\n , and {unknowncommodities[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n , although check potential profits for {if len(unknowncommodities) > 1: these |else: this} before confirming the transaction.\r\n}\r\n\r\n{_ Let the user know about any stolen commodities they can sell on the black market}\r\n{if len(stolencommodities) > 0:\r\n {if station.hasblackmarket:\r\n You can fence your stolen\r\n {if len(stolencommodities) = 1:\r\n {stolencommodities[0].name}\r\n |elif len(stolencommodities) = 2:\r\n {stolencommodities[0].name} and {stolencommodities[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(stolencommodities):\r\n {if cur = 0:\r\n {stolencommodities[cur].name}\r\n |elif cur < len(stolencommodities) - 1:\r\n , {stolencommodities[cur].name}\r\n |else:\r\n , and {stolencommodities[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n here.\r\n |else:\r\n Reminder: you {OneOf(\"have stolen cargo on-board\", \"have stolen goods on-board\", \"are carrying stolen goods\", \"are carrying stolen cargo\")}.\r\n }\r\n}\r\n\r\n{_ Let the user know about any mission related commodities they can sell on the black market}\r\n{if len(missioncommodities) > 0 && station.hasblackmarket:\r\n\r\n You can {if len(stolencommodities) > 0: also} {OneOf('offload', 'dump')} your mission related\r\n {if len(missioncommodities) = 1:\r\n {missioncommodities[0].name}\r\n |elif len(missioncommodities) = 2:\r\n {missioncommodities[0].name} and {missioncommodities[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(missioncommodities):\r\n {if cur = 0:\r\n {missioncommodities[cur].name}\r\n |elif cur < len(missioncommodities) - 1:\r\n , {missioncommodities[cur].name}\r\n |else:\r\n , and {missioncommodities[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n here.\r\n}\r\n",
"name": "Commodity sale check",
"description": "Check to see which commodities can be sold here",
"default": true,
"defaultValue": "{_ Commodity sale check}\r\n{_ Check to see which commodities can be sold here}\r\n\r\n\r\n{_ Function to find a given commodity in market}\r\n{set market(commodity) to:\r\n {for marketcommodity in station.commodities:\r\n {if marketcommodity.name = commodity.name:\r\n {return marketcommodity}\r\n }\r\n }\r\n}\r\n\r\n{_ Function to find an illegal mission related to the commodity}\r\n{set illegalmission(haulageData) to:\r\n {for haulage in haulageData:\r\n {if haulage.illegal:\r\n {return true}\r\n }\r\n }\r\n {return false}\r\n}\r\n\r\n{set totalprofit to 0}\r\n{set missioncommodities to []}\r\n{set profitablecommodities to []}\r\n{set stolencommodities to []}\r\n{set unknowncommodities to []}\r\n\r\n{for cargo in inventory:\r\n {if cargo.name != 'Limpet':\r\n {set marketcommodity to market(cargo.commodity)}\r\n {set illegal to illegalmission(cargo.haulageData)}\r\n {set profit to (marketcommodity.sellprice - cargo.price) * cargo.owned}\r\n\r\n {if cargo.stolen > 0 && !illegal:\r\n {set stolencommodities to cat(stolencommodities, [cargo.commodity])}\r\n |elif cargo.haulage > 0:\r\n {set missioncommodities to cat(missioncommodities, [cargo.commodity])}\r\n |elif !marketcommodity && lcase(cargo.category) != \"powerplay\" && cargo.total > 0:\r\n {set unknowncommodities to cat(unknowncommodities, [cargo.commodity])}\r\n |elif marketcommodity && profit > 0:\r\n {set profitablecommodities to cat(profitablecommodities, [cargo.commodity])}\r\n {set totalprofit to totalprofit + profit}\r\n }\r\n }\r\n}\r\n\r\n{_ Let the user know about any commodities they can sell here for a profit}\r\n{if len(profitablecommodities) > 0:\r\n You can sell your\r\n {if len(profitablecommodities) = 1:\r\n {profitablecommodities[0].name}\r\n |elif len(profitablecommodities) = 2:\r\n {profitablecommodities[0].name} and {profitablecommodities[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(profitablecommodities):\r\n {if cur = 0:\r\n {profitablecommodities[cur].name}\r\n |elif cur < len(profitablecommodities) - 1:\r\n , {profitablecommodities[cur].name}\r\n |else:\r\n , and {profitablecommodities[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n for a profit of {Humanise(totalprofit)} credits.\r\n}\r\n\r\n{_ Let the user know about any commodities about which we are unsure if they can sell for a profit}\r\n{if len(unknowncommodities) > 0:\r\n You could {if len(profitablecommodities) > 0: also } sell your\r\n {if len(unknowncommodities) = 1:\r\n {unknowncommodities[0].name}\r\n |elif len(unknowncommodities) = 2:\r\n {unknowncommodities[0].name} and {unknowncommodities[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(unknowncommodities):\r\n {if cur = 0:\r\n {unknowncommodities[cur].name}\r\n |elif cur < len(unknowncommodities) - 1:\r\n , {unknowncommodities[cur].name}\r\n |else:\r\n , and {unknowncommodities[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n , although check potential profits for {if len(unknowncommodities) > 1: these |else: this} before confirming the transaction.\r\n}\r\n\r\n{_ Let the user know about any stolen commodities they can sell on the black market}\r\n{if len(stolencommodities) > 0:\r\n {if station.hasblackmarket:\r\n You can fence your stolen\r\n {if len(stolencommodities) = 1:\r\n {stolencommodities[0].name}\r\n |elif len(stolencommodities) = 2:\r\n {stolencommodities[0].name} and {stolencommodities[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(stolencommodities):\r\n {if cur = 0:\r\n {stolencommodities[cur].name}\r\n |elif cur < len(stolencommodities) - 1:\r\n , {stolencommodities[cur].name}\r\n |else:\r\n , and {stolencommodities[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n here.\r\n |else:\r\n Reminder: you {OneOf(\"have stolen cargo on-board\", \"have stolen goods on-board\", \"are carrying stolen goods\", \"are carrying stolen cargo\")}.\r\n }\r\n}\r\n\r\n{_ Let the user know about any mission related commodities they can sell on the black market}\r\n{if len(missioncommodities) > 0 && station.hasblackmarket:\r\n\r\n You can {if len(stolencommodities) > 0: also} {OneOf('offload', 'dump')} your mission related\r\n {if len(missioncommodities) = 1:\r\n {missioncommodities[0].name}\r\n |elif len(missioncommodities) = 2:\r\n {missioncommodities[0].name} and {missioncommodities[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(missioncommodities):\r\n {if cur = 0:\r\n {missioncommodities[cur].name}\r\n |elif cur < len(missioncommodities) - 1:\r\n , {missioncommodities[cur].name}\r\n |else:\r\n , and {missioncommodities[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n here.\r\n}\r\n"
},
"Commodity sold": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'commodity')}\r\n{SetState('eddi_context_last_action', 'sell')}\r\n{SetState('eddi_context_commodity_name', event.commodity)}\r\n{SetState('eddi_context_commodity_amount', event.amount)}\r\n\r\n{if event.amount = 1:\r\n You have just sold one tonne of {event.commodity} for {Humanise(event.price)} credits\r\n|elif event.amount > 1:\r\n You have just sold {event.amount} tonnes of {event.commodity} at {Humanise(event.price)} credits per tonne for a total of {Humanise(event.amount * event.price)} credits\r\n}\r\n\r\n{if event.price != event.profit:\r\n {if event.profit < 0:\r\n with a loss of {Humanise(-1 * event.profit * event.amount)} credits.\r\n |elif event.profit = 0:\r\n and broke even on the trade.\r\n |else:\r\n with a profit of {Humanise(event.profit * event.amount)} credits.\r\n }\r\n}",
"name": "Commodity sold",
"description": "Triggered when you sell a commodity to the markets",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'commodity')}\r\n{SetState('eddi_context_last_action', 'sell')}\r\n{SetState('eddi_context_commodity_name', event.commodity)}\r\n{SetState('eddi_context_commodity_amount', event.amount)}\r\n\r\n{if event.amount = 1:\r\n You have just sold one tonne of {event.commodity} for {Humanise(event.price)} credits\r\n|elif event.amount > 1:\r\n You have just sold {event.amount} tonnes of {event.commodity} at {Humanise(event.price)} credits per tonne for a total of {Humanise(event.amount * event.price)} credits\r\n}\r\n\r\n{if event.price != event.profit:\r\n {if event.profit < 0:\r\n with a loss of {Humanise(-1 * event.profit * event.amount)} credits.\r\n |elif event.profit = 0:\r\n and broke even on the trade.\r\n |else:\r\n with a profit of {Humanise(event.profit * event.amount)} credits.\r\n }\r\n}"
},
"Community goal": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Set Context _}\r\n{SetState('eddi_context_last_subject', 'community goal')}\r\n\r\n{_ Localize percentile bands }\r\n{set ordinalPercentile(percentile) to:\r\n {if percentile = 10:\r\n tenth\r\n |elif percentile = 25:\r\n twenty-fifth\r\n |elif percentile = 50:\r\n fiftieth\r\n |elif percentile = 75:\r\n seventy-fifth\r\n |else:\r\n one hundredth\r\n }\r\n}\r\n\r\n{F(\"Honorific\")}, we have received an update to the community goal \"{event.name}\".\r\n\r\n{for update in event.updates:\r\n {if update.type = \"Tier\":\r\n The goal has reached tier {event.tier}.\r\n |elif update.type = \"Percentile\":\r\n {if event.toprank:\r\n Congratulations! You are now one of the top {event.topranksize} contributors. \r\n |else:\r\n {if update.direction = \"Increase\":\r\n You have reached \r\n |else:\r\n You have fallen to\r\n }\r\n the {Occasionally(2, \"top\")}\r\n {ordinalPercentile(event.percentileband)} percentile band.\r\n }\r\n }\r\n}\r\n\r\n{if event.contribution > 0:\r\n Your expected reward is \r\n {Occasionally(2, \"currently\")}\r\n {Humanise(event.tierreward)} credits.\r\n}",
"name": "Community goal",
"description": "Triggered when the status of a community goal changes",
"default": true,
"defaultValue": "{_ Set Context _}\r\n{SetState('eddi_context_last_subject', 'community goal')}\r\n\r\n{_ Localize percentile bands }\r\n{set ordinalPercentile(percentile) to:\r\n {if percentile = 10:\r\n tenth\r\n |elif percentile = 25:\r\n twenty-fifth\r\n |elif percentile = 50:\r\n fiftieth\r\n |elif percentile = 75:\r\n seventy-fifth\r\n |else:\r\n one hundredth\r\n }\r\n}\r\n\r\n{F(\"Honorific\")}, we have received an update to the community goal \"{event.name}\".\r\n\r\n{for update in event.updates:\r\n {if update.type = \"Tier\":\r\n The goal has reached tier {event.tier}.\r\n |elif update.type = \"Percentile\":\r\n {if event.toprank:\r\n Congratulations! You are now one of the top {event.topranksize} contributors. \r\n |else:\r\n {if update.direction = \"Increase\":\r\n You have reached \r\n |else:\r\n You have fallen to\r\n }\r\n the {Occasionally(2, \"top\")}\r\n {ordinalPercentile(event.percentileband)} percentile band.\r\n }\r\n }\r\n}\r\n\r\n{if event.contribution > 0:\r\n Your expected reward is \r\n {Occasionally(2, \"currently\")}\r\n {Humanise(event.tierreward)} credits.\r\n}"
},
"Community goals": {
"enabled": true,
"priority": 3,
"responder": true,
"script": null,
"name": "Community goals",
"description": "Triggered when checking the status of community goals",
"default": true,
"defaultValue": null
},
"Controlling fighter": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{OneOf(\"Neural link\", \"Link\", \"Uplink\")} {Occasionally(2, \"to fighter\")} {OneOf(\"initiated\", \"established\", \"engaged\")}.",
"name": "Controlling fighter",
"description": "Triggered when you switch control from your ship to your fighter",
"default": true,
"defaultValue": "{OneOf(\"Neural link\", \"Link\", \"Uplink\")} {Occasionally(2, \"to fighter\")} {OneOf(\"initiated\", \"established\", \"engaged\")}."
},
"Controlling ship": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{OneOf(\"Neural link\", \"Link\", \"Uplink\")} {OneOf(\"terminated\", \"disengaged\")}.",
"name": "Controlling ship",
"description": "Triggered when you switch control from your fighter to your ship",
"default": true,
"defaultValue": "{OneOf(\"Neural link\", \"Link\", \"Uplink\")} {OneOf(\"terminated\", \"disengaged\")}."
},
"Crew assigned": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{if event.role = \"Active\":\r\n {event.name} на боевом посту.\r\n|else:\r\n {event.name} покинул боевой пост.\r\n}",
"name": "Crew assigned",
"description": "Triggered when you assign crew",
"default": false,
"defaultValue": "{if event.role = \"Active\":\r\n {event.name} is now on active duty.\r\n|else:\r\n {event.name} standing down from active duty.\r\n}"
},
"Crew fired": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'fire')}\r\n{SetState('eddi_context_crew_name', event.name)}\r\n\r\n{event.name} был отстранён.",
"name": "Crew fired",
"description": "Triggered when you fire crew",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'fire')}\r\n{SetState('eddi_context_crew_name', event.name)}\r\n\r\n{event.name} has been fired."
},
"Crew hired": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'hire')}\r\n{SetState('eddi_context_crew_name', event.name)}\r\n\r\n{event.name} был нанят.",
"name": "Crew hired",
"description": "Triggered when you hire crew",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'hire')}\r\n{SetState('eddi_context_crew_name', event.name)}\r\n\r\n{event.name} has been hired."
},
"Crew joined": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'join')}\r\n{SetState('eddi_context_crew_name', event.captain)}\r\n\r\nВы присоединились к экипажу {event.captain}.",
"name": "Crew joined",
"description": "Triggered when you join a crew",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'join')}\r\n{SetState('eddi_context_crew_name', event.captain)}\r\n\r\nYou have joined {event.captain}'s crew."
},
"Crew left": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'leave')}\r\n{SetState('eddi_context_crew_name', event.captain)}\r\n\r\nВы покинули экипаж {event.captain} .",
"name": "Crew left",
"description": "Triggered when you leave a crew",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'leave')}\r\n{SetState('eddi_context_crew_name', event.captain)}\r\n\r\nYou have left {event.captain}'s crew."
},
"Crew member joined": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'join')}\r\n{SetState('eddi_context_crew_name', event.crew)}\r\n\r\n{event.crew} присоединился к вашему экипажу.",
"name": "Crew member joined",
"description": "Triggered when a commander joins your crew",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'join')}\r\n{SetState('eddi_context_crew_name', event.crew)}\r\n\r\n{event.crew} has joined your crew."
},
"Crew member launched": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'launch')}\r\n{SetState('eddi_context_crew_name', event.crew)}\r\n\r\n{event.crew} запустил истребитель.",
"name": "Crew member launched",
"description": "Triggered when a crew member launches the fighter",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'launch')}\r\n{SetState('eddi_context_crew_name', event.crew)}\r\n\r\n{event.crew} has launched their fighter."
},
"Crew member left": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'leave')}\r\n{SetState('eddi_context_crew_name', event.crew)}\r\n\r\n{event.crew} покинул ваш экипаж.",
"name": "Crew member left",
"description": "Triggered when a commander leaves your crew",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'leave')}\r\n{SetState('eddi_context_crew_name', event.crew)}\r\n\r\n{event.crew} has left your crew."
},
"Crew member removed": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'remove')}\r\n{SetState('eddi_context_crew_name', event.crew)}\r\n\r\nВы выгнали {event.crew} из вашего экипажа.",
"name": "Crew member removed",
"description": "Triggered when you remove a commander from your crew",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'remove')}\r\n{SetState('eddi_context_crew_name', event.crew)}\r\n\r\nYou have removed {event.crew} from your crew."
},
"Crew member role changed": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'role')}\r\n{SetState('eddi_context_crew_name', event.crew)}\r\n{SetState('eddi_context_crew_role', event.role)}\r\n\r\n{if event.role = 'Idle':\r\n {event.crew} больше не занимает должность\r\n|elif event.role = 'Fighter':\r\n {event.crew} переназначен на управление истребителем\r\n|elif event.role = 'Gunner':\r\n {event.crew} переназначен на управление орудиями корабля \r\n}.\r\n",
"name": "Crew member role changed",
"description": "Triggered when a crew member changes their role",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'crew')}\r\n{SetState('eddi_context_last_action', 'role')}\r\n{SetState('eddi_context_crew_name', event.crew)}\r\n{SetState('eddi_context_crew_role', event.role)}\r\n\r\n{if event.role = 'Idle':\r\n {event.crew} is no longer manning a position\r\n|elif event.role = 'Fighter':\r\n {event.crew} is now manning the fighter\r\n|elif event.role = 'Gunner':\r\n {event.crew} is now manning the guns\r\n}.\r\n"
},
"Crew paid wage": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Crew paid wage }\r\n{_ Triggered when npc crew receives a profit share }\r\n\r\n",
"name": "Crew paid wage",
"description": "Triggered when npc crew receives a profit share",
"default": true,
"defaultValue": "{_ Crew paid wage }\r\n{_ Triggered when npc crew receives a profit share }\r\n\r\n"
},
"Crew promotion": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Crew promotion }\r\n{_ Triggered when crewmember combat rank increases }\r\n\r\n\r\nЧлен экипажа {event.name} повышен до боевого звания {event.combatrating}.",
"name": "Crew promotion",
"description": "Triggered when crewmember combat rank increases",
"default": false,
"defaultValue": "{_ Crew promotion }\r\n{_ Triggered when crewmember combat rank increases }\r\n\r\n\r\nCrew member {event.name} has been promoted to the combat rank of {event.combatrating}."
},
"Crew role changed": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{if event.role = 'Gunner':\r\n Вы переназначены на управлением орудиями корабля.\r\n|elif event.role = 'Fighter':\r\n Вы переназначены на управлением истребителем.\r\n|elif event.role = 'Idle':\r\n Вы покинули боевой пост.\r\n}",
"name": "Crew role changed",
"description": "Triggered when your role in the crew changes",
"default": false,
"defaultValue": "{if event.role = 'Gunner':\r\n You are now this crew's gunner.\r\n|elif event.role = 'Fighter':\r\n You are now this crew's fighter pilot.\r\n|elif event.role = 'Idle':\r\n You have been unassigned from active duty.\r\n}"
},
"Crime check station": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Crime check station }\r\n{_ Check claims, fines & bounties related to the current station }\r\n\r\n\r\n{set CheckPad(current_station) to:\r\n {set largest_pad to lcase(current_station.largestpad)}\r\n {if largest_pad != \"none\":\r\n {if largest_pad = \"large\":\r\n {return true}\r\n |elif largest_pad = \"medium\":\r\n {if lcase(ship.size) = \"large\":\r\n {return false}\r\n |else:\r\n {return true}\r\n }\r\n }\r\n {if lcase(ship.size) = \"small\":\r\n {return true}\r\n }\r\n }\r\n {return false}\r\n}\r\n\r\n{set HasService(service) to:\r\n {if CheckPad(current_station):\r\n {if find(current_station.stationservices, service) > -1:\r\n {return true}\r\n |else:\r\n {return false}\r\n }\r\n |else: {return false}\r\n }\r\n}\r\n\r\n{if state.eddi_context_body_type = 'Station' && station.name && station.name != \"\":\r\n {set current_station to StationDetails(station.name)}\r\n {set factions_claims to []}\r\n {set factions_fines to []}\r\n {set factions_bounties to []}\r\n {set station_report to false}\r\n {set system_claims to 0}\r\n {set system_fines to 0}\r\n {set system_bounties to 0}\r\n\r\n {for record in criminalrecord:\r\n {for faction in system.factions:\r\n {if record.faction = faction.name:\r\n\r\n {if record.claims > 0:\r\n {set factions_claims to cat(factions_claims, [record.faction])}\r\n {set system_claims to system_claims + record.claims}\r\n }\r\n\r\n {set reports to record.finesIncurred}\r\n {if len(reports) > 0:\r\n {for report in reports:\r\n {if report.shipId = ship.LocalId:\r\n {set system_fines to system_fines + report.amount}\r\n {if find(factions_fines, record.faction) < 0:\r\n {set factions_fines to cat(factions_fines, [record.faction])}\r\n }\r\n }\r\n }\r\n }\r\n\r\n {set reports to record.bountiesIncurred}\r\n {if len(reports) > 0:\r\n {for report in reports:\r\n {if report.shipId = ship.LocalId:\r\n {set system_bounties to system_bounties + report.amount}\r\n {if find(factions_bounties, record.faction) < 0:\r\n {set factions_bounties to cat(factions_bounties, [record.faction])}\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n {set claim_count to len(factions_claims)}\r\n {set fine_count to len(factions_fines)}\r\n {set bounty_count to len(factions_bounties)}\r\n {set bounties to system_bounties > 0 && HasService(\"Interstellar Factors Contact\")}\r\n {set fines to system_fines > 0 && HasService(\"Contacts\")}\r\n {set claims to system_claims > 0 && HasService(\"Contacts\")}\r\n \r\n {if bounties || fines || claims:\r\n {set actions to []}\r\n {if bounties:\r\n {set action to:\r\n clear your pending\r\n {if bounty_count = 1: bounty |else: bounties }\r\n }\r\n {set actions to cat(actions, [action])} \r\n }\r\n {if fines: \r\n {set action to:\r\n clear your pending\r\n {if fine_count = 1: fine |else: fines }\r\n }\r\n {set actions to cat(actions, [action])} \r\n }\r\n {if claims:\r\n {set action to:\r\n claim your pending\r\n {if claim_count = 1: reward |else: rewards }\r\n for hunting services rendered\r\n }\r\n {set actions to cat(actions, [action])}\r\n }\r\n There are facilities at this station to {List(actions)}.\r\n }\r\n}",
"name": "Crime check station",
"description": "Check claims, fines & bounties related to the current station",
"default": true,
"defaultValue": "{_ Crime check station }\r\n{_ Check claims, fines & bounties related to the current station }\r\n\r\n\r\n{set CheckPad(current_station) to:\r\n {set largest_pad to lcase(current_station.largestpad)}\r\n {if largest_pad != \"none\":\r\n {if largest_pad = \"large\":\r\n {return true}\r\n |elif largest_pad = \"medium\":\r\n {if lcase(ship.size) = \"large\":\r\n {return false}\r\n |else:\r\n {return true}\r\n }\r\n }\r\n {if lcase(ship.size) = \"small\":\r\n {return true}\r\n }\r\n }\r\n {return false}\r\n}\r\n\r\n{set HasService(service) to:\r\n {if CheckPad(current_station):\r\n {if find(current_station.stationservices, service) > -1:\r\n {return true}\r\n |else:\r\n {return false}\r\n }\r\n |else: {return false}\r\n }\r\n}\r\n\r\n{if state.eddi_context_body_type = 'Station' && station.name && station.name != \"\":\r\n {set current_station to StationDetails(station.name)}\r\n {set factions_claims to []}\r\n {set factions_fines to []}\r\n {set factions_bounties to []}\r\n {set station_report to false}\r\n {set system_claims to 0}\r\n {set system_fines to 0}\r\n {set system_bounties to 0}\r\n\r\n {for record in criminalrecord:\r\n {for faction in system.factions:\r\n {if record.faction = faction.name:\r\n\r\n {if record.claims > 0:\r\n {set factions_claims to cat(factions_claims, [record.faction])}\r\n {set system_claims to system_claims + record.claims}\r\n }\r\n\r\n {set reports to record.finesIncurred}\r\n {if len(reports) > 0:\r\n {for report in reports:\r\n {if report.shipId = ship.LocalId:\r\n {set system_fines to system_fines + report.amount}\r\n {if find(factions_fines, record.faction) < 0:\r\n {set factions_fines to cat(factions_fines, [record.faction])}\r\n }\r\n }\r\n }\r\n }\r\n\r\n {set reports to record.bountiesIncurred}\r\n {if len(reports) > 0:\r\n {for report in reports:\r\n {if report.shipId = ship.LocalId:\r\n {set system_bounties to system_bounties + report.amount}\r\n {if find(factions_bounties, record.faction) < 0:\r\n {set factions_bounties to cat(factions_bounties, [record.faction])}\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n {set claim_count to len(factions_claims)}\r\n {set fine_count to len(factions_fines)}\r\n {set bounty_count to len(factions_bounties)}\r\n {set bounties to system_bounties > 0 && HasService(\"Interstellar Factors Contact\")}\r\n {set fines to system_fines > 0 && HasService(\"Contacts\")}\r\n {set claims to system_claims > 0 && HasService(\"Contacts\")}\r\n \r\n {if bounties || fines || claims:\r\n {set actions to []}\r\n {if bounties:\r\n {set action to:\r\n clear your pending\r\n {if bounty_count = 1: bounty |else: bounties }\r\n }\r\n {set actions to cat(actions, [action])} \r\n }\r\n {if fines: \r\n {set action to:\r\n clear your pending\r\n {if fine_count = 1: fine |else: fines }\r\n }\r\n {set actions to cat(actions, [action])} \r\n }\r\n {if claims:\r\n {set action to:\r\n claim your pending\r\n {if claim_count = 1: reward |else: rewards }\r\n for hunting services rendered\r\n }\r\n {set actions to cat(actions, [action])}\r\n }\r\n There are facilities at this station to {List(actions)}.\r\n }\r\n}"
},
"Crime check system": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Crime check system }\r\n{_ Check claims, fines & bounties related to the current system }\r\n\r\n\r\n{set CheckPad(station) to:\r\n {set largest_pad to lcase(station.largestpad)}\r\n {if largest_pad != \"none\":\r\n {if largest_pad = \"large\":\r\n {return true}\r\n |elif largest_pad = \"medium\":\r\n {if lcase(ship.size) = \"large\":\r\n {return false}\r\n |else:\r\n {return true}\r\n }\r\n }\r\n {if lcase(ship.size) = \"small\":\r\n {return true}\r\n }\r\n }\r\n {return false}\r\n}\r\n\r\n{set NearestStation(service) to:\r\n {set distance to 0}\r\n {set station_count to 0}\r\n {set orbital_count to 0}\r\n\r\n {_ If preferred & available, use orbital stations }\r\n {if orbitalpriority:\r\n {for station in system.orbitalstations:\r\n {if find(station.stationservices, service) > -1:\r\n {set orbital_count to orbital_count + 1}\r\n }\r\n }\r\n }\r\n\r\n {_ Force orbital stations when game version is not 'Horizons' }\r\n {if orbital_count > 0 || !horizons:\r\n {set stations to system.orbitalstations}\r\n |else:\r\n {set stations to system.stations}\r\n }\r\n\r\n {_ Get the total count and nearest station }\r\n {for station in stations:\r\n {if CheckPad(station):\r\n {if find(station.stationservices, service) > -1:\r\n {set station_count to station_count + 1}\r\n {if distance = 0 || station.distancefromstar < distance:\r\n {set distance to station.distancefromstar}\r\n {set nearest_station to P(station.name, \"station\")}\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n{set factions_claims to []}\r\n{set factions_fines to []}\r\n{set factions_bounties to []}\r\n{set station_report to false}\r\n{set system_claims to 0}\r\n{set system_fines to 0}\r\n{set system_bounties to 0}\r\n{set wanted_count to 0}\r\n\r\n{for record in criminalrecord:\r\n {for faction in system.factions:\r\n {if record.faction = faction.name:\r\n\r\n {if record.claims > 0:\r\n {set factions_claims to cat(factions_claims, [record.faction])}\r\n {set system_claims to system_claims + record.claims}\r\n }\r\n\r\n {set reports to record.finesIncurred}\r\n {if len(reports) > 0:\r\n {for report in reports:\r\n {if report.shipId = ship.LocalId:\r\n {set system_fines to system_fines + report.amount}\r\n {if find(factions_fines, record.faction) < 0:\r\n {set factions_fines to cat(factions_fines, [record.faction])}\r\n {if find(factions_bounties, record.faction) < 0:\r\n {set wanted_count to wanted_count + 1}\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n {set reports to record.bountiesIncurred}\r\n {if len(reports) > 0:\r\n {for report in reports:\r\n {if report.shipId = ship.LocalId:\r\n {set system_bounties to system_bounties + report.amount}\r\n {if find(factions_bounties, record.faction) < 0:\r\n {set factions_bounties to cat(factions_bounties, [record.faction])}\r\n {if find(factions_fines, record.faction) < 0:\r\n {set wanted_count to wanted_count + 1}\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n{set claim_count to len(factions_claims)}\r\n{set fine_count to len(factions_fines)}\r\n{set bounty_count to len(factions_bounties)}\r\n\r\n{if wanted_count > 0:\r\n Warning: {ShipName()} is wanted in this system by {wanted_count}\r\n {if wanted_count = 1: faction |else: factions},\r\n for total fines and bounties of {Humanise(system_fines + system_bounties)} credits.\r\n}\r\n\r\n{_ Report nearest station to clear bounties }\r\n{if system_bounties > 0:\r\n {NearestStation(\"Interstellar Factors Contact\")}\r\n {if station_count > 0:\r\n There are legal facilities at {station_count} {if orbitalpriority: orbital}\r\n {if station_count = 1: station |else: stations} to clear your pending\r\n {if bounty_count = 1: bounty |else: bounties}.\r\n {if station_count = 1: It |else: The nearest} is {nearest_station},\r\n {round(distance, 1)} light-seconds from the main star.\r\n {set station_report to true}\r\n }\r\n}\r\n\r\n{if system_fines > 0 && !station_report:\r\n {NearestStation(\"Contacts\")}\r\n {if station_count > 0:\r\n There {if station_count = 1: is |else: are} {station_count} {if orbitalpriority: orbital}\r\n {if station_count = 1: station |else: stations} to clear your pending\r\n {if fine_count = 1: fine |else: fines}.\r\n {if station_count = 1: It |else: The nearest} is {nearest_station},\r\n {round(distance, 1)} light-seconds from the main star.\r\n {set station_report to true}\r\n }\r\n}\r\n\r\n{_ Report nearest station for pending claims }\r\n{if system_claims > 0:\r\n You have bond and bounty claims in this system for {claim_count}\r\n {if claim_count = 1: faction |else: factions}, for a total of {Humanise(system_claims)} credits.\r\n\r\n {if !station_report:\r\n {if system_fines = 0: {NearestStation(\"Contacts\")}}\r\n {if station_count > 0:\r\n There {if station_count = 1: is |else: are} {station_count} {if orbitalpriority: orbital}\r\n {if station_count = 1: station |else: stations} to claim your\r\n {if claim_count = 1: reward |else: rewards}.\r\n {if station_count = 1: It |else: The nearest} is {nearest_station},\r\n {round(distance, 1)} light-seconds from the main star.\r\n }\r\n }\r\n}\r\n",
"name": "Crime check system",
"description": "Check claims, fines & bounties related to the current system",
"default": true,
"defaultValue": "{_ Crime check system }\r\n{_ Check claims, fines & bounties related to the current system }\r\n\r\n\r\n{set CheckPad(station) to:\r\n {set largest_pad to lcase(station.largestpad)}\r\n {if largest_pad != \"none\":\r\n {if largest_pad = \"large\":\r\n {return true}\r\n |elif largest_pad = \"medium\":\r\n {if lcase(ship.size) = \"large\":\r\n {return false}\r\n |else:\r\n {return true}\r\n }\r\n }\r\n {if lcase(ship.size) = \"small\":\r\n {return true}\r\n }\r\n }\r\n {return false}\r\n}\r\n\r\n{set NearestStation(service) to:\r\n {set distance to 0}\r\n {set station_count to 0}\r\n {set orbital_count to 0}\r\n\r\n {_ If preferred & available, use orbital stations }\r\n {if orbitalpriority:\r\n {for station in system.orbitalstations:\r\n {if find(station.stationservices, service) > -1:\r\n {set orbital_count to orbital_count + 1}\r\n }\r\n }\r\n }\r\n\r\n {_ Force orbital stations when game version is not 'Horizons' }\r\n {if orbital_count > 0 || !horizons:\r\n {set stations to system.orbitalstations}\r\n |else:\r\n {set stations to system.stations}\r\n }\r\n\r\n {_ Get the total count and nearest station }\r\n {for station in stations:\r\n {if CheckPad(station):\r\n {if find(station.stationservices, service) > -1:\r\n {set station_count to station_count + 1}\r\n {if distance = 0 || station.distancefromstar < distance:\r\n {set distance to station.distancefromstar}\r\n {set nearest_station to P(station.name, \"station\")}\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n{set factions_claims to []}\r\n{set factions_fines to []}\r\n{set factions_bounties to []}\r\n{set station_report to false}\r\n{set system_claims to 0}\r\n{set system_fines to 0}\r\n{set system_bounties to 0}\r\n{set wanted_count to 0}\r\n\r\n{for record in criminalrecord:\r\n {for faction in system.factions:\r\n {if record.faction = faction.name:\r\n\r\n {if record.claims > 0:\r\n {set factions_claims to cat(factions_claims, [record.faction])}\r\n {set system_claims to system_claims + record.claims}\r\n }\r\n\r\n {set reports to record.finesIncurred}\r\n {if len(reports) > 0:\r\n {for report in reports:\r\n {if report.shipId = ship.LocalId:\r\n {set system_fines to system_fines + report.amount}\r\n {if find(factions_fines, record.faction) < 0:\r\n {set factions_fines to cat(factions_fines, [record.faction])}\r\n {if find(factions_bounties, record.faction) < 0:\r\n {set wanted_count to wanted_count + 1}\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n {set reports to record.bountiesIncurred}\r\n {if len(reports) > 0:\r\n {for report in reports:\r\n {if report.shipId = ship.LocalId:\r\n {set system_bounties to system_bounties + report.amount}\r\n {if find(factions_bounties, record.faction) < 0:\r\n {set factions_bounties to cat(factions_bounties, [record.faction])}\r\n {if find(factions_fines, record.faction) < 0:\r\n {set wanted_count to wanted_count + 1}\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n{set claim_count to len(factions_claims)}\r\n{set fine_count to len(factions_fines)}\r\n{set bounty_count to len(factions_bounties)}\r\n\r\n{if wanted_count > 0:\r\n Warning: {ShipName()} is wanted in this system by {wanted_count}\r\n {if wanted_count = 1: faction |else: factions},\r\n for total fines and bounties of {Humanise(system_fines + system_bounties)} credits.\r\n}\r\n\r\n{_ Report nearest station to clear bounties }\r\n{if system_bounties > 0:\r\n {NearestStation(\"Interstellar Factors Contact\")}\r\n {if station_count > 0:\r\n There are legal facilities at {station_count} {if orbitalpriority: orbital}\r\n {if station_count = 1: station |else: stations} to clear your pending\r\n {if bounty_count = 1: bounty |else: bounties}.\r\n {if station_count = 1: It |else: The nearest} is {nearest_station},\r\n {round(distance, 1)} light-seconds from the main star.\r\n {set station_report to true}\r\n }\r\n}\r\n\r\n{if system_fines > 0 && !station_report:\r\n {NearestStation(\"Contacts\")}\r\n {if station_count > 0:\r\n There {if station_count = 1: is |else: are} {station_count} {if orbitalpriority: orbital}\r\n {if station_count = 1: station |else: stations} to clear your pending\r\n {if fine_count = 1: fine |else: fines}.\r\n {if station_count = 1: It |else: The nearest} is {nearest_station},\r\n {round(distance, 1)} light-seconds from the main star.\r\n {set station_report to true}\r\n }\r\n}\r\n\r\n{_ Report nearest station for pending claims }\r\n{if system_claims > 0:\r\n You have bond and bounty claims in this system for {claim_count}\r\n {if claim_count = 1: faction |else: factions}, for a total of {Humanise(system_claims)} credits.\r\n\r\n {if !station_report:\r\n {if system_fines = 0: {NearestStation(\"Contacts\")}}\r\n {if station_count > 0:\r\n There {if station_count = 1: is |else: are} {station_count} {if orbitalpriority: orbital}\r\n {if station_count = 1: station |else: stations} to claim your\r\n {if claim_count = 1: reward |else: rewards}.\r\n {if station_count = 1: It |else: The nearest} is {nearest_station},\r\n {round(distance, 1)} light-seconds from the main star.\r\n }\r\n }\r\n}\r\n"
},
"Crime report": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Crime report}\r\n{_ Report on all pending claims, fines, and bounties }\r\n\r\n\r\n{set factions_claims to []}\r\n{set claims_count to 0}\r\n{set factions_fines to []}\r\n{set fines_count to 0}\r\n{set factions_bounties to []}\r\n{set systems_bounties to []}\r\n\r\n{for record in criminalrecord:\r\n {set faction to FactionDetails(record.faction)}\r\n {if faction:\r\n {if record.bounties > 0:\r\n {set factions_bounties to cat(factions_bounties, [record.faction])}\r\n {for presence in faction.presences:\r\n {if find(presence.systemName, systems_bounties) = -1:\r\n {set systems_bounties to cat(systems_bounties, [presence.systemName])}\r\n }\r\n }\r\n }\r\n {if record.fines > 0:\r\n {set factions_fines to cat(factions_fines, [record.faction])}\r\n }\r\n {if record.claims > 0:\r\n {set factions_claims to cat(factions_claims, [record.faction])}\r\n }\r\n\r\n {for report in record.factionReports:\r\n {if !report.bounty && report.crimeEDName != \"none\":\r\n {set fines_count to fines_count + 1}\r\n }\r\n {if report.crimeEDName = \"none\":\r\n {set claims_count to claims_count + 1}\r\n }\r\n }\r\n }\r\n}\r\n\r\n{set factions_count to len(factions_bounties)}\r\n{set systems_count to len(factions_bounties)}\r\n\r\n{if factions_count > 0:\r\n You are wanted by {factions_count} {if factions_count = 1: faction |else: factions}\r\n in {systems_count} {if systems_count = 1: system |else: systems} for a total of\r\n {Humanise(bounties)} credits.\r\n}\r\n\r\n{set factions_count to len(factions_fines)}\r\n{if factions_count > 0:\r\n You have {fines_count} pending {if fines_count = 1: fine |else: fines} from\r\n {factions_count} {if factions_count = 1: faction |else: factions},\r\n for a total of {Humanise(fines)} credits.\r\n}\r\n\r\n{set factions_count to len(factions_claims)}\r\n{if factions_count > 0:\r\n You have {claims_count} uncollected {if claims_count = 1: claim |else: claims} from\r\n {factions_count} {if factions_count = 1: faction |else: factions},\r\n for a total of {Humanise(claims)} credits.\r\n}",
"name": "Crime report",
"description": "Report on all pending claims, fines, and bounties",
"default": true,
"defaultValue": "{_ Crime report}\r\n{_ Report on all pending claims, fines, and bounties }\r\n\r\n\r\n{set factions_claims to []}\r\n{set claims_count to 0}\r\n{set factions_fines to []}\r\n{set fines_count to 0}\r\n{set factions_bounties to []}\r\n{set systems_bounties to []}\r\n\r\n{for record in criminalrecord:\r\n {set faction to FactionDetails(record.faction)}\r\n {if faction:\r\n {if record.bounties > 0:\r\n {set factions_bounties to cat(factions_bounties, [record.faction])}\r\n {for presence in faction.presences:\r\n {if find(presence.systemName, systems_bounties) = -1:\r\n {set systems_bounties to cat(systems_bounties, [presence.systemName])}\r\n }\r\n }\r\n }\r\n {if record.fines > 0:\r\n {set factions_fines to cat(factions_fines, [record.faction])}\r\n }\r\n {if record.claims > 0:\r\n {set factions_claims to cat(factions_claims, [record.faction])}\r\n }\r\n\r\n {for report in record.factionReports:\r\n {if !report.bounty && report.crimeEDName != \"none\":\r\n {set fines_count to fines_count + 1}\r\n }\r\n {if report.crimeEDName = \"none\":\r\n {set claims_count to claims_count + 1}\r\n }\r\n }\r\n }\r\n}\r\n\r\n{set factions_count to len(factions_bounties)}\r\n{set systems_count to len(factions_bounties)}\r\n\r\n{if factions_count > 0:\r\n You are wanted by {factions_count} {if factions_count = 1: faction |else: factions}\r\n in {systems_count} {if systems_count = 1: system |else: systems} for a total of\r\n {Humanise(bounties)} credits.\r\n}\r\n\r\n{set factions_count to len(factions_fines)}\r\n{if factions_count > 0:\r\n You have {fines_count} pending {if fines_count = 1: fine |else: fines} from\r\n {factions_count} {if factions_count = 1: faction |else: factions},\r\n for a total of {Humanise(fines)} credits.\r\n}\r\n\r\n{set factions_count to len(factions_claims)}\r\n{if factions_count > 0:\r\n You have {claims_count} uncollected {if claims_count = 1: claim |else: claims} from\r\n {factions_count} {if factions_count = 1: faction |else: factions},\r\n for a total of {Humanise(claims)} credits.\r\n}"
},
"Damage check": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Track if there is any damage}\r\n{set damaged to 0}\r\n\r\n{_ Announce hull health}\r\n{if ship.health < 100:\r\n Корпус {Humanise(ship.health)}%.\r\n {set damaged to 1}\r\n}\r\n\r\n{_ Announce critical module health}\r\n\r\n{set minordamage to []}\r\n{set majordamage to []}\r\n\r\n{if ship.powerplant.health < 60:\r\n {set majordamage to cat(majordamage, [ship.powerplant])}\r\n|elif ship.powerplant.health < 100:\r\n {set minordamage to cat(minordamage, [ship.powerplant])}\r\n}\r\n\r\n{if ship.thrusters.health < 60:\r\n {set majordamage to cat(majordamage, [ship.thrusters])}\r\n|elif ship.thrusters.health < 100:\r\n {set minordamage to cat(minordamage, [ship.thrusters])}\r\n}\r\n\r\n{if ship.frameshiftdrive.health < 60:\r\n {set majordamage to cat(majordamage, [ship.frameshiftdrive])}\r\n|elif ship.frameshiftdrive.health < 100:\r\n {set minordamage to cat(minordamage, [ship.frameshiftdrive])}\r\n}\r\n\r\n{if ship.powerdistributor.health < 60:\r\n {set majordamage to cat(majordamage, [ship.powerdistributor])}\r\n|elif ship.powerdistributor.health < 100:\r\n {set minordamage to cat(minordamage, [ship.powerdistributor])}\r\n}\r\n\r\n{if ship.lifesupport.health < 60:\r\n {set majordamage to cat(majordamage, [ship.lifesupport])}\r\n|elif ship.lifesupport.health < 100:\r\n {set minordamage to cat(minordamage, [ship.lifesupport])}\r\n}\r\n\r\n{if ship.sensors.health < 60:\r\n {set majordamage to cat(majordamage, [ship.sensors])}\r\n|elif ship.sensors.health < 100:\r\n {set minordamage to cat(minordamage, [ship.sensors])}\r\n}\r\n\r\n{if len(majordamage) > 0:\r\n {set damaged to 1}\r\n Значительный повреждение\r\n {if len(majordamage) = 1:\r\n {majordamage[0].name}\r\n |elif len(majordamage) = 2:\r\n {majordamage[0].name} и {majordamage[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(majordamage):\r\n {if cur = 0:\r\n {majordamage[cur].name}\r\n |elif cur < len(majordamage) - 1:\r\n , {majordamage[cur].name}\r\n |else:\r\n ,и {majordamage[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }.\r\n}\r\n\r\n{if len(minordamage) > 0:\r\n {set damaged to 1}\r\n Незначительное повреждение\r\n {if len(minordamage) = 1:\r\n {minordamage[0].name}\r\n |elif len(minordamage) = 2:\r\n {minordamage[0].name} и {minordamage[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(minordamage):\r\n {if cur = 0:\r\n {minordamage[cur].name}\r\n |elif cur < len(minordamage) - 1:\r\n , {minordamage[cur].name}\r\n |else:\r\n ,и {minordamage[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }.\r\n}\r\n\r\n{_ Announce other module health}\r\n\r\n{set minordamage to []}\r\n{set majordamage to []}\r\n\r\n{for compartment in ship.compartments:\r\n {if compartment.module.health < 60:\r\n {set majordamage to cat(majordamage, [compartment.module.name])}\r\n |elif hardpoint.module.health < 100:\r\n {set minordamage to cat(minordamage, [compartment.module.name])}\r\n }\r\n}\r\n\r\n{for hardpoint in ship.hardpoints:\r\n {if hardpoint.module.health < 60:\r\n {set majordamage to cat(majordamage, [hardpoint.module.name])}\r\n |elif hardpoint.module.health < 100:\r\n {set minordamage to cat(minordamage, [hardpiont.module.name])}\r\n }\r\n}\r\n\r\n{if len(majordamage) > 0:\r\n {set damaged to 1}\r\n {if len(majordamage) = 1:\r\n Еще один модуль корабля серьезно поврежден\r\n |elif len(majordamage) > 1:\r\n {len(majordamage)} другие модули корбля с серьезными повреждениями {_needs plural_}\r\n }\r\n {if len(minordamage) = 1:\r\n и еще один модуль корабля с незначительными повреждениями\r\n |elif len(minordamage) > 1:\r\n and {len(minordamage)} другие модули корабля с незначительными повреждениями {_needs plural_}\r\n }.\r\n|elif len(minordamage) = 1:\r\n {set damaged to 1}\r\n Еще один модуль корабля с незначительными повреждениями.\r\n|elif len(minordamage) > 1:\r\n {set damaged to 1}\r\n {len(minordamage)} другие модули корабля с незначительными повреждениями. {_needs plural_}\r\n}\r\n\r\n{if damaged = 0:\r\n {OneOf(\"Системы корабля полностью работоспособны.\", \"{ShipName()} полностью работоспособен.\", \"{ShipName()} не поврежден.\")}\r\n}\r\n",
"name": "Damage check",
"description": "Check on the levels of damage to your ship",
"default": false,
"defaultValue": "{_ Track if there is any damage}\r\n{set damaged to 0}\r\n\r\n{_ Announce hull health}\r\n{if ship.health < 100:\r\n Hull at {Humanise(ship.health)}%.\r\n {set damaged to 1}\r\n}\r\n\r\n{_ Announce critical module health}\r\n\r\n{set minordamage to []}\r\n{set majordamage to []}\r\n\r\n{if ship.powerplant.health < 60:\r\n {set majordamage to cat(majordamage, [ship.powerplant])}\r\n|elif ship.powerplant.health < 100:\r\n {set minordamage to cat(minordamage, [ship.powerplant])}\r\n}\r\n\r\n{if ship.thrusters.health < 60:\r\n {set majordamage to cat(majordamage, [ship.thrusters])}\r\n|elif ship.thrusters.health < 100:\r\n {set minordamage to cat(minordamage, [ship.thrusters])}\r\n}\r\n\r\n{if ship.frameshiftdrive.health < 60:\r\n {set majordamage to cat(majordamage, [ship.frameshiftdrive])}\r\n|elif ship.frameshiftdrive.health < 100:\r\n {set minordamage to cat(minordamage, [ship.frameshiftdrive])}\r\n}\r\n\r\n{if ship.powerdistributor.health < 60:\r\n {set majordamage to cat(majordamage, [ship.powerdistributor])}\r\n|elif ship.powerdistributor.health < 100:\r\n {set minordamage to cat(minordamage, [ship.powerdistributor])}\r\n}\r\n\r\n{if ship.lifesupport.health < 60:\r\n {set majordamage to cat(majordamage, [ship.lifesupport])}\r\n|elif ship.lifesupport.health < 100:\r\n {set minordamage to cat(minordamage, [ship.lifesupport])}\r\n}\r\n\r\n{if ship.sensors.health < 60:\r\n {set majordamage to cat(majordamage, [ship.sensors])}\r\n|elif ship.sensors.health < 100:\r\n {set minordamage to cat(minordamage, [ship.sensors])}\r\n}\r\n\r\n{if len(majordamage) > 0:\r\n {set damaged to 1}\r\n Major damage to\r\n {if len(majordamage) = 1:\r\n {majordamage[0].name}\r\n |elif len(majordamage) = 2:\r\n {majordamage[0].name} and {majordamage[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(majordamage):\r\n {if cur = 0:\r\n {majordamage[cur].name}\r\n |elif cur < len(majordamage) - 1:\r\n , {majordamage[cur].name}\r\n |else:\r\n ,and {majordamage[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }.\r\n}\r\n\r\n{if len(minordamage) > 0:\r\n {set damaged to 1}\r\n Minor damage to\r\n {if len(minordamage) = 1:\r\n {minordamage[0].name}\r\n |elif len(minordamage) = 2:\r\n {minordamage[0].name} and {minordamage[1].name}\r\n |else:\r\n {set cur to 0}\r\n {while cur < len(minordamage):\r\n {if cur = 0:\r\n {minordamage[cur].name}\r\n |elif cur < len(minordamage) - 1:\r\n , {minordamage[cur].name}\r\n |else:\r\n ,and {minordamage[cur].name}\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }.\r\n}\r\n\r\n{_ Announce other module health}\r\n\r\n{set minordamage to []}\r\n{set majordamage to []}\r\n\r\n{for compartment in ship.compartments:\r\n {if compartment.module.health < 60:\r\n {set majordamage to cat(majordamage, [compartment.module.name])}\r\n |elif hardpoint.module.health < 100:\r\n {set minordamage to cat(minordamage, [compartment.module.name])}\r\n }\r\n}\r\n\r\n{for hardpoint in ship.hardpoints:\r\n {if hardpoint.module.health < 60:\r\n {set majordamage to cat(majordamage, [hardpoint.module.name])}\r\n |elif hardpoint.module.health < 100:\r\n {set minordamage to cat(minordamage, [hardpiont.module.name])}\r\n }\r\n}\r\n\r\n{if len(majordamage) > 0:\r\n {set damaged to 1}\r\n {if len(majordamage) = 1:\r\n One other ship component with major damage\r\n |elif len(majordamage) > 1:\r\n {len(majordamage)} other ship components with major damage\r\n }\r\n {if len(minordamage) = 1:\r\n and one other ship component with minor damage\r\n |elif len(minordamage) > 1:\r\n and {len(minordamage)} other ship components with minor damage\r\n }.\r\n|elif len(minordamage) = 1:\r\n {set damaged to 1}\r\n One other ship component with minor damage.\r\n|elif len(minordamage) > 1:\r\n {set damaged to 1}\r\n {len(minordamage)} other ship components with minor damage.\r\n}\r\n\r\n{if damaged = 0:\r\n {OneOf(\"All systems fully operational.\", \"{ShipName()} is fully operational.\", \"{ShipName()} is undamaged.\")}\r\n}\r\n"
},
"Data scanned": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Data scanned }\r\n{_ Triggered when scanning some types of data links }\r\n\r\n\r\n{_ Context }\r\n{SetState('eddi_context_last_subject', 'scan')}\r\n{SetState('eddi_context_last_action', 'data')}\r\n{SetState('eddi_context_data_scan_type', event.datalinktype)}\r\n\r\nСканирование {event.datalinktype} завершено.",
"name": "Data scanned",
"description": "Triggered when scanning some types of data links",
"default": false,
"defaultValue": "{_ Data scanned }\r\n{_ Triggered when scanning some types of data links }\r\n\r\n\r\n{_ Context }\r\n{SetState('eddi_context_last_subject', 'scan')}\r\n{SetState('eddi_context_last_action', 'data')}\r\n{SetState('eddi_context_data_scan_type', event.datalinktype)}\r\n\r\nData scan of {event.datalinktype} completed."
},
"Data voucher awarded": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Data voucher awarded }\r\n{_ Triggered when you are awarded a data voucher }\r\n\r\n\r\n{_ Context }\r\n{SetState('eddi_context_last_subject', 'data_voucher')}\r\n{SetState('eddi_context_last_action', 'award')}\r\n{SetState('eddi_context_bond_amount', event.reward)}\r\n{SetState('eddi_context_bond_faction', event.payeefaction)}\r\n\r\nData voucher awarded from {P(event.payeefaction, \"faction\")} for {Humanise(event.reward)} credits.\r\n",
"name": "Data voucher awarded",
"description": "Triggered when you are awarded a data voucher",
"default": true,
"defaultValue": "{_ Data voucher awarded }\r\n{_ Triggered when you are awarded a data voucher }\r\n\r\n\r\n{_ Context }\r\n{SetState('eddi_context_last_subject', 'data_voucher')}\r\n{SetState('eddi_context_last_action', 'award')}\r\n{SetState('eddi_context_bond_amount', event.reward)}\r\n{SetState('eddi_context_bond_faction', event.payeefaction)}\r\n\r\nData voucher awarded from {P(event.payeefaction, \"faction\")} for {Humanise(event.reward)} credits.\r\n"
},
"Data voucher redeemed": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'data_voucher')}\r\n{SetState('eddi_context_last_action', 'redeem')}\r\n{SetState('eddi_context_data_voucher_amount', event.amount)}\r\n\r\n{set singular to len(event.rewards) = 1}\r\nData \r\n{if singular: voucher |else: vouchers}\r\nfor {Humanise(event.amount)} credits\r\n{Occasionally(2, \"{if singular: has |else: have} {Occasionally(2, 'now')} been\"))}\r\n{OneOf(\"redeemed\", \"claimed\")}\r\n\r\n{Occasionally(2, \"\r\n {if singular && len(event.rewards[0].faction) > 0:\r\n {OneOf(\"by\", \"courtesy of\")}\r\n {P(event.rewards[0].faction, \"faction\")}\r\n |else:\r\n {if len(event.rewards[0].faction) > 0:\r\n {OneOf(\"by\", \"courtesy of\")}\r\n {set cur to 0}\r\n {while cur < len(event.rewards):\r\n {if cur = 0:\r\n |elif cur < len(event.rewards) - 1:\r\n , \r\n |else:\r\n and\r\n }\r\n {P(event.rewards[cur].faction, \"faction\")}\r\n {set cur to cur + 1}\r\n }\r\n }\r\n }\r\n\")}.",
"name": "Data voucher redeemed",
"description": "Triggered when you redeem a data voucher",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'data_voucher')}\r\n{SetState('eddi_context_last_action', 'redeem')}\r\n{SetState('eddi_context_data_voucher_amount', event.amount)}\r\n\r\n{set singular to len(event.rewards) = 1}\r\nData \r\n{if singular: voucher |else: vouchers}\r\nfor {Humanise(event.amount)} credits\r\n{Occasionally(2, \"{if singular: has |else: have} {Occasionally(2, 'now')} been\"))}\r\n{OneOf(\"redeemed\", \"claimed\")}\r\n\r\n{Occasionally(2, \"\r\n {if singular && len(event.rewards[0].faction) > 0:\r\n {OneOf(\"by\", \"courtesy of\")}\r\n {P(event.rewards[0].faction, \"faction\")}\r\n |else:\r\n {if len(event.rewards[0].faction) > 0:\r\n {OneOf(\"by\", \"courtesy of\")}\r\n {set cur to 0}\r\n {while cur < len(event.rewards):\r\n {if cur = 0:\r\n |elif cur < len(event.rewards) - 1:\r\n , \r\n |else:\r\n and\r\n }\r\n {P(event.rewards[cur].faction, \"faction\")}\r\n {set cur to cur + 1}\r\n }\r\n }\r\n }\r\n\")}."
},
"Datalink message": {
"enabled": true,
"priority": 3,
"responder": true,
"script": null,
"name": "Datalink message",
"description": "Triggered upon completion of Datalink scan",
"default": true,
"defaultValue": null
},
"Died": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{if len(event.ships) > 0:\r\n\r\n {set commanders to []}\r\n {for cmdr in event.commanders:\r\n {if find(cmdr, \"$ShipName\") >= 0:\r\n {_ Ignore NPC ships _} \r\n |else: \r\n {set commanders to cat(commanders, [cmdr])}\r\n }\r\n }\r\n\r\n {ShipName()} was\r\n {Occasionally(2, \"just\")}\r\n {OneOf(\"blown away\", \"terminated\", \"destroyed\")}\r\n\r\n {if len(commanders) = 1:\r\n by {commanders[0]} \r\n in a {event.ships[0]} \r\n and with a combat ranking of {event.ratings[0]}.\r\n |elif len(commanders) = 2:\r\n by {commanders[0]} \r\n in a {event.ships[0]} and with a \r\n combat ranking of {event.ratings[0]}, \r\n and by {commanders[1]} \r\n in a {event.ships[1]} and with a \r\n combat ranking of {event.ratings[1]}.\r\n |elif len(commanders) > 2:\r\n {set cur to 0}\r\n by\r\n {while cur < len(commanders):\r\n {if cur = 0:\r\n {commanders[cur]} \r\n in a {event.ships[cur]} \r\n and with a combat ranking of {event.ratings[cur]}\r\n |elif cur < len(commanders) - 1:\r\n , {commanders[cur]} \r\n in a {event.ships[cur]} \r\n and with a combat ranking of {event.ratings[cur]}\r\n |else:\r\n , and {commanders[cur]} \r\n in a {event.ships[cur]} \r\n and with a combat ranking of {event.ratings[cur]}.\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n}",
"name": "Died",
"description": "Triggered when you have died",
"default": true,
"defaultValue": "{if len(event.ships) > 0:\r\n\r\n {set commanders to []}\r\n {for cmdr in event.commanders:\r\n {if find(cmdr, \"$ShipName\") >= 0:\r\n {_ Ignore NPC ships _} \r\n |else: \r\n {set commanders to cat(commanders, [cmdr])}\r\n }\r\n }\r\n\r\n {ShipName()} was\r\n {Occasionally(2, \"just\")}\r\n {OneOf(\"blown away\", \"terminated\", \"destroyed\")}\r\n\r\n {if len(commanders) = 1:\r\n by {commanders[0]} \r\n in a {event.ships[0]} \r\n and with a combat ranking of {event.ratings[0]}.\r\n |elif len(commanders) = 2:\r\n by {commanders[0]} \r\n in a {event.ships[0]} and with a \r\n combat ranking of {event.ratings[0]}, \r\n and by {commanders[1]} \r\n in a {event.ships[1]} and with a \r\n combat ranking of {event.ratings[1]}.\r\n |elif len(commanders) > 2:\r\n {set cur to 0}\r\n by\r\n {while cur < len(commanders):\r\n {if cur = 0:\r\n {commanders[cur]} \r\n in a {event.ships[cur]} \r\n and with a combat ranking of {event.ratings[cur]}\r\n |elif cur < len(commanders) - 1:\r\n , {commanders[cur]} \r\n in a {event.ships[cur]} \r\n and with a combat ranking of {event.ratings[cur]}\r\n |else:\r\n , and {commanders[cur]} \r\n in a {event.ships[cur]} \r\n and with a combat ranking of {event.ratings[cur]}.\r\n }\r\n {set cur to cur + 1}\r\n }\r\n }\r\n}"
},
"Discovery scan": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Fetch from Context, if a context is set _}\r\n{if state.eddi_context_system_name:\r\n {set reportSystem to SystemDetails(state.eddi_context_system_name)}\r\n|else:\r\n {set reportSystem to SystemDetails(system.systemname)}\r\n}\r\n\r\n{if !reportSystem.name || reportSystem.name = \"\":\r\n I'm not sure which system you are asking about.\r\n|else:\r\n {if ship.Role.edname = \"Exploration\" || \r\n (ship.Role.edname = \"Multipurpose\" && len(reportSystem.factions) = 0):\r\n\r\n {if reportSystem:\r\n \t{set reportedBodies to len(reportSystem.bodies)}\r\n {if 0 < reportedBodies && reportedBodies < event.totalbodies:\r\n {Pause(1000)}\r\n\r\n {set scannedBodies to 0}\r\n {for body in reportSystem.bodies:\r\n {if body.scanned:\r\n {set scannedBodies to scannedBodies + 1}\r\n }\r\n }\r\n {set bodiesToScan to (event.totalbodies- scannedBodies)}\r\n\r\n {if bodiesToScan = 1:\r\n \tOne body remains to be scanned\r\n |elif scannedBodies < event.totalbodies:\r\n {OneOf(\r\n \"{scannedBodies} out of {event.totalbodies} bodies {if scannedBodies != 1: have been scanned |else: has been scanned}\", \r\n \"{bodiesToScan} bodies remain to be scanned\"\r\n )}\r\n {Occasionally(3, OneOf(\"here\", \"in this system\"))}.\r\n }\r\n |else:\r\n {set bodiesToMap to F(\"Bodies to map\")}\r\n {if bodiesToMap:\r\n {bodiesToMap}\r\n }\r\n }\r\n }\r\n }\r\n}",
"name": "Discovery scan",
"description": "Triggered when performing a full system scan (honk)",
"default": true,
"defaultValue": "{_ Fetch from Context, if a context is set _}\r\n{if state.eddi_context_system_name:\r\n {set reportSystem to SystemDetails(state.eddi_context_system_name)}\r\n|else:\r\n {set reportSystem to SystemDetails(system.systemname)}\r\n}\r\n\r\n{if !reportSystem.name || reportSystem.name = \"\":\r\n I'm not sure which system you are asking about.\r\n|else:\r\n {if ship.Role.edname = \"Exploration\" || \r\n (ship.Role.edname = \"Multipurpose\" && len(reportSystem.factions) = 0):\r\n\r\n {if reportSystem:\r\n \t{set reportedBodies to len(reportSystem.bodies)}\r\n {if 0 < reportedBodies && reportedBodies < event.totalbodies:\r\n {Pause(1000)}\r\n\r\n {set scannedBodies to 0}\r\n {for body in reportSystem.bodies:\r\n {if body.scanned:\r\n {set scannedBodies to scannedBodies + 1}\r\n }\r\n }\r\n {set bodiesToScan to (event.totalbodies- scannedBodies)}\r\n\r\n {if bodiesToScan = 1:\r\n \tOne body remains to be scanned\r\n |elif scannedBodies < event.totalbodies:\r\n {OneOf(\r\n \"{scannedBodies} out of {event.totalbodies} bodies {if scannedBodies != 1: have been scanned |else: has been scanned}\", \r\n \"{bodiesToScan} bodies remain to be scanned\"\r\n )}\r\n {Occasionally(3, OneOf(\"here\", \"in this system\"))}.\r\n }\r\n |else:\r\n {set bodiesToMap to F(\"Bodies to map\")}\r\n {if bodiesToMap:\r\n {bodiesToMap}\r\n }\r\n }\r\n }\r\n }\r\n}"
},
"Docked": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{if event.state = \"Damaged\": Emergency}\r\nСтыковка завершена.\r\n\r\n{if event.activefine || event.wanted:\r\n Протоколы анонимизации запущены.\r\n}\r\n\r\n{if event.cockpitbreached:\r\n Рекомендуется произвести ремонт кабины.\r\n}",
"name": "Docked",
"description": "Triggered when your ship docks at a station or outpost",
"default": false,
"defaultValue": "{if event.state = \"Damaged\": Emergency}\r\nDocking complete.\r\n\r\n{if event.activefine || event.wanted:\r\n Anonymous protocols are in effect.\r\n}\r\n\r\n{if event.cockpitbreached:\r\n Canopy repair highly recommended.\r\n}"
},
"Docking cancelled": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Запрос на стыковку отменен.",
"name": "Docking cancelled",
"description": "Triggered when your ship cancels a docking request at a station or outpost",
"default": false,
"defaultValue": "Docking request cancelled."
},
"Docking denied": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{Pause(2000)}\r\n\r\nНам отказали в стыковке\r\n\r\n{if event.reason = \"ActiveFighter\":\r\n потому что один из наших истребителей развернут\r\n|elif event.reason = \"Distance\":\r\n потому что мы слишком далеко от станции\r\n|elif event.reason = \"Hostile\":\r\n потому что мы враждуем с фракцией, контролирующей станцию\r\n|elif event.reason = \"NoSpace\":\r\n because there is no space available\r\n|elif event.reason = \"Offences\":\r\n потому что недавно мы совершили преступление против них\r\n|elif event.reason = \"TooLarge\":\r\n потому что нет посадочных площадок, которые могли бы разместить корабль такого размера\r\n}.",
"name": "Docking denied",
"description": "Triggered when your ship is denied docking at a station or outpost",
"default": false,
"defaultValue": "{Pause(2000)}\r\n\r\nWe have been denied docking\r\n\r\n{if event.reason = \"ActiveFighter\":\r\n because our fighter is deployed\r\n|elif event.reason = \"Distance\":\r\n because we are too far from the station\r\n|elif event.reason = \"Hostile\":\r\n because the station's controlling faction doesn't like us\r\n|elif event.reason = \"NoSpace\":\r\n because there is no space available\r\n|elif event.reason = \"Offences\":\r\n because we have recently committed an offence against them\r\n|elif event.reason = \"TooLarge\":\r\n because there are no landing pads that can accomodate the size of our ship\r\n}."
},
"Docking granted": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'landing pad')}\r\n{SetState('eddi_context_landing_pad_system', system.name)}\r\n{SetState('eddi_context_landing_pad_station', event.station)}\r\n{SetState('eddi_context_landing_pad_station_model', event.stationtype)}\r\n{SetState('eddi_context_landing_pad_pad', event.landingpad)}\r\n\r\n{if event.stationDefinition.basename = \"Coriolis\" || \r\n event.stationDefinition.basename = \"Orbis\" || \r\n event.stationDefinition.basename = \"Bernal\" || \r\n event.stationDefinition.basename = \"Ocellus\" || \r\n event.stationDefinition.basename = \"AsteroidBase\":\r\n {Pause(8000)}\r\n {F(\"Landing pad report\")}\r\n|else:\r\n {Pause(8000)}\r\n Посадочная площадка {event.landingpad}\r\n {OneOf('готова', 'назначена вам', 'выделена для вас')}\r\n {Occasionally(4, cat(', ', F('Honorific') ))}.\r\n}",
"name": "Docking granted",
"description": "Triggered when your ship is granted docking permission at a station or outpost",
"default": false,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'landing pad')}\r\n{SetState('eddi_context_landing_pad_system', system.name)}\r\n{SetState('eddi_context_landing_pad_station', event.station)}\r\n{SetState('eddi_context_landing_pad_station_model', event.stationtype)}\r\n{SetState('eddi_context_landing_pad_pad', event.landingpad)}\r\n\r\n{if event.stationDefinition.basename = \"Coriolis\" || \r\n event.stationDefinition.basename = \"Orbis\" || \r\n event.stationDefinition.basename = \"Bernal\" || \r\n event.stationDefinition.basename = \"Ocellus\" || \r\n event.stationDefinition.basename = \"AsteroidBase\":\r\n {Pause(8000)}\r\n {F(\"Landing pad report\")}\r\n|else:\r\n {Pause(8000)}\r\n Landing pad {event.landingpad}\r\n {OneOf('ready', 'assigned', 'allocated')}\r\n {Occasionally(4, cat(', ', F('Honorific') ))}.\r\n}"
},
"Docking requested": {
"enabled": true,
"priority": 3,
"responder": true,
"script": null,
"name": "Docking requested",
"description": "Triggered when your ship requests docking at a station or outpost",
"default": true,
"defaultValue": null
},
"Docking timed out": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Нет ответа на наш запрос о стыковке.",
"name": "Docking timed out",
"description": "Triggered when your docking request times out",
"default": false,
"defaultValue": "No response to our docking request."
},
"Empire honorific": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Forms of address taken from <https://en.wikipedia.org/wiki/Forms_of_address_in_the_United_Kingdom>}\r\n{if cmdr.empirerating.rank <= 4: {_ Commoner }\r\n Командер\r\n|elif cmdr.empirerating.rank = 5: {_ Knight / Dame }\r\n {if cmdr.gender = \"Male\": \r\n Сэр \r\n |elif cmdr.gender = \"Female\": \r\n Мадам\r\n |else: \r\n Командер\r\n }\r\n|elif cmdr.empirerating.rank <= 11: {_ Peer / Peeress }\r\n {if cmdr.gender = \"Male\": \r\n {OneOf(\"Мой лорд\", \"Ваша светлость\")}\r\n |elif cmdr.gender = \"Female\": \r\n {OneOf(\"Моя леди\", \"Ваша светлость\")}\r\n |else: \r\n Командер\r\n }\r\n|elif cmdr.empirerating.rank = 12:\r\n Ваша милость\r\n|elif cmdr.empirerating.rank = 13:\r\n Ваше королевское высочетсво\r\n|elif cmdr.empirerating.rank = 14:\r\n ваше Величество\r\n}\r\n",
"name": "Empire honorific",
"description": "Function to provide a suitable honorific for your commander when in the empire",
"default": false,
"defaultValue": "{_ Forms of address taken from <https://en.wikipedia.org/wiki/Forms_of_address_in_the_United_Kingdom>}\r\n{if cmdr.empirerating.rank <= 4: {_ Commoner }\r\n commander\r\n|elif cmdr.empirerating.rank = 5: {_ Knight / Dame }\r\n {if cmdr.gender = \"Male\": \r\n sir \r\n |elif cmdr.gender = \"Female\": \r\n madam\r\n |else: \r\n commander\r\n }\r\n|elif cmdr.empirerating.rank <= 11: {_ Peer / Peeress }\r\n {if cmdr.gender = \"Male\": \r\n {OneOf(\"my lord\", \"your lordship\")}\r\n |elif cmdr.gender = \"Female\": \r\n {OneOf(\"my lady\", \"your ladyship\")}\r\n |else: \r\n commander\r\n }\r\n|elif cmdr.empirerating.rank = 12:\r\n your grace\r\n|elif cmdr.empirerating.rank = 13:\r\n your royal highness\r\n|elif cmdr.empirerating.rank = 14:\r\n your majesty\r\n}\r\n"
},
"Empire promotion": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Congratulations {F(\"Empire honorific\")},\r\nthe Imperial Navy has \r\n{OneOf(\"granted you a promotion\", \"promoted you\", \"advanced you\", \"named you\")}\r\nto the rank of\r\n{when(cmdr.gender = \"Female\", event.femininerank, event.rank)}\r\n{Occasionally(2, OneOf(\"within the Imperial Navy\", \"for your service to the Empire\"))}.\r\n\r\n{if event.rating = 1:\r\n You may now purchase the Imperial Eagle.\r\n|elif event.rating = 3:\r\n You may now purchase the Imperial Courier.\r\n|elif event.rating = 4:\r\n This grants you the honour of entering the {P(\"Achenar\", \"starsystem\")} system.\r\n|elif event.rating = 7:\r\n This allows you to purchase the Imperial Clipper, and the honour of entering the {P(\"Summerland\", \"starsystem\")} system.\r\n|elif event.rating = 10:\r\n This grants you the honour of entering the {P(\"Facece\", \"starsystem\")} system\r\n|elif event.rating = 12:\r\n You may now purchase the Imperial Cutter.\r\n|elif event.rating = 14:\r\n This is the highest {OneOf(\"rank\", \"honor\")} available to a member of the Imperial Naval Reserve.\r\n}\r\n",
"name": "Empire promotion",
"description": "Triggered when your rank increases with the Empire",
"default": true,
"defaultValue": "Congratulations {F(\"Empire honorific\")},\r\nthe Imperial Navy has \r\n{OneOf(\"granted you a promotion\", \"promoted you\", \"advanced you\", \"named you\")}\r\nto the rank of\r\n{when(cmdr.gender = \"Female\", event.femininerank, event.rank)}\r\n{Occasionally(2, OneOf(\"within the Imperial Navy\", \"for your service to the Empire\"))}.\r\n\r\n{if event.rating = 1:\r\n You may now purchase the Imperial Eagle.\r\n|elif event.rating = 3:\r\n You may now purchase the Imperial Courier.\r\n|elif event.rating = 4:\r\n This grants you the honour of entering the {P(\"Achenar\", \"starsystem\")} system.\r\n|elif event.rating = 7:\r\n This allows you to purchase the Imperial Clipper, and the honour of entering the {P(\"Summerland\", \"starsystem\")} system.\r\n|elif event.rating = 10:\r\n This grants you the honour of entering the {P(\"Facece\", \"starsystem\")} system\r\n|elif event.rating = 12:\r\n You may now purchase the Imperial Cutter.\r\n|elif event.rating = 14:\r\n This is the highest {OneOf(\"rank\", \"honor\")} available to a member of the Imperial Naval Reserve.\r\n}\r\n"
},
"Engineer contributed": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{event.engineer} \r\nthanks you for contributing\r\n{if event.contributiontype = \"Commodity\":\r\n {event.amount} tonne{if event.amount != 1:s} \r\n|elif event.contributiontype = \"Material\":\r\n {if material.category = 'Data':\r\n {event.amount} {OneOf(\"unit\", \"sample\", \"record\")}{if event.amount != 1:s}\r\n |else:\r\n {event.amount} {OneOf(\"unit\", \"sample\", \"fragment\")}{if event.amount != 1:s}\r\n }\r\n}\r\nof {event.contribution}.",
"name": "Engineer contributed",
"description": "Triggered when contributing resources to an engineer in exchange for access",
"default": true,
"defaultValue": "{event.engineer} \r\nthanks you for contributing\r\n{if event.contributiontype = \"Commodity\":\r\n {event.amount} tonne{if event.amount != 1:s} \r\n|elif event.contributiontype = \"Material\":\r\n {if material.category = 'Data':\r\n {event.amount} {OneOf(\"unit\", \"sample\", \"record\")}{if event.amount != 1:s}\r\n |else:\r\n {event.amount} {OneOf(\"unit\", \"sample\", \"fragment\")}{if event.amount != 1:s}\r\n }\r\n}\r\nof {event.contribution}."
},
"Engineer progressed": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{if event.progresstype = \"Stage\":\r\n\r\n {if event.stage = \"Known\":\r\n The Engineer {event.engineer} has sent you a message.\r\n |elif event.stage = \"Invited\":\r\n Workshop invitation received from {event.engineer}.\r\n |elif event.stage = \"Unlocked\":\r\n {event.engineer} has granted you access to workshop facilities.\r\n |elif event.stage = \"Barred\":\r\n {event.engineer} has {OneOf(\"barred\", \"restricted\")} your access to workshop facilities.\r\n }\r\n\r\n|elif event.engineer:\r\n\r\n {event.engineer} has\r\n {OneOf(\"given\", \"granted\")}\r\n you access to grade {event.rank} blueprints.\r\n\r\n}",
"name": "Engineer progressed",
"description": "Triggered when you reach a new rank with an engineer",
"default": true,
"defaultValue": "{if event.progresstype = \"Stage\":\r\n\r\n {if event.stage = \"Known\":\r\n The Engineer {event.engineer} has sent you a message.\r\n |elif event.stage = \"Invited\":\r\n Workshop invitation received from {event.engineer}.\r\n |elif event.stage = \"Unlocked\":\r\n {event.engineer} has granted you access to workshop facilities.\r\n |elif event.stage = \"Barred\":\r\n {event.engineer} has {OneOf(\"barred\", \"restricted\")} your access to workshop facilities.\r\n }\r\n\r\n|elif event.engineer:\r\n\r\n {event.engineer} has\r\n {OneOf(\"given\", \"granted\")}\r\n you access to grade {event.rank} blueprints.\r\n\r\n}"
},
"Engineer report": {
"enabled": true,
"priority": 3,
"responder": false,
"script": "{_ Fetch from Context, if a context is set _}\r\n{if state.eddi_context_system_name:\r\n {set systemname to state.eddi_context_system_name}\r\n|else:\r\n {set systemname to system.systemname}\r\n}\r\n\r\n{if !systemname || systemname = \"\":\r\n\r\n I'm not sure which system you are asking about.\r\n\r\n|else:\r\n\r\n {set reportEngineer to EngineerDetails(systemname)}\r\n {if reportEngineer:\r\n This system is home to {reportEngineer.name}, who\r\n {if len(reportEngineer.majorspecialties) > 0:\r\n specializes in {OneOf(\"improving\", \"upgrading\")}\r\n {List(reportEngineer.majorspecialties)}\r\n {if len(reportEngineer.minorspecialties) > 0:. They also}\r\n }\r\n {if len(reportEngineer.minorspecialties) > 0:\r\n {OneOf(\"improve\", \"upgrade\")} {List(reportEngineer.minorspecialties)}\r\n }.\r\n You can find {reportEngineer.name} at {P(reportEngineer.stationname, \"station\")}.\r\n }\r\n}",
"name": "Engineer report",
"description": "Report on the engineer in a contextual system",
"default": true,
"defaultValue": "{_ Fetch from Context, if a context is set _}\r\n{if state.eddi_context_system_name:\r\n {set systemname to state.eddi_context_system_name}\r\n|else:\r\n {set systemname to system.systemname}\r\n}\r\n\r\n{if !systemname || systemname = \"\":\r\n\r\n I'm not sure which system you are asking about.\r\n\r\n|else:\r\n\r\n {set reportEngineer to EngineerDetails(systemname)}\r\n {if reportEngineer:\r\n This system is home to {reportEngineer.name}, who\r\n {if len(reportEngineer.majorspecialties) > 0:\r\n specializes in {OneOf(\"improving\", \"upgrading\")}\r\n {List(reportEngineer.majorspecialties)}\r\n {if len(reportEngineer.minorspecialties) > 0:. They also}\r\n }\r\n {if len(reportEngineer.minorspecialties) > 0:\r\n {OneOf(\"improve\", \"upgrade\")} {List(reportEngineer.minorspecialties)}\r\n }.\r\n You can find {reportEngineer.name} at {P(reportEngineer.stationname, \"station\")}.\r\n }\r\n}"
},
"Entered CQC": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Entering close-quarters combat.",
"name": "Entered CQC",
"description": "Triggered when you enter CQC",
"default": true,
"defaultValue": "Entering close-quarters combat."
},
"Entered normal space": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Entered normal space }\r\n{_ Triggered when your ship enters normal space }\r\n\r\n\r\n{_ Context }\r\n{SetState('eddi_context_last_subject', 'fsd')}\r\n{SetState('eddi_context_last_action', 'disengage')}\r\n{SetState('eddi_context_system_name', event.system)}\r\n{SetState('eddi_context_body_name', event.body)}\r\n{SetState('eddi_context_body_type', event.bodytype)}\r\n{SetState('eddi_context_body_system', event.system)}\r\n\r\n{set station_notifications to:\r\n {set station_missions to F(\"Mission check station\")}\r\n {set station_crimes to F(\"Crime check station\")}\r\n {if station_missions || station_crimes:\r\n {_ Pause for station ATC before speaking again _}\r\n {Pause(5000)}\r\n Information:\r\n {if station_missions:\r\n {Pause(500)}\r\n {station_missions}\r\n }\r\n {if station_crimes:\r\n {Pause(500)}\r\n {station_crimes}\r\n }\r\n }\r\n}\r\n\r\n{Pause(500)}\r\n\r\n{OneOf(\"{ShipName()} has\", \"\")} \r\n{OneOf(\"left supercruise\", \"{OneOf(\\\"entered\\\", \\\"returned to\\\", \\\"dropped to\\\")} normal space\")}\r\n\r\n{if event.bodytype = 'Planet':\r\n {OneOf(\"near\", \"close to\", \"in the vicinity of\")}\r\n {set time to SecondsSince(0) - state.eddi_context_approach_time}\r\n {if time < 60:\r\n {set settlement to state.eddi_context_last_settlement}\r\n {set station to StationDetails(settlement, event.system)}\r\n {if station:\r\n {SetState('eddi_context_body_name', settlement)}\r\n {if station.Model.invariantName != \"Unknown\":\r\n {P(station.model, \"station\")},\r\n } \r\n {P(settlement, \"station\")}\r\n {station_notifications}\r\n |else:\r\n {P(settlement, \"station\")}\r\n }\r\n |else:\r\n planet {P(event.body, \"body\")}\r\n }\r\n|elif event.bodytype = 'Star':\r\n {OneOf(\"near\", \"close to\", \"in the vicinity of\")} star {P(event.body, \"body\")}\r\n|elif event.bodytype = 'Station':\r\n {set station to StationDetails(event.body, event.system)}\r\n {OneOf(\"near\", \"close to\", \"in the vicinity of\")}\r\n {P(station.model, \"station\")}, {P(event.body, \"body\")}\r\n {station_notifications}\r\n|elif event.bodytype = 'PlanetaryRing':\r\n Planetary Ring {P(token(event.body,\" Ring\",0), \"body\")}\r\n}.",
"name": "Entered normal space",
"description": "Triggered when your ship enters normal space",
"default": true,
"defaultValue": "{_ Entered normal space }\r\n{_ Triggered when your ship enters normal space }\r\n\r\n\r\n{_ Context }\r\n{SetState('eddi_context_last_subject', 'fsd')}\r\n{SetState('eddi_context_last_action', 'disengage')}\r\n{SetState('eddi_context_system_name', event.system)}\r\n{SetState('eddi_context_body_name', event.body)}\r\n{SetState('eddi_context_body_type', event.bodytype)}\r\n{SetState('eddi_context_body_system', event.system)}\r\n\r\n{set station_notifications to:\r\n {set station_missions to F(\"Mission check station\")}\r\n {set station_crimes to F(\"Crime check station\")}\r\n {if station_missions || station_crimes:\r\n {_ Pause for station ATC before speaking again _}\r\n {Pause(5000)}\r\n Information:\r\n {if station_missions:\r\n {Pause(500)}\r\n {station_missions}\r\n }\r\n {if station_crimes:\r\n {Pause(500)}\r\n {station_crimes}\r\n }\r\n }\r\n}\r\n\r\n{Pause(500)}\r\n\r\n{OneOf(\"{ShipName()} has\", \"\")} \r\n{OneOf(\"left supercruise\", \"{OneOf(\\\"entered\\\", \\\"returned to\\\", \\\"dropped to\\\")} normal space\")}\r\n\r\n{if event.bodytype = 'Planet':\r\n {OneOf(\"near\", \"close to\", \"in the vicinity of\")}\r\n {set time to SecondsSince(0) - state.eddi_context_approach_time}\r\n {if time < 60:\r\n {set settlement to state.eddi_context_last_settlement}\r\n {set station to StationDetails(settlement, event.system)}\r\n {if station:\r\n {SetState('eddi_context_body_name', settlement)}\r\n {if station.Model.invariantName != \"Unknown\":\r\n {P(station.model, \"station\")},\r\n } \r\n {P(settlement, \"station\")}\r\n {station_notifications}\r\n |else:\r\n {P(settlement, \"station\")}\r\n }\r\n |else:\r\n planet {P(event.body, \"body\")}\r\n }\r\n|elif event.bodytype = 'Star':\r\n {OneOf(\"near\", \"close to\", \"in the vicinity of\")} star {P(event.body, \"body\")}\r\n|elif event.bodytype = 'Station':\r\n {set station to StationDetails(event.body, event.system)}\r\n {OneOf(\"near\", \"close to\", \"in the vicinity of\")}\r\n {P(station.model, \"station\")}, {P(event.body, \"body\")}\r\n {station_notifications}\r\n|elif event.bodytype = 'PlanetaryRing':\r\n Planetary Ring {P(token(event.body,\" Ring\",0), \"body\")}\r\n}."
},
"Entered signal source": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{set warninglevel to:\r\n {set entered to OneOf(\"Entered\", \"Dropped into\", \"Entering\")}\r\n {if event.threat < 2:\r\n {entered}\r\n |elif event.threat = 2:\r\n Caution: {entered} medium threat\r\n |elif event.threat = 3:\r\n Warning: {entered} high-threat\r\n |elif event.threat = 4:\r\n Danger: {entered} very high-threat\r\n |elif event.threat = 5:\r\n Extreme Danger: {Occasionally(2, entered)} very high-threat\r\n |elif event.threat = 6:\r\n Extreme Danger: {Occasionally(2, entered)} extremely high-threat\r\n |elif event.threat = 7:\r\n Extreme Danger: {Occasionally(2, entered)} ultra high-threat\r\n |else:\r\n Extreme Danger: {Occasionally(2, entered)} Unprecedented level {event.threat} threat\r\n }\r\n}\r\n\r\n{set source to token(event.source, \"$USS_Type_\", 1)}\r\n\r\n{if source = \"Aftermath;\":\r\n {set source to OneOf(\"combat aftermath\", \"dissipating combat\")}\r\n|elif ((source = \"Anomaly;\" || source = \"Salvage;\") && event.threat = 2):\r\n {set warninglevel to entered}\r\n {set source to OneOf(\"alien\", \"xeno\", \"non-human\", \"Thargoid probe\")}\r\n|elif (source = \"Anomaly;\" && event.threat = 4):\r\n {set warninglevel to entered}\r\n {set source to OneOf(\"alien\", \"xeno\", \"non-human\", \"Thargoid sensor\")}\r\n|elif source = \"Anomaly;\":\r\n {set source to OneOf(\"anomalous\", \"unknown\", \"mysterious\")}\r\n|elif source = \"Ceremonial;\":\r\n {set source to \"ceremonial comms\"}\r\n|elif source = \"Convoy;\":\r\n {set source to \"convoy\"}\r\n|elif source = \"DisruptedWakeEchoes;\":\r\n {set source to \"\"}\r\n|elif source = \"DistressSignal;\":\r\n {set source to \"distress\"}\r\n|elif source = \"MissionTarget;\":\r\n {set source to OneOf(\"mission\", \"mission encoded\")}\r\n|elif source = \"NonHuman;\":\r\n {set source to OneOf(\"alien\", \"xeno\", \"non-human\")}\r\n|elif source = \"Salvage;\":\r\n {set source to \"degraded emissions\"}\r\n|elif source = \"ValuableSalvage;\":\r\n {set source to \"encoded emissions\"}\r\n|elif source = \"VeryValuableSalvage;\":\r\n {set source to \"high grade emissions\"}\r\n|elif source = \"WeaponsFire;\":\r\n {set source to OneOf(\"combat\", \"weapons fire\")}\r\n}\r\n\r\n{Pause(2000)}\r\n{warninglevel} {source} signal source. \r\n\r\n{if system.state = \"Anarchy\" && source = \"degraded emissions\" && system.population > 0: \r\n {Occasionally(2, \"\r\n Caution:\r\n {set local to OneOf('local', 'nearby')}\r\n {set chatter to OneOf('chatter', 'gossip', 'rumor')}\r\n {set indicate to OneOf('claims', 'suggests', 'implies', 'reports')}\r\n {OneOf('{local} transmissions {indicate}', \r\n '{chatter} in {local} transmissions {indicate}')}\r\n {Occasionally(3, 'that there is')}\r\n {OneOf('increased', 'elevated', 'heightened')}\r\n {OneOf('criminal {Occasionally(2, \\\\'syndicate\\\\')}', \r\n 'pirate {Occasionally(2, OneOf(\\\\'gang\\\\', \\\\'clan\\\\'))}' )}\r\n {OneOf('activity', 'presence')}\r\n in {OneOf('the area', 'the vicinity', 'this sector', 'this system')}.\r\n {OneOf('Remain', 'Stay', 'Keep')} {OneOf('vigilant', 'alert', 'frosty', 'sharp')} \r\n {Occasionally(3,' {F(\\\\'Honorific\\\\')}' )}.\r\n \")}\r\n}",
"name": "Entered signal source",
"description": "Triggered when your ship enters a signal source",
"default": true,
"defaultValue": "{set warninglevel to:\r\n {set entered to OneOf(\"Entered\", \"Dropped into\", \"Entering\")}\r\n {if event.threat < 2:\r\n {entered}\r\n |elif event.threat = 2:\r\n Caution: {entered} medium threat\r\n |elif event.threat = 3:\r\n Warning: {entered} high-threat\r\n |elif event.threat = 4:\r\n Danger: {entered} very high-threat\r\n |elif event.threat = 5:\r\n Extreme Danger: {Occasionally(2, entered)} very high-threat\r\n |elif event.threat = 6:\r\n Extreme Danger: {Occasionally(2, entered)} extremely high-threat\r\n |elif event.threat = 7:\r\n Extreme Danger: {Occasionally(2, entered)} ultra high-threat\r\n |else:\r\n Extreme Danger: {Occasionally(2, entered)} Unprecedented level {event.threat} threat\r\n }\r\n}\r\n\r\n{set source to token(event.source, \"$USS_Type_\", 1)}\r\n\r\n{if source = \"Aftermath;\":\r\n {set source to OneOf(\"combat aftermath\", \"dissipating combat\")}\r\n|elif ((source = \"Anomaly;\" || source = \"Salvage;\") && event.threat = 2):\r\n {set warninglevel to entered}\r\n {set source to OneOf(\"alien\", \"xeno\", \"non-human\", \"Thargoid probe\")}\r\n|elif (source = \"Anomaly;\" && event.threat = 4):\r\n {set warninglevel to entered}\r\n {set source to OneOf(\"alien\", \"xeno\", \"non-human\", \"Thargoid sensor\")}\r\n|elif source = \"Anomaly;\":\r\n {set source to OneOf(\"anomalous\", \"unknown\", \"mysterious\")}\r\n|elif source = \"Ceremonial;\":\r\n {set source to \"ceremonial comms\"}\r\n|elif source = \"Convoy;\":\r\n {set source to \"convoy\"}\r\n|elif source = \"DisruptedWakeEchoes;\":\r\n {set source to \"\"}\r\n|elif source = \"DistressSignal;\":\r\n {set source to \"distress\"}\r\n|elif source = \"MissionTarget;\":\r\n {set source to OneOf(\"mission\", \"mission encoded\")}\r\n|elif source = \"NonHuman;\":\r\n {set source to OneOf(\"alien\", \"xeno\", \"non-human\")}\r\n|elif source = \"Salvage;\":\r\n {set source to \"degraded emissions\"}\r\n|elif source = \"ValuableSalvage;\":\r\n {set source to \"encoded emissions\"}\r\n|elif source = \"VeryValuableSalvage;\":\r\n {set source to \"high grade emissions\"}\r\n|elif source = \"WeaponsFire;\":\r\n {set source to OneOf(\"combat\", \"weapons fire\")}\r\n}\r\n\r\n{Pause(2000)}\r\n{warninglevel} {source} signal source. \r\n\r\n{if system.state = \"Anarchy\" && source = \"degraded emissions\" && system.population > 0: \r\n {Occasionally(2, \"\r\n Caution:\r\n {set local to OneOf('local', 'nearby')}\r\n {set chatter to OneOf('chatter', 'gossip', 'rumor')}\r\n {set indicate to OneOf('claims', 'suggests', 'implies', 'reports')}\r\n {OneOf('{local} transmissions {indicate}', \r\n '{chatter} in {local} transmissions {indicate}')}\r\n {Occasionally(3, 'that there is')}\r\n {OneOf('increased', 'elevated', 'heightened')}\r\n {OneOf('criminal {Occasionally(2, \\\\'syndicate\\\\')}', \r\n 'pirate {Occasionally(2, OneOf(\\\\'gang\\\\', \\\\'clan\\\\'))}' )}\r\n {OneOf('activity', 'presence')}\r\n in {OneOf('the area', 'the vicinity', 'this sector', 'this system')}.\r\n {OneOf('Remain', 'Stay', 'Keep')} {OneOf('vigilant', 'alert', 'frosty', 'sharp')} \r\n {Occasionally(3,' {F(\\\\'Honorific\\\\')}' )}.\r\n \")}\r\n}"
},
"Entered supercruise": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'fsd')}\r\n{SetState('eddi_context_last_action', 'engage')}\r\n\r\n{Pause(1000)}\r\n\r\n{Occasionally(2, \"{ShipName()} has\")} {OneOf(\"entered\", \"jumped to\")} supercruise.",
"name": "Entered supercruise",
"description": "Triggered when your ship enters supercruise",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'fsd')}\r\n{SetState('eddi_context_last_action', 'engage')}\r\n\r\n{Pause(1000)}\r\n\r\n{Occasionally(2, \"{ShipName()} has\")} {OneOf(\"entered\", \"jumped to\")} supercruise."
},
"Exploration data purchased": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{OneOf(\"Purchased {OneOf('system', 'exploration')} data for {P(event.system, 'starsystem')}\",\r\n \"{OneOf('system', 'exploration')} data for {P(event.system, 'starsystem')} now available\",\r\n \"{Occasionally(3, '{ShipName()} has')} Received {OneOf('system', 'exploration')} data for {P(event.system, 'starsystem')} from station services\",\r\n \"Receipt of {P(event.system, 'starsystem')} {OneOf('system', 'exploration')} data confirmed\")}.",
"name": "Exploration data purchased",
"description": "Triggered when you purchase exploration data",
"default": true,
"defaultValue": "{OneOf(\"Purchased {OneOf('system', 'exploration')} data for {P(event.system, 'starsystem')}\",\r\n \"{OneOf('system', 'exploration')} data for {P(event.system, 'starsystem')} now available\",\r\n \"{Occasionally(3, '{ShipName()} has')} Received {OneOf('system', 'exploration')} data for {P(event.system, 'starsystem')} from station services\",\r\n \"Receipt of {P(event.system, 'starsystem')} {OneOf('system', 'exploration')} data confirmed\")}."
},
"Exploration data sold": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Exploration data for {len(event.systems)} \r\n{if len(event.systems) = 1: system |else: systems} \r\nsold for {Humanise(event.total)} credits\r\n\r\n{if event.bonus > 0:\r\n , including a bonus of {Humanise(event.bonus)} credits for first discoveries\r\n}.",
"name": "Exploration data sold",
"description": "Triggered when you sell exploration data",
"default": true,
"defaultValue": "Exploration data for {len(event.systems)} \r\n{if len(event.systems) = 1: system |else: systems} \r\nsold for {Humanise(event.total)} credits\r\n\r\n{if event.bonus > 0:\r\n , including a bonus of {Humanise(event.bonus)} credits for first discoveries\r\n}."
},
"Exploration promotion": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "You have been recognised for your exploration skills, {F(\"Honorific\")}.",
"name": "Exploration promotion",
"description": "Triggered when your exploration rank increases",
"default": true,
"defaultValue": "You have been recognised for your exploration skills, {F(\"Honorific\")}."
},
"Federation promotion": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{set plainHonorific to when(cmdr.gender = 'Female', 'Madam', 'Sir')}\r\n\r\nCongratulations {OneOf('Commander {CommanderName()}', plainHonorific)}! You have\r\n{OneOf('achieved', 'been promoted to', 'been granted')}\r\nthe rank of {event.rank}\r\n{Occasionally(2, OneOf('within the Federal Navy', 'for your service to the Federation'))}.\r\n\r\n{if event.rating = 3:\r\n You now qualify to purchase the Federal Dropship.\r\n|elif event.rating = 4:\r\n This grants you access to the {P('Sol', 'starsystem')} system.\r\n|elif event.rating = 5:\r\n You now qualify to purchase the Federal Assault Ship, and have access to the {P('Vega', 'starsystem')} and {P('Beta Hydri', 'starsystem')} systems.\r\n|elif event.rating = 6:\r\n This grants you access to the {P('PLX 695', 'starsystem')} system.\r\n|elif event.rating = 7:\r\n You now qualify to purchase the Federal Gunship, and have access to the {P('Ross 128', 'starsystem')} system.\r\n|elif event.rating = 8:\r\n This grants you access to the {P('Exbeur', 'starsystem')} system.\r\n|elif event.rating = 10:\r\n This grants you access to the {P('Hors', 'starsystem')} system.\r\n|elif event.rating = 12:\r\n You now qualify to purchase the Federal Corvette.\r\n|elif event.rating = 14:\r\n This is the highest rank available to a member of the Federal Naval Reserve.\r\n}\r\n",
"name": "Federation promotion",
"description": "Triggered when your rank increases with the Federation",
"default": true,
"defaultValue": "{set plainHonorific to when(cmdr.gender = 'Female', 'Madam', 'Sir')}\r\n\r\nCongratulations {OneOf('Commander {CommanderName()}', plainHonorific)}! You have\r\n{OneOf('achieved', 'been promoted to', 'been granted')}\r\nthe rank of {event.rank}\r\n{Occasionally(2, OneOf('within the Federal Navy', 'for your service to the Federation'))}.\r\n\r\n{if event.rating = 3:\r\n You now qualify to purchase the Federal Dropship.\r\n|elif event.rating = 4:\r\n This grants you access to the {P('Sol', 'starsystem')} system.\r\n|elif event.rating = 5:\r\n You now qualify to purchase the Federal Assault Ship, and have access to the {P('Vega', 'starsystem')} and {P('Beta Hydri', 'starsystem')} systems.\r\n|elif event.rating = 6:\r\n This grants you access to the {P('PLX 695', 'starsystem')} system.\r\n|elif event.rating = 7:\r\n You now qualify to purchase the Federal Gunship, and have access to the {P('Ross 128', 'starsystem')} system.\r\n|elif event.rating = 8:\r\n This grants you access to the {P('Exbeur', 'starsystem')} system.\r\n|elif event.rating = 10:\r\n This grants you access to the {P('Hors', 'starsystem')} system.\r\n|elif event.rating = 12:\r\n You now qualify to purchase the Federal Corvette.\r\n|elif event.rating = 14:\r\n This is the highest rank available to a member of the Federal Naval Reserve.\r\n}\r\n"
},
"Fighter docked": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Fighter {OneOf(\"docked\", \"redocked\")} {Occasionally(2, \"with ship\")}.",
"name": "Fighter docked",
"description": "Triggered when you dock a fighter with your ship",
"default": true,
"defaultValue": "Fighter {OneOf(\"docked\", \"redocked\")} {Occasionally(2, \"with ship\")}."
},
"Fighter launched": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Fighter {OneOf(\"deploying\", \"launching\")} {Occasionally(2, \"from mothership\")}.",
"name": "Fighter launched",
"description": "Triggered when you launch a fighter from your ship",
"default": true,
"defaultValue": "Fighter {OneOf(\"deploying\", \"launching\")} {Occasionally(2, \"from mothership\")}."
},
"Fighter rebuilt": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "Fighter {OneOf(\"rebuilt\", \"reconstruction complete\")} and ready for {OneOf(\"launch\", \"deployment\")}.",
"name": "Fighter rebuilt",
"description": "Triggered when a ship's fighter is rebuilt in the hangar",
"default": true,
"defaultValue": "Fighter {OneOf(\"rebuilt\", \"reconstruction complete\")} and ready for {OneOf(\"launch\", \"deployment\")}."
},
"File Header": {
"enabled": true,
"priority": 3,
"responder": true,
"script": null,
"name": "File Header",
"description": "Triggered when the file header is read",
"default": true,
"defaultValue": null
},
"Fine incurred": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'fine')}\r\n{SetState('eddi_context_last_action', 'incur')}\r\n{SetState('eddi_context_fine_name', event.victim)}\r\n{SetState('eddi_context_fine_faction', event.faction)}\r\n{SetState('eddi_context_fine_amount', event.fine)}\r\n\r\nYou owe {P(event.faction, \"faction\")} {Humanise(event.fine)} credits for {event.crime}.",
"name": "Fine incurred",
"description": "Triggered when you incur a fine",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'fine')}\r\n{SetState('eddi_context_last_action', 'incur')}\r\n{SetState('eddi_context_fine_name', event.victim)}\r\n{SetState('eddi_context_fine_faction', event.faction)}\r\n{SetState('eddi_context_fine_amount', event.fine)}\r\n\r\nYou owe {P(event.faction, \"faction\")} {Humanise(event.fine)} credits for {event.crime}."
},
"Fine paid": {
"enabled": true,
"priority": 3,
"responder": true,
"script": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'fine')}\r\n{SetState('eddi_context_last_action', 'pay')}\r\n{SetState('eddi_context_fine_amount', event.amount)}\r\n\r\n\r\nPaid fine of {Humanise(event.amount)} credits.",
"name": "Fine paid",
"description": "Triggered when you pay a fine",
"default": true,
"defaultValue": "{_ Context }\r\n{SetState('eddi_context_last_subject', 'fine')}\r\n{SetState('eddi_context_last_action', 'pay')}\r\n{SetState('eddi_context_fine_amount', event.amount)}\r\n\r\n\r\nPaid fine of {Humanise(event.amount)} credits."
},
"Flight assist": {
"enabled": true,
"priority": 3,
"responder": true,
"script": null,
"name": "Flight assist",
"description": "Triggered when flight assist is toggled",
"default": true,
"defaultValue": null
},
"Friends status": {
"enabled": false,
"priority": 3,
"responder": true,
"script": "{_ Set uselist to \"white\" or \"black\", depending on which list you want to use to filter people _}\r\n{_ \"white\" will only allow notifications from people in this list (e.g. \"User1\", \"User2\", & \"User3\") _}\r\n{_ \"black\" will allow all notification EXCEPT those on this list (e.g. \"User4\", \"User5\", & \"User6\") _}\r\n{_ to allow all notifications, you may also use an empty blacklist (i.e. \"set blacklist to []\" _}\r\n\r\n{set uselist to \"black\"}\r\n\r\n{set whitelist to [\"User1\", \"User2\", \"User3\"]}\r\n{set blacklist to [\"User4\", \"User5\", \"User6\"]}\r\n\r\n{if event.name:\r\n {if uselist = \"white\":\r\n {if find(whitelist, event.name) > -1:\r\n {event.name} is now {event.status}.\r\n }\r\n |elif uselist = \"black\":\r\n {if find(blacklist, event.name) = -1:\r\n {event.name} is now {event.status}.\r\n }\r\n }\r\n|else:\r\n I don't know who you are talking about.\r\n}",
"name": "Friends status",