forked from Trimps/Trimps.github.io
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.js
More file actions
5434 lines (5395 loc) · 173 KB
/
config.js
File metadata and controls
5434 lines (5395 loc) · 173 KB
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
/* Trimps
Copyright (C) 2016 Zach Hood
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program (if you are reading this on the original
author's website, you can find a copy at
<trimps.github.io/license.txt>). If not, see
<http://www.gnu.org/licenses/>. */
//Spoilers ahead, proceed with caution
function newGame () {
var toReturn = {
global: {
version: 3.231,
isBeta: false,
killSavesBelow: 0.13,
playerGathering: "",
playerModifier: 1,
buildingsQueue: [],
timeLeftOnCraft: 0,
crafting: "",
timeLeftOnTrap: -1,
world: 1,
gridArray: [],
mapGridArray: [],
mapsOwnedArray: [],
currentMapId: "",
lastClearedCell: -1,
lastClearedMapCell: -1,
pauseFight: true,
soldierHealth: 0,
soldierHealthMax: 0,
soldierHealthRemaining: 0,
soldierCurrentAttack: 0,
soldierCurrentBlock: 0,
radioStacks: 0,
fighting: false,
health: 50,
attack: 6,
block: 0,
autoBattle: false,
autoCraftModifier: 0,
start: new Date().getTime(),
time: 0,
portalTime: new Date().getTime(),
lastFightUpdate: "",
battleCounter: 0,
firing: false,
mapsActive: false,
preMapsActive: false,
switchToMaps: false,
switchToWorld: false,
lookingAtMap: "",
mapsOwned: 0,
totalMapsEarned: 0,
freshFight: false,
tab: "All",
repeatMap: false,
buyAmt: 1,
numTab: 1,
spreadsheetMode: false,
lockTooltip: false,
portalActive: false,
mapsUnlocked: false,
lastOnline: 0,
buyTab: "all",
nextQueueId: 0,
kongBonusMode: false,
canRespecPerks: true,
respecActive: false,
heliumLeftover: 0,
viewingUpgrades: false,
totalPortals: 0,
lastCustomAmt: 1,
trapBuildAllowed: false,
trapBuildToggled: false,
lastSkeletimp: 0,
pp: [],
highestLevelCleared: 0,
b: 0,
challengeActive: "",
selectedChallenge: "",
lastOfflineProgress: "",
sLevel: 0,
totalGifts: 0,
brokenPlanet: false,
formation: 0,
bestHelium: 0,
tempHighHelium: 0,
totalHeliumEarned: 0,
removingPerks: false,
lastBreedTime: 0,
antiStacks: 0,
prisonClear: 0,
frugalDone: false,
lastUnlock: 0,
lowestGen: -1,
breedBack: -1,
titimpLeft: 0,
mapBonus: 0,
slowDone: false,
turkimpTimer: 0,
statsMode: "current",
achievementBonus: 0,
lastLowGen: 0,
presimptStore: "food",
lastWarp: 0,
zoneStarted: new Date().getTime(),
mapStarted: new Date().getTime(),
bionicOwned: 0,
roboTrimpLevel: 0,
roboTrimpCooldown: 0,
useShriek: false,
usingShriek: false,
autoUpgrades: false,
autoPrestiges: 0,
autoStorage: false,
autoStorageAvailable: false,
totalVoidMaps: 0,
voidMapsToggled: false,
voidBuff: "",
lastVoidMap: 0,
voidSeed: Math.floor(Math.random() * 1000000),
heirloomSeed: Math.floor(Math.random() * 1000000),
heirloomBoneSeed: Math.floor(Math.random() * 1000000),
eggSeed: Math.floor(Math.random() * 1000000),
heirloomsExtra: [],
heirloomsCarried: [],
StaffEquipped: {},
ShieldEquipped: {},
nullifium: 0,
maxCarriedHeirlooms: 1,
selectedHeirloom: [],
lastPortal: -1,
addonUser: false,
eggLoc: -1,
researched: false,
bonePortalThisRun: false,
maxSplit: 1,
maxSoldiersAtStart: -1,
playFabLoginType: -1,
lastCustomExact: 1,
voidMaxLevel: -1,
sessionMapValues: {
loot: 0,
difficulty: 0,
size: 0,
biome: "Random"
},
lootAvgs: {
food: [0],
foodTotal: 0,
wood: [0],
woodTotal: 0,
metal: [0],
metalTotal: 0,
gems: [0],
gemsTotal: 0,
fragments: [0],
fragmentsTotal: 0
},
menu: {
buildings: true,
jobs: false,
upgrades: false
},
messages: {
Story: true,
Loot: true,
Unlocks: true,
Combat: true,
Notices: true
},
prestige: {
attack: 13,
health: 14,
cost: 57,
block: 10
},
difs: {
attack: 0,
health: 0,
block: 0,
trainers: 0
},
getEnemyAttack: function (level, name) {
var world = getCurrentMapObject();
var amt = 0;
world = (game.global.mapsActive) ? world.level : game.global.world;
var adjWorld = ((world - 1) * 100) + level;
amt += 50 * Math.sqrt(world) * Math.pow(3.27, world / 2);
amt -= 10;
if (world == 1){
amt *= 0.35;
amt = (amt * 0.20) + ((amt * 0.75) * (level / 100));
}
else if (world == 2){
amt *= 0.5;
amt = (amt * 0.32) + ((amt * 0.68) * (level / 100));
}
else if (world < 60)
amt = (amt * 0.375) + ((amt * 0.7) * (level / 100));
else{
amt = (amt * 0.4) + ((amt * 0.9) * (level / 100));
amt *= Math.pow(1.15, world - 59);
}
if (world < 60) amt *= 0.85;
if (world > 6 && game.global.mapsActive) amt *= 1.1;
amt *= game.badGuys[name].attack;
return Math.floor(amt);
},
getEnemyHealth: function (level, name) {
var world = getCurrentMapObject();
world = (game.global.mapsActive) ? world.level : game.global.world;
var amt = 0;
amt += 130 * Math.sqrt(world) * Math.pow(3.265, world / 2);
amt -= 110;
if (world == 1 || world == 2 && level < 10){
amt *= 0.6;
amt = (amt * 0.25) + ((amt * 0.72) * (level / 100));
}
else if (world < 60)
amt = (amt * 0.4) + ((amt * 0.4) * (level / 110));
else{
amt = (amt * 0.5) + ((amt * 0.8) * (level / 100));
amt *= Math.pow(1.1, world - 59);
}
if (world < 60) amt *= 0.75;
if (world > 5 && game.global.mapsActive) amt *= 1.1;
amt *= game.badGuys[name].health;
return Math.floor(amt);
}
},
options: {
displayed: false,
menu: {
autoSave: {
enabled: 1,
description: "Automatically save the game once per minute",
titles: ["Not Saving", "Auto Saving"],
onToggle: function () {
var elem = document.getElementById("saveIndicator");
if (this.enabled) elem.innerHTML = "<span class='autosaving'>(AutoSaving)</span>";
else elem.innerHTML = "<span class='notAutosaving'>(Not AutoSaving)</span>";
}
},
usePlayFab: {
enabled: 0,
description: "<b>Beta:</b> Whenever the game saves, also back up a copy online with PlayFab. While using this setting, you will be asked if you want to download your online save if it is ever ahead of the version on your computer. You can also manually import your save from PlayFab through the Import menu.",
titles: ["Not Saving Online", "Saving with PlayFab"],
onToggle: function () {
var indicatorElem = document.getElementById("playFabIndicator");
if (this.enabled == 1) indicatorElem.className = "icomoon icon-wifi iconStateGood";
else indicatorElem.className = "";
}
},
standardNotation: {
enabled: 1,
description: "Swap between standard and exponential number formatting",
titles: ["Exponential Formatting", "Standard Formatting"],
},
tooltips: {
enabled: 1,
description: "Hide button tooltips unless shift is held.",
titles: ["Shift for Tooltips", "Showing Tooltips"]
},
tooltipPosition: {
enabled: 0,
description: "Toggle between top and right of mouse tooltip positioning, and centered above or below positioning for the tooltips.",
titles: ["Top Right Tips", "Center Bottom Tips", "Center Top Tips"]
},
queueAnimation: {
enabled: 1,
description: "Toggle on or off the building queue blue color animation.",
titles: ["No Animation", "Animation"]
},
barOutlines: {
enabled: 1,
description: "Toggle on or off a black bar at the end of all progress bars. Can help discern where the progress bar ends.",
titles: ["No Outline", "Outline"],
onToggle: function () {
var outlineStyle = (this.enabled) ? "2px solid black" : "none";
var bars = document.getElementsByClassName("progress-bar");
for (var x = 0; x < bars.length; x++){
bars[x].style.borderRight = outlineStyle;
}
}
},
menuFormatting: {
enabled: 1,
description: "Toggle on or off large number formatting for jobs and buildings on the left menu. This turns 1000000 in to 1M.",
titles: ["No Menu Formatting", "Formatting Menu"]
},
progressBars: {
enabled: 1,
description: "Toggle progress bars to on, off, or performance. Performance and off will reduce CPU usage.",
titles: ["No Progress Bars", "Progress Bars", "Performance Bars"],
onToggle: function () {
var bars = document.getElementsByClassName("progress-bar");
for (var x = 0; x < bars.length; x++){
if (this.enabled == 2) bars[x].className += " noTransition";
else {
bars[x].className = bars[x].className.replace(" noTransition", "");
if (this.enabled == 0) bars[x].style.width = "0%";
}
}
}
},
confirmhole: {
enabled: 1,
description: "Toggles on or off the confirmation pop-up on scary purchases like Wormholes.",
titles: ["Not Confirming", "Confirming"],
},
lockOnUnlock: {
enabled: 0,
description: "Enables/disables the locking of buildings, jobs, upgrades, and equipment for 1 second after unlocking something new. Useful to prevent accidental purchases.",
titles: ["Not Locking", "Locking"],
},
achievementPopups: {
enabled: 1,
description: "Decide whether or not you want popups on completing an achievement.",
titles: ["Not Popping", "Popping"]
},
mapLoot: {
enabled: 0,
description: "<p>Choose which upgrades you want first if it has been a while since you last ran maps.</p><p><b>Tier first</b> will cause maps to drop all items for the lowest tier before moving to the next. (Greatsword II -> Breastplate II -> Shield III)</p><p><b>Equip first</b> will start from Shield and drop all available Shield prestiges before continuing to Dagger and so on. (Shield III -> Shield IV -> Dagger III)</p>",
titles: ["Tier First", "Equip First"],
secondLocation: "togglemapLoot2",
},
repeatUntil: {
enabled: 0,
description: "<b>Repeat Forever</b> will cause the map to continually repeat if Repeat Maps is enabled. <b>Repeat to 10</b> will exit the map after 10 stacks, if the map's level is high enough. <b>Repeat for Items</b> will exit the map once there are no more special items left for that level of map. <br/><br/><b>This setting only matters if Repeat is on. Toggling Repeat off will still leave the map when it is finished no matter what.</b>",
titles: ["Repeat Forever", "Repeat to 10", "Repeat for Items"],
locked: true
},
exitTo: {
enabled: 0,
description: "Choose whether to go to the Maps Screen or World after completing a map.",
titles: ["Exit to Maps", "Exit to World"],
locked: true
},
repeatVoids: {
enabled: 0,
description: "Decide if you want to continue running the rest of your Void Maps after finishing one.",
titles: ["One Void Map", "Finish All Voids"],
locked: true
},
boneAlerts: {
enabled: 1,
description: "Hide popup confirmation messages when in the Bone Trader or Heirlooms menus.",
titles: ["Not Popping", "Popping"]
},
showAlerts: {
enabled: 1,
description: "Toggle on or off the display of yellow alert icons when unlocking something new.",
titles: ["Not Alerting", "Alerting"]
},
showFullBreed: {
enabled: 0,
description: "Display time to breed a full group of soldiers next to the current breed timer.",
titles: ["Less Breed Timer", "More Breed Timer"]
},
darkTheme: {
enabled: 1,
description: "Toggle between the default Trimps theme, a custom dark theme made by u/Grabarz19, and the default theme with a black background.",
titles: ["Black Background", "Default Theme", "Dark Theme"],
onToggle: function () {
var link;
if (this.enabled == 2){
link = document.createElement('link');
link.type = 'text/css';
link.rel = 'stylesheet';
link.href = 'css/dark.css';
link.id = 'darkTheme';
document.head.appendChild(link);
return;
}
if (this.enabled == 0) {
document.getElementById("innerWrapper").style.backgroundColor = "black";
link = document.getElementById("darkTheme");
if (!link) return;
link.disabled = true;
document.head.removeChild(link);
return;
}
document.getElementById("innerWrapper").style.backgroundColor = "initial";
},
restore: function () {
document.getElementById("innerWrapper").style.backgroundColor = "initial";
link = document.getElementById("darkTheme");
if (!link) return;
link.disabled = true;
document.head.removeChild(link);
}
},
fadeIns: {
enabled: 1,
description: "Toggle on or off the fade in effect on elements.",
titles: ["Not Fading", "Fading"]
},
extraStats: {
enabled: 0,
description: "Toggle on or off adding extra information to map items.",
titles: ["Standard Maps", "Extra Info"],
onToggle: function () {
refreshMaps();
}
},
useAverages: {
enabled: 0,
description: "<b>Experimental, may be jumpy.</b> Toggle on or off whether or not loot from maps and the world should be counted in the loot breakdown and tooltip calculations. Calculates the average of the last two minutes of loot. If you want to clear the last 2 minutes, try toggling it off and on again.",
titles: ["Not Averaging", "Averaging"],
onToggle: function () {
for (var item in game.global.lootAvgs){
if (Array.isArray(game.global.lootAvgs[item])) game.global.lootAvgs[item] = [0];
else game.global.lootAvgs[item] = 0;
}
}
},
voidPopups: {
enabled: 1,
description: "Decide whether or not you want popups on looting an Heirloom.",
titles: ["No Heirloom Pop", "Popping Heirlooms"]
},
detailedPerks: {
enabled: 0,
description: "Decide whether or not to show extra information on Perk buttons",
titles: ["Minimal Perk Info", "Extra Perk Info"]
},
alwaysAbandon: {
enabled: 0,
description: "Decide whether or not to wait for soldiers to die on switching between maps and world. Toggling this on will automatically abandon your soldiers.",
titles: ["Wait to Travel", "Auto Abandon"]
},
extraMapBtns: {
enabled: 0,
description: "Toggle the button menu to the right of the map grid",
titles: ["Less Map Buttons", "Extra Map Buttons"],
onToggle: function () {
if (!game.global.mapsActive) return;
var setTo = (this.enabled) ? ["8", "2"] : ["10", "off"];
swapClass("col-xs", "col-xs-" + setTo[0], document.getElementById("gridContainer"));
swapClass("col-xs", "col-xs-" + setTo[1], document.getElementById("extraMapBtns"));
},
lockUnless: function () {
return (game.global.totalPortals > 0)
},
},
overkillColor: {
enabled: 1,
description: "Choose if you would like to see a different cell color for cells that you overkilled. Toggle between off, showing both cells involved in the overkill, or just showing the 1 cell that was skipped.",
titles: ["No Overcolors", "1 Overkill Cell", "2 Overkill Cells"],
lockUnless: function () {
return (!game.portal.Overkill.locked)
},
},
pauseGame: {
enabled: 0,
description: "Pause your game. This will pause all resource gathering, offline progress, and timers.",
titles: ["Not Paused", "Paused"],
timeAtPause: 0,
onToggle: function () {
if (this.enabled) {
this.timeAtPause = new Date().getTime();
if (game.options.menu.autoSave.enabled == 1) save();
}
else if (this.timeAtPause) {
var now = new Date().getTime();
var dif = now - this.timeAtPause;
game.global.portalTime += dif;
game.global.lastSkeletimp += dif;
game.global.zoneStarted += dif;
game.global.mapStarted += dif;
this.timeAtPause = 0;
game.global.time = 0;
game.global.lastOnline = now;
game.global.start = now;
setTimeout(gameTimeout, (100));
setTimeout(updatePortalTimer, 1000);
}
}
},
deleteSave: {
enabled: 0,
description: "Delete your save and start fresh. Your Trimps will not be happy.",
titles: ["Delete Save"],
onToggle: function () {
cancelTooltip();
tooltip('Reset', null, 'update');
game.global.lockTooltip = true;
tooltipUpdateFunction = "";
this.enabled = 0;
}
}
}
},
//portal
portal: {
Overkill: {
level: 0,
locked: true,
priceBase: 1000000,
heliumSpent: 0,
tooltip: "You have overcome the otherworldly objective of obtaining Overkill, outstanding! Each level of this perk will allow 0.5% of your overkill damage to harm the next enemy. If this damage kills the next enemy, you will lose no time moving through that cell.",
max: 30
},
Resourceful: {
level: 0,
locked: true,
modifier: 0.05,
priceBase: 50000,
heliumSpent: 0,
tooltip: "Spending time with limited maps has taught you how to be more resourceful. Each level will allow you to spend 5% fewer resources <b>than the current cost</b> per level on all structures."
},
Coordinated: {
level: 0,
locked: true,
priceBase: 150000,
modifier: 0.98,
heliumSpent: 0,
currentSend: 1,
onChange: function (overrideLevel) {
var newValue = 1;
var level = (overrideLevel) ? this.level + this.levelTemp : this.level;
var currentMod = 0.25 * Math.pow(this.modifier, level);
currentMod += 1;
for (var x = 0; x < game.upgrades.Coordination.done; x++){
newValue = Math.ceil(newValue * currentMod);
}
if (overrideLevel) return newValue;
this.currentSend = newValue;
},
tooltip: "Use knowledge gained while studying Coordinated Bad Guys to reduce the amount of Trimps required per level of Coordination by 2% <b>of current amount (compounding)</b>, while keeping the stat bonus the same."
},
Siphonology: {
level: 0,
locked: true,
max: 3,
priceBase: 100000,
heliumSpent: 0,
tooltip: "Use strategies discovered in alternate dimensions to siphon Map Bonus Damage stacks from lower level maps. For each level of Siphonology, you will earn stacks from maps one level lower than your current world. Maximum of 3 levels.",
},
Anticipation: {
level: 0,
locked: true,
max: 10,
modifier: 0.02,
priceBase: 1000,
heliumSpent: 0,
onChange: function () {
if (this.level <= 0) {
game.global.antiStacks = 0;
updateAntiStacks();
}
},
tooltip: "Use your experiences in understanding the attention span of Trimps to increase the damage dealt by all soldiers based on how long it took to get an army together. Increases damage by 2% per level per second up to 30 seconds. Maximum of 10 levels."
},
Resilience: {
level: 0,
locked: true,
modifier: 0.1,
priceBase: 100,
heliumSpent: 0,
tooltip: "Use your acquired skills in Trimp strengthening to gain a 10% <b>compounding</b> increase to total Trimp health."
},
Meditation: {
level: 0,
locked: true,
modifier: 1,
priceBase: 75,
heliumSpent: 0,
max: 7,
tooltip: "Your experiences in the Dimension of Strong Things have taught you the value of taking your time. Every level of Meditation will increase your Trimps' gather speed by 1% for every 10 minutes spent on the same zone, up to 1 hour, even when offline. This bonus is reset after clearing the current zone. Maximum of 7 levels.",
getBonusPercent: function (justStacks) {
var timeOnZone = new Date().getTime() - game.global.zoneStarted;
timeOnZone = Math.floor(timeOnZone / 600000);
if (timeOnZone > 6) timeOnZone = 6;
else if (timeOnZone <= 0) return 0;
if (justStacks) return timeOnZone;
return (timeOnZone * this.modifier * this.level);
}
},
Relentlessness:{
level: 0,
locked: true,
modifier: 0.05,
otherModifier: 0.3,
priceBase: 75,
heliumSpent: 0,
tooltip: "You've seen too many Trimps fall, it's time for more aggressive training. Bringing back these memories will cause your Trimps to gain a 5% chance to critically strike for 230% damage at level 1, and they will gain an additional 5% crit chance and 30% crit damage per level. Maximum of 10 levels.",
max: 10
},
Carpentry: {
level: 0,
locked: true,
modifier: 0.1,
priceBase: 25,
heliumSpent: 0,
tooltip: "You've built quite a few houses and you're getting pretty good at it. Bringing your expertise in construction back through the portal will allow you to house 10% more Trimps per level <b>than the current amount (compounds)</b>."
},
Artisanistry: {
level: 0,
locked: true,
modifier: 0.05,
priceBase: 15,
heliumSpent: 0,
tooltip: "You're beginning to notice ways to make equally powerful equipment with considerably fewer resources. Bringing back these new ideas will allow you to spend 5% fewer resources <b>than the current cost</b> per level on all equipment."
},
Range: {
level: 0,
locked: true,
modifier: 2,
max: 10,
priceBase: 1,
heliumSpent: 0,
tooltip: "Use your new-found leadership skills in order to increase the minimum damage your Trimps deal by 2% per level. Stacks up to 10 times, doesn't affect max damage. At 10 levels, you will get a minimum of 100% benefit from all attack damage per strike.",
},
Agility: {
level: 0,
modifier: 0.05,
priceBase: 4,
heliumSpent: 0,
tooltip: "Crank your portal into overdrive, requiring extra helium but increasing the clock speed of the Universe. Each level reduces the time between Trimp and Bad Guy attacks by 5% <b>of the current time (compounds)</b>. Maximum of 20 levels.",
max: 20
},
Bait: {
level: 0,
modifier: 1,
priceBase: 4,
heliumSpent: 0,
tooltip: "A few of these in your traps are sure to bring in extra Trimps. Each level allows traps to catch $modifier$ extra Trimp."
},
Trumps: {
//fiveTrimpMax worldUnlock
locked: 0,
level: 0,
modifier: 1,
priceBase: 3,
heliumSpent: 0,
tooltip: "Practicing aggressive strategizing allows you to earn $modifier$ extra max population from each battle territory bonus."
},
//breed main
Pheromones: {
level: 0,
modifier: 0.1,
priceBase: 3,
heliumSpent: 0,
tooltip: "Bring some pheromones with you to ensure that your Trimps will permanently breed 10% faster."
},
//trapThings main
Packrat: {
modifier: 0.2,
heliumSpent: 0,
tooltip: "Study the ancient, secret Trimp methods of hoarding. Each level increases the amount of stuff you can shove in each Barn, Shed, and Forge by 20%.",
priceBase: 3,
level: 0
},
//updatePs updates
//gather main
Motivation: {
modifier: 0.05,
heliumSpent: 0,
tooltip: "Practice public speaking with your trimps. Each level increases the amount of resources that workers produce by 5%.",
priceBase: 2,
level: 0
},
//startFight main
Power: {
level: 0,
modifier: 0.05,
priceBase: 1,
heliumSpent: 0,
tooltip: "Trimps learn through example. Spending some time bench pressing dead Elephimps should inspire any future Trimps to become stronger too. Adds 5% attack permanently to your Trimps."
},
//startFight main
Toughness: {
modifier: 0.05,
priceBase: 1,
heliumSpent: 0,
tooltip: "Pay your Trimps to knock you around a little bit. By learning to not be such a wuss, your Trimps will be less wussy as well. Adds 5% health permanently to your Trimps.",
level: 0
},
//rewardResources main
Looting: {
modifier: 0.05,
priceBase: 1,
heliumSpent: 0,
tooltip: "Walk back through the empty zones, learning how to milk them for every last drop. Each level permanently increases the amount of resources gained from battle by 5%.",
level: 0
},
},
challenges: {
Discipline: {
description: "Tweak the portal to bring you back to a universe where Trimps are less disciplined, in order to teach you how to be a better Trimp trainer. Your Trimps' minimum damage will be drastically lower, but their high end damage will be considerably higher. Completing The Dimension Of Anger will cause Trimp damage to return to normal.",
filter: function () {
return (game.resources.helium.owned >= 30 || game.global.totalHeliumEarned >= 30);
},
unlocks: "Range",
unlockString: "have 30 total helium"
},
Metal: {
description: "Tweak the portal to bring you to alternate reality, where the concept of Miners does not exist, to force yourself to become frugal with equipment crafting strategies. If you complete The Dimension Of Anger without disabling the challenge, miners will re-unlock.",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 24);
},
abandon: function () {
game.worldUnlocks.Miner.fire();
for (var x = 0; x < game.challenges.Metal.heldBooks; x++){
unlockUpgrade("Speedminer");
}
},
fireAbandon: false,
heldBooks: 0,
unlocks: "Artisanistry",
unlockString: "reach Zone 25"
},
Size: {
description: "Tweak the portal to bring you to an alternate reality, where Trimps are bigger and stronger, to force yourself to figure out a way to build larger housing. Your Trimps will gather 50% more resources, but your housing will fit 50% fewer Trimps. If you complete The Dimension of Anger without disabling the challenge, your stats will return to normal.",
completed: false,
filter: function () {
return (game.global.world >= 35 || game.global.highestLevelCleared >= 34);
},
abandon: function () {
game.jobs.Farmer.modifier *= (2/3);
game.jobs.Lumberjack.modifier *= (2/3);
game.jobs.Miner.modifier *= (2/3);
game.resources.trimps.maxMod = 1;
},
start: function () {
game.jobs.Farmer.modifier *= 1.5;
game.jobs.Lumberjack.modifier *= 1.5;
game.jobs.Miner.modifier *= 1.5;
game.resources.trimps.maxMod = 0.5;
},
fireAbandon: true,
unlocks: "Carpentry",
unlockString: "reach Zone 35"
},
Balance: {
description: "Your scientists have discovered a chaotic dimension filled with helium. All enemies have 100% more health, enemies in world deal 17% more damage, and enemies in maps deal 135% more damage. Starting at Zone 6, every time an enemy in the world is slain you will gain a stack of 'Unbalance'. Every time an enemy in a map is slain, you will lose a stack of Unbalance. Each stack of Unbalance reduces your health by 1%, but increases your Trimps' gathering speed by 1%. Unbalance can only stack to 250. Completing <b>Zone 40</b> with this challenge active will grant double helium earned for all Blimps slain and Void Maps cleared up to Zone 40. This challenge is repeatable!",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 39);
},
balanceStacks: 0,
addStack: function () {
this.balanceStacks++;
if (this.balanceStacks > 250) this.balanceStacks = 250;
else {
game.global.soldierHealthMax *= 0.99;
if (game.global.soldierHealth > game.global.soldierHealthMax) game.global.soldierHealth = game.global.soldierHealthMax;
}
},
removeStack: function () {
this.balanceStacks--;
if (this.balanceStacks < 0) this.balanceStacks = 0;
else {
game.global.soldierHealthMax *= 1.01;
}
},
abandon: function () {
this.balanceStacks = 0;
updateBalanceStacks();
},
getHealthMult: function (formatText) {
var num = Math.pow(0.99, this.balanceStacks);
if (formatText) return Math.floor((1 - num) * 100) + "%";
return num;
},
getGatherMult: function (formatText) {
if (formatText) return this.balanceStacks + "%";
return ((this.balanceStacks * 0.01) + 1);
},
heldHelium: 0,
heliumThrough: 40,
unlockString: "reach Zone 40"
},
Scientist: {
description: "Attempt modifying the portal to harvest resources when travelling. Until you perfect the technique, you will start with <b>_</b> science but will be unable to research or hire scientists. Choose your upgrades wisely! Clearing <b>'The Block' (11)</b> with this challenge active will cause you to * each time you use your portal.",
completed: false,
heldBooks: 0,
filter: function (fromCheck) {
if (game.global.sLevel == 0) return (game.global.highestLevelCleared >= 39);
else if (game.global.sLevel == 1) return (game.global.highestLevelCleared >= 49);
else if (game.global.sLevel == 2) {
if (game.global.highestLevelCleared > 69 && game.global.prisonClear) return (game.global.highestLevelCleared >= 89);
else return true;
}
else if (game.global.sLevel >= 3){
return (game.global.highestLevelCleared >= 109);
}
},
abandon: function () {
game.worldUnlocks.Scientist.fire();
document.getElementById("scienceCollectBtn").style.display = "block";
for (var x = 0; x < this.heldBooks; x++){
unlockUpgrade("Speedscience");
}
message("You can research science again!", "Notices");
if (game.global.sLevel == 4) document.getElementById("autoUpgradeBtn").style.display = "block";
},
start: function () {
document.getElementById("scienceCollectBtn").style.display = "none";
game.resources.science.owned = getScientistInfo(getScientistLevel());
},
onLoad: function () {
document.getElementById("scienceCollectBtn").style.display = "none";
},
fireAbandon: false,
unlockString: function () {
if (game.global.sLevel == 0) return "reach Zone 40";
else if (game.global.sLevel == 1) return "reach Zone 50";
else if (game.global.sLevel == 2) return "reach Zone 90";
else if (game.global.sLevel >= 3) return "reach Zone 110";
}
},
Meditate: {
description: "Visit a dimension where everything is stronger, in an attempt to learn how to better train your Trimps. All enemies will have +100% health and +50% attack, and your trimps will gather 25% faster. Completing <b>'Trimple of Doom' (33)</b> will return the world to normal.",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 44);
},
unlocks: "Meditation",
unlockString: "reach Zone 45"
},
Trimp: {
description: "Tweak the portal to bring you to a dimension where Trimps explode if more than 1 fights at a time. You will not be able to learn Coordination, but completing <b>'The Block' (11)</b> will teach you how to keep your Trimps alive for much longer.",
completed: false,
heldBooks: 0,
fireAbandon: true,
unlocks: "Resilience",
filter: function () {
return (game.global.world >= 60 || game.global.highestLevelCleared >= 59);
},
abandon: function () {
for (var x = 0; x < game.challenges.Trimp.heldBooks; x++){
unlockUpgrade("Coordination");
}
},
unlockString: "reach Zone 60"
},
Trapper: {
description: "Travel to a dimension where Trimps refuse to breed in captivity, teaching yourself new ways to take advantage of situations where breed rate is low. Clearing <b>'Trimple Of Doom' (33)</b> with this challenge active will return your breeding rate to normal.",
completed: false,
heldBooks: 0,
fireAbandon: true,
unlocks: "Anticipation",
filter: function () {
return (game.global.highestLevelCleared >= 69);
},
abandon: function () {
for (var x = 0; x < game.challenges.Trapper.heldBooks; x++){
unlockUpgrade("Potency");
}
},
unlockString: "reach Zone 70"
},
Electricity: {
description: "Use the keys you found in the Prison to bring your portal to an extremely dangerous dimension. In this dimension enemies will electrocute your Trimps, stacking a debuff with each attack that damages Trimps for 10% of total health per turn per stack, and reduces Trimp attack by 10% per stack. Clearing <b>'The Prison' (80)</b> will reward you with double helium for all Blimps and Improbabilities killed up to but not including Zone 80. This is repeatable!",
completed: false,
hasKey: false,
filter: function () {
return (game.global.prisonClear > 0);
},
fireAbandon: true,
abandon: function () {
game.global.radioStacks = 0;
updateRadioStacks();
},
heldHelium: 0,
heliumThrough: 79,
unlockString: "clear 'The Prison' at Zone 80"
},
Frugal: {
description: "Bring yourself to a dimension where Equipment is cheap but unable to be prestiged, in order to teach yourself better resource and equipment management. Completing <b>'Dimension of Anger' (20)</b> with this challenge active will return missing books to maps, and your new skills in Frugality will permanently cause MegaBooks to increase gather speed by 60% instead of 50%.",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 99);
},
start: function (reset) {
var mod = (reset) ? 1.2 : 1.1;
for (var item in game.equipment){
var cost = (item == "Shield") ? "wood" : "metal";
game.equipment[item].cost[cost][1] = mod;
}
},
onLoad: function () {
this.start();
},
fireAbandon: true,
abandon: function () {
this.start(true);
},
unlockString: "reach Zone 100"
},
Mapocalypse: {
description: "Experience a slightly distorted version of the 'Electricity' dimension, to help understand the relationship between maps and the world. Everything will work exactly the same as Electricity, but all maps will have an extra 300% difficulty. Clearing <b>'The Prison' (80)</b> will cause the world to return to normal. You <b>will</b> receive the Helium reward from Electricity.",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 114);
},
fireAbandon: true,
abandon: function () {
for (var x = 0; x < game.global.mapsOwnedArray.length; x++){
game.global.mapsOwnedArray[x].difficulty = parseFloat(game.global.mapsOwnedArray[x].difficulty) - this.difficultyIncrease;
}
},
unlocks: "Siphonology",
unlockString: "reach Zone 115",
difficultyIncrease: 3
},
Coordinate: {
description: "Visit a dimension where Bad Guys are Coordinated but never fast, to allow you to study naturally evolved Coordination. Completing <b>'Dimension of Anger' (20)</b> with this challenge active will cause all enemies to lose their Coordination.",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 119);
},
unlocks: "Coordinated",
unlockString: "reach Zone 120"
},
Crushed: {
description: "Journey to a dimension where the atmosphere is rich in helium, but Bad Guys have a 50% chance to Critical Strike for +400% damage unless your Block is as high as your current Health. Clearing <b>Bionic Wonderland (Z125)</b> will reward you with double helium earned up to but not including Z125. This challenge is repeatable.",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 124);
},
fireAbandon: true,
abandon: function () {
document.getElementById("badCrit").innerHTML = "";
document.getElementById("badCanCrit").style.display = "none";
},
heldHelium: 0,
heliumThrough: 124,
unlockString: "reach Zone 125"
},
Slow: {
description: "Legends tell of a dimension inhabited by incredibly fast bad guys, where blueprints exist for a powerful yet long forgotten weapon and piece of armor. All bad guys will attack first in this dimension, but clearing <b>Zone 120</b> with this challenge active will forever-after allow you to create these new pieces of equipment.",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 129);
},
unlockString: "reach Zone 130"
},
Nom: {
description: "Travel to a dimension where bad guys enjoy the taste of Trimp. Whenever a group of Trimps dies, the bad guy will eat them, gaining 25% (compounding) more attack damage and healing for 5% of their maximum health. The methane-rich atmosphere causes your Trimps to lose 5% of their total health after each attack, but the bad guys are too big and slow to attack first. Clearing <b>Zone 145</b> will reward you with triple helium for all Blimps and Improbabilities killed. This is repeatable!",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 144);
},
heldHelium: 0,
heliumThrough: 145,
unlockString: "reach Zone 145"
},
Mapology: {
description: "Travel to a dimension where maps are scarce, in an attempt to learn to be more resourceful. You will earn one map Credit for each World Zone you clear, and it costs 1 credit to run 1 map. Completing <b>Zone 100</b> with this challenge active will return you to your original dimension. Double prestige from Scientist IV will not work during this challenge.",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 149);
},
fireAbandon: true,
abandon: function (){
document.getElementById("mapCreditsLeft").innerHTML = "";
},
onLoad: function () {
updateMapCredits();
},
unlocks: "Resourceful",
credits: 0,
unlockString: "reach Zone 150"
},
Toxicity: {
description: "Travel to a dimension rich in helium, but also rich in toxic bad guys. All bad guys have 5x attack and 2x health. Each time you attack a bad guy, your Trimps lose 5% of their health, and toxins are released into the air which reduce the breeding speed of your Trimps by 0.3% (of the current amount), but also increase all loot found by 0.15%, stacking up to 1500 times. These stacks will reset when you clear a zone. Completing <b>Zone 165</b> with this challenge active will reward you with triple helium for all Blimps and Improbabilities killed. This is repeatable!",
completed: false,
filter: function () {
return (game.global.highestLevelCleared >= 164);
},
heldHelium: 0,
heliumThrough: 165,
stacks: 0,
maxStacks: 1500,
stackMult: 0.997,
lootMult: 0.15,
unlockString: "reach Zone 165"
},
Devastation: {
description: "Travel to a harsh dimension where Trimps are penalized for the mistakes of previous generations. If your army is killed at any point, any overkill damage will be applied 750% to the next group of Trimps to fight. Completing <b>Imploding Star (Zone 170)</b> will return the world to normal.",