-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathindex.html
More file actions
14768 lines (13391 loc) · 818 KB
/
index.html
File metadata and controls
14768 lines (13391 loc) · 818 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
<html>
<meta charset="UTF-8"/>
<head><title>Proto23</title>
<style>
html body{font: 1.1em MS Gothic;}
input:focus{outline: none;}
.d{text-align:center;background-color:rgb(0,40,64);color:white;position:absolute}
.dd{text-align:center;width:25%}.dd:hover{background-color:rgb(105,105,199)}
.ddd_1{text-align:center;width:50%;border:solid 2px rgb(12,86,195);height:100%;border-bottom:none;padding-top:3;height:initial;}
.ddd_2{display:flex;height:20%}
.bts{text-align:center;width:20%}
.bts_b{border-top:solid 1px grey;border-right:solid 1px grey;position:relative;top:7px}
.bts_m{border-top:solid 1px grey;border-right:solid 1px grey;position:relative;top:7px;height:18px}
.atrkmove2:hover,.atrkmove:hover,.opt_c:hover,.ct_bts:hover,.chs:hover,.bts:hover,.bbts:hover,.bts_b:hover,.inv_slot:hover,.bts_m:hover,.crf_c_bts:hover{background:linear-gradient(90deg,rgb(25,129,108),rgb(1,41,39))}
.crf_lg{font-size:.9em;background-color:rgb(46,41,169);border-bottom: 1px cornflowerblue solid; padding-top:2;padding-bottom:2;text-align: center;}
.crf_lg:hover{background-color:rgb(46,81,159)}
.inv_slot{border-bottom:1px #44c solid;margin-left:-3px}
.del_b{position:absolute;right:26px;width:16px;text-align:center;margin-top:-19px}
.dss_b{position:absolute;right:42px;width:16px;text-align:center;margin-top:-19px}
.eq_r{position:absolute;right:44px;width:16px;text-align:center;margin-top:-19px;padding-top:3px;color:#f80;background-color:royalblue}
.eq_l{position:absolute;right:72px;width:16px;text-align:center;margin-top:-19px;padding-top:3px;color:#f80;background-color:royalblue}
.eq_r:hover,.eq_l:hover{border: solid 1px lime; width: 14px;height: 13px;padding-top: 2;padding-bottom: 2;}
.spc_a{position:absolute;right:9px;width:16px;text-align:center;color:black;background-color:#f80;padding-top:3px}
.del_b:hover{background-color:red;}
.dss_b:hover{background-color:lightgrey;color:grey}
.s_am{position:absolute;left:260px}
.shn{position:absolute;color:yellow;text-shadow:gold 0px 0px 5px}
.msg{border-bottom:1px solid rgb(110,110,140);text-align:center;width:100%;background-color:rgb(36,21,59);padding-top:2px;font-size:.9em}
.msg:hover{background-color:#282756;}
.noselect{-moz-users-select:-moz-none;-khtml-user-select:none;-webkit-user-select:none;user-select:none;cursor:default}
.doselect{-moz-users-select:;-khtml-user-select:;-webkit-user-select:;user-select:;cursor:}
.bts_m_b{margin-top:-1px;width:18px;height:18px;background-color:rgba(0,0,50,.3);text-align:center;border:darkgrey 1px
dashed;border-bottom:none;position:absolute;color:red;}
.se_ia{width:18px;height:18px;border:solid black 1px}
.se_ia:hover{border:1px lime solid}
.ct_bts{width:20%;border:orchid 1px solid;padding-top:1px;border-bottom:none;font-size:.9em}
.bbts{color:cadetblue;}
.opt_c{padding-bottom:2px;display:flex;border-bottom: 1px solid lightslategray;background-color:rgb(10,30,54)}
.opt_t{padding-left:4px}
.opt_v{border:none; border-left: 1px solid lightslategray; padding-right:4px;position:absolute;left:50%; background-color: transparent;font: 1.1em MS Gothic;padding-left:4px; color: inherit}
.opt_ta{padding-left:4px}
.opt_va{border:none; border-left: 1px solid lightslategray; padding-right:4px;position:absolute;left:50%; background-color: transparent;;padding-left:4px; color: inherit}
.skwmmc{border: 1px solid #46a;border-bottom:none;background-color: #081040;padding: 2px;display:flex}
.skwmmc:hover,#qtrtn:hover,.opt_ta:hover,.opt_va:hover{background-color: #154080;}
.rgt_ics{width:50%;text-align:left;border-bottom:1px solid #3e4092;padding-top:2px;padding-bottom:2px;border-right:1px solid #3e4092;overflow-wrap: break-word;}
.chs{width:100%;height:22px;border-bottom:solid 1px #3848c0;background-color:rgb(0,44,87);padding-top:8}
.chs_s{height:15px;border-bottom:solid 1px #3848c0;padding-top:5;text-align:left;font-size:.85em;padding-left:5px;background-color:#111935}
.sl{border: solid 1px;text-align:center; width:40px;padding:3px;font-size:.7em} .sl:hover{background-color:#abc}
#sl{bottom:0px;left:0px;position:fixed;background-color:#dededd;width:100%;padding:5px;opacity:0.7}
#chs{width:100%;height:60px;border-bottom:solid 1px #3848c0;background-color:rgb(0,20,44);height:auto;padding-top:12px;padding-bottom:12px}
#d1{width:430px;height:310px;padding:5px;border: black solid 3px}
.d2,.d3,.d3m{background:linear-gradient(90deg,rgb(25,129,108),rgb(1,41,39))}
#toh:hover,.rgt_ics:hover{background-color:#327}
.d3:hover{background:linear-gradient(90deg,rgb(2,51,52),rgb(24,62,91))}
#d4{display:flex;background-color:#558}
#d_t{padding-top:5;}
#d_l{padding-bottom:5;border-bottom:solid 1px darkgrey;}
#dr_l{position:absolute; bottom:0px;right:66px;padding-bottom:5;width:30%}
#dp_m{display:inline;position:absolute;height:6px;margin-top:3px;}
#ainfo{position:absolute;bottom:5px;background:linear-gradient(270deg,rgb(84,28,112),rgb(29,62,116));width:97.5%;left:5px;text-align:left}
#bbts{display:flex;position:absolute;bottom:20px;left:5px;text-align:left;background:linear-gradient(rgb(0,40,64),rgb(0,50,94));width:97.5%}
#se_i{position:absolute;bottom:5px;width:100%;display:flex;max-width:420px}
#chbts{width:100%;display:flex;border-bottom:#249 solid 2px;text-align:center;}
.chbtsa{width:20%;text-align:center;background-color:rgb(33,55,74); border:1px #57b solid ;color:rgb(188,254,254);border-bottom:none}
.chbtsa:hover{background-color:rgb(53,85,99)}
.hp{text-shadow:black 1px 1px 0px,black 1px 0px 0px;background:linear-gradient(90deg,rgb(254,239,157),rgb(45,223,206));width:100%}
#hpp,#expp,#enn{width:415px}
.exp{text-shadow:black 1px 1px 0px,black 1px 0pzx 0px;background:linear-gradient(90deg,rgb(254,239,157),rgb(219,119,158));width:100%}
#nch{position:absolute;left:20%;font:1.1em MS Gothic;border:none;background-color:transparent;width:auto;color:white;top:4px}
#mn{position:absolute;right:13px;bottom:-7px;display:flex;width:200px;}
#mnb{width:25%;}
.en{background:linear-gradient(270deg,rgb(124,68,112),rgb(29,29,113)); width:100%}
.bst_entr{display:flex;border-bottom:1px solid #9485ed} #bst_entrh:hover{background-color:rgb(20,50,84)!important}
.bst_entr1{width:68%;left:5px;position:relative}
.bst_entr2{width:12%;position:relative;border-left:1px solid #9485ed;text-align:center}
.bst_entr3{width:20%;position:relative;border-left:1px solid #9485ed;text-align:center}
#dscr{position:absolute;border:solid 5px lightgrey;outline:solid 3px black;background:linear-gradient(90deg,#333,#111);width:320px;height:auto; text-align:center; box-shadow: 8px 8px rgba(220,20,60,.8);font: .9em MS Gothic; color:white; padding:6px;z-index:99999}
#ctrmg{left:347px;color:rgb(188,254,254);width:550px;height:430px;border:solid 3px black;background:linear-gradient(90deg,rgb(0,5,51),rgb(0,65,107));position:absolute;top:337px}
#ctrm_1{border-bottom:3px dotted #2357ec;position:absolute;background:linear-gradient(270deg,rgb(36,37,62),rgb(11,32,80));height:50px;width:100%;}
#ctrm_2{position:relative;text-align:center;top:53px}
#ctr_w{position:absolute;right:4px;top:4px;font-size:1.1em;}
#ctr_t{position:absolute;right:4px;top:25px;font-size:1.17em;text-shadow:-1px 0px 5px #328aa4}
#ctr_l{position:absolute;left:4px;top:4px;font-size:1em;}
#crf_c{display:flex;width:100%;height:360px;line-height:16px}
#crf_l{width:45%;height:100%;overflow:auto}
#crf_r{width:55%;height:100%;background-color:rgb(36,21,59);border-left:1px cornflowerblue solid}
#ct_ctrl{position:absolute;display:flex;bottom:0px;width:100%;text-align:center;background-color:rgb(15,25,60);}
#gmsgs{background:linear-gradient(180deg,rgb(60,50,90),rgb(24,16,49));position:absolute;left:906px;padding:6px;color:rgb(188,254,254);border:3px black solid;width:361px;height:747px;resize:both;}
#mscont{height:94%;overflow:auto;margin-right:-6;margin-left:-6;}
#m_control{position:absolute;display:flex;width:100%;bottom:7px;height: 25px;margin:-6px}
#inv{color:rgb(188,254,254);width:330px;height:430px;border:solid 3px
black;background:linear-gradient(90deg,rgb(0,5,51),rgb(0,65,107));position:absolute;overflow:auto;resize:vertical;top:337px}
#inv_control{display:flex;border-bottom:solid 2px grey}
#inv_control_b{position:absolute;display:flex;width:100%;background:linear-gradient(90deg,rgb(0,5,51),rgb(0,65,107));bottom:7px}
#inv_con{overflow:auto;height:86%;position:relative}
#eq_w{background-color:rgb(22,52,104);width:100%;height:125}
.crf_c_bts{border-right:1px solid cornflowerblue;width:100%;text-align:center}
.noout{outline:none}
.dseparator{border-bottom: 1px solid grey;width:100%;height:8px;margin-bottom:10px}
.trkitm{display:flex;border-bottom:1px #44c solid;position:relative}
.atrkmove{position:absolute;right:0;border-left:1px #44c solid;width:19;height:16;display:block;text-align:center}
.atrkmove2{position:absolute;left:0;border-right:1px #44c solid;width:19;height:16;display:block;text-align:center}
#youttlc{position:absolute;width:300px;color:ghostwhite;top:50px;left:81px;background-color:rgb(10,30,54);border:3px solid #000;text-align:center;}
#youttlh{background-color:rgb(40,60,84);padding-top:2;border-bottom:1px dotted #500}
.youttl{border-top:1px dashed #500;padding-top:2px;padding-bottom:2px}
.youttl:hover{background-color:#6f2727}
.ctrwinbx{position:relative;top:53px}
.ch_entbb{border-left:1px #9485ed solid;width:20;height:18}
.ch_entbb:hover{background-color:rgb(10,30,54)}
.sttc{display:flex;border-bottom:1px solid #44c;width:100%;}
.sttl{width:55%;border-right:1px solid #44c;text-align:left;padding-left:3}
.sttr{width:45%;text-align:center}
.sttc:hover{background:rgb(20,50,84)}
.jcell{height:100%;width:50%;border:2px dotted #4075b7;background-color:#131261;text-align:center;line-height:50px}
.jcell:hover{border:2px dotted #142f52} .jrow{display:flex;height:50%}
#jcell1:hover{background-color:#0d7680;} #jcell2:hover{background-color:#862a0e;}
#jcell3:hover{background-color:#1d8651;} #jcell4:hover{background-color:#6f2a63;}
.bksstt{position:absolute;border:solid lime 1px;width:350px;overflow:auto;background-color:#210445;left:445px;top:370px;max-height:350px}
.blssttc{border-bottom:thistle 1px solid;text-align:center;line-height:22px}
#qtrtn{background-color:#12152f;position:absolute;bottom:0px;width:100%;line-height:25px;height:25px;border-top: 1px solid #3b3158}
#rptbn{position:absolute;right:0;top:0;border:1px solid #3e4092;height:15;width:15;text-align:center;color:lime}
#rptbn:hover{background-color:lightgrey}
img,canvas{image-rendering:pixelated}
::-webkit-scrollbar{width: 8px;height:10px}
::-webkit-scrollbar-track{background:transparent}
::-webkit-scrollbar-thumb {background: #5fc3ff}
body{scrollbar-color:#5fc3ff;scrollbar-width:thin}
@supports (-moz-appearance:none) {html{line-height:18px}#mscont{line-height:16px}.eq_r{padding-top:0px}.eq_l{padding-top:0px}.spc_a{padding-top:0px0}.sttc{line-height:15px}
.opt_v{font: .9em MS Gothic;height:20px}
.trkitm{line-height:15px}
#d_t{line-height:16px}
#d_l,#intfffx{line-height:13px}
.spc_a{padding-top:0px}
} //gmsgs rgb(40,30,70)
//crf_r linear-gradient(0deg,rgb(32,7,41),rgb(36,21,68))
</style>
<link rel="shortcut icon" href="favicon.ico" type="image/x-icon">
</head>
<body class='noselect'>
<script > //#080521
var dom = new Object();
var global = new Object(); var listen = new Object();
var w_manager = new Object();
var creature = new Object();
var offline = new Object();
var effect = new Object();
var wpn = new Object(); var eqp = new Object(); var acc = new Object(); var sld = new Object(); var item = new Object(); var itemgroup=[item,wpn,eqp,sld,acc];
var rcp = new Object();
var area = new Object();
var timers = new Object();
var chss = new Object();
var ttl = new Object();
var skl = new Object();
var abl = new Object();
var furniture = new Object();
var vendor = new Object();
var quest = new Object();
var act = new Object();
var test = new Object();
var callback = new Object();
var effector = new Object();
var planner = new Object(); plans=[[],[],[]];
var sector = new Object(); var sectors=[];
var check = new Object(); var checksd=[];
var inv=[]; var furn=[]; var qsts=[]; var dar=[[],[],[],[],[]]; you = new Object(); var home = new Object(); eqp.dummy = {};
var container = new Object();
var mastery = new Object();
const YEAR = 518400; const MONTH = 43200; const DAY = 1440; const WEEK = 10080; const HOUR = 60;
const SILVER = 100; const GOLD = 10000; let tempt = new Date();
global.home_loc=111; global.lst_sve='?'; global.ver=470;
global.sm=1; global.rm=0; global.bg_g=global.bg_r=global.bg_b=255;
global.s_l=0; global.spnew=0; global.vsnew=10; global.uid=1; global.wdwidx=0; global.menuo=0; global.lastmsgc=0
global.sinv=[]; global.srcp=[]; global.drdata={};
global.lw_op=0; global.zone_a_p=[];
global.rec_d=[]; global.e_e=[]; global.e_em=[]; global.titles=[]; global.titlese=[]; var acts=[]; global.tstcr=[];
global.atkdftm=[-1,-1,-1]; global.atkdfty=[-1,-1]; global.atkdftydt={};
global.current_m; global.current_z; global.current_l; global.stat={tick:0,akills:0,fooda:0,foodb:0,foodal:0,foodt:0,ftried:0,moneyg:0,die_p:0,die_p_t:0,ivtntdj:0,athme:0,athmec:0,slvs:0,lgtstk:0,moneysp:0,shppnt:0,exptotl:0,seed1:(Math.random()*7e+7<<7)%7&7,igtttl:0,msts:[[0,0],[0,0],[0,0],[0,0],[0,0],[0,0],[0,0],[0,0]],msks:[0,0,0,0,0,0,0],sttime:tempt.getFullYear()+'/'+(tempt.getMonth()+1)+'/'+tempt.getDate()+' '+tempt.getHours()+':'+(tempt.getMinutes()>=10?tempt.getMinutes():'0'+tempt.getMinutes())+':'+(tempt.getSeconds()>10?tempt.getSeconds():'0'+tempt.getSeconds()),buyt:0,rdttl:0,dsst:0,thrt:0,crftt:0,deadt:0,smovet:0,timeslp:0,misst:0,dodgt:0,potnst:0,medst:0,plst:0,jcom:0,qstc:0,popt:0,dsct:0,bloodt:0,rdgtttl:0,cat_c:0,dmgdt:0,dmgrt:0,onesht:0,pts:0,gsvs:0,hbhbsld:0,wsnburst:50,wsnrest:50,indkill:0,coldnt:0,lastver:global.ver};
global.hit_a=0;global.hit_b=0;global.timescale=1; global.keytarget; global.offline_evil_index=1;
global.flags={btl:false,m_freeze:false,msd:false,m_blh:false,crti:false,to_pause:false,civil:true,sleepmode:false,loadstate:false,eshake:false,msgtm:false,
grd_s:true,inside:true,israin:false,issnow:false,iscold:false,bstu:false,blken:false,rtcrutch:false,savestate:false,expatv:false,gameone:false,
tmmode:1,ssngaijin:true,rptbncgt:false};
global.spirits=100;global.bestiary=[{a:false}]; global.shortcuts=[];
global.msgs_max = 36; global.text=new Object(); global.text.nt=['K','M','B','T','Qa','Qi','Sx','Sp','Oc','No','De','Un','DDe','TDe','QaDe','QiDe','Lc'];
global.fps = 1;global.text.wecs=[['grey','inherit'],['white','inherit'],['cyan','cyan'],['lime','green'],['yellow','red'],['orange','orange'],['purple','white']];
global.text.lunarp=[['🌑','New Moon'],['🌒','Waxing Crescent Moon'],['🌓','First Quarter Moon'],
['🌔','Waxing Gibbous Moon'],['🌕','Full Moon'],['🌖','Waning Gibbous Moon'],
['🌗','Last Quarter Moon'],['🌘','Waning Crescent Moon']];
global.text.eranks=['???','--G','-G','G','G+','-F','F','F+','-E','E','E+','-D','D','D+','-C','C','C+','-B','B','B+','--A','-A','A','A+','A++','--S','-S','S','S+','S++','--SS','-SS','SS','SS+','SS++','--SSS','-SSS','SSS','SSS+','SSS++'];
dom.dseparator='<div class="dseparator"> </div>';
dom.coincopper='<small style="color:rgb(255, 116, 63)">●</small>';
dom.coinsilver='<small style="color:rgb(192, 192, 192)">●</small>';
dom.coingold='<small style="color:rgb(255, 215, 0)">●</small>';
window.addEventListener('load',()=>{load()});
function save(lvr){
let storage = window.localStorage; global.flags.savestate=true; global.stat.gsvs++;
let str = "";
let a = new Date(); global.lst_sve=a.getFullYear()+'/'+(a.getMonth()+1)+'/'+a.getDate()+' '+a.getHours()+':'+(a.getMinutes()>=10?a.getMinutes():'0'+a.getMinutes())+':'+(a.getSeconds()>=10?a.getSeconds():'0'+a.getSeconds());
dom.sl_extra.innerHTML='Last save: '+global.lst_sve;
let o=[];for(let obj in you.eqp){o[obj]=you.eqp[obj];unequip(you.eqp[obj],{save:true});} you.stat_r(); let freezete = global.flags.m_freeze;
if(inSector(sector.home)){for(let a in furn)deactivatef(furn[a])}
global.flags.m_freeze=true; for(let a in you.eff)if(you.eff[a].type===5)you.eff[a].onRemove();
let yu = {name:you.name,title:you.title.id,lvl:you.lvl,exp:you.exp,exp_t:you.exp_t,sat:you.sat,satmax:you.satmax,sat_r:you.sat_r,hp:you.hp,
hpmax:you.hpmax,hp_r:you.hp_r,str:you.str,str_r:you.str_r,agl:you.agl,agl_r:you.agl_r,int:you.int,int_r:you.int_r,spd:you.spd,
spd_r:you.spd_r,luck:you.luck,stat_p:you.stat_p,wealth:you.wealth,crt:you.crt,res:you.res,mods:you.mods,stra:you.stra,strm:you.strm,inta:you.inta,
intm:you.intm,agla:you.agla,aglm:you.agml,spda:you.spda,spdm:you.spdm,hpa:you.hpa,hpm:you.hpm,sata:you.sata,satm:you.satm,cls:you.cls,ccls:you.ccls,
aff:you.aff,maff:you.maff,caff:you.caff,cmaff:you.cmaff,karma:you.karma,ki:you.ki}
global.flags.m_freeze=true;global.current_a.deactivate();dom.ct_bt3.style.backgroundColor='inherit';
for(let a in you.eff)if(you.eff[a].type===5)you.eff[a].onGive();
str += JSON.stringify(yu); str +='|';
let a4 = []; for(let obj in you.eff) if(!!you.eff[obj].id) {var pw;!!you.eff[obj].power?pw=you.eff[obj].power:pw=1;a4[obj]={a:you.eff[obj].id,b:you.eff[obj].duration,c:pw}}; global.flags.m_freeze=false;
str += JSON.stringify(a4); str +='|';
let a6 = []; for(let obj in you.skls) {a6[obj]={id:you.skls[obj].id,lvl:you.skls[obj].lvl,mst:[]}; for(let m in you.skls[obj].mlstn) a6[obj].mst[m]=you.skls[obj].mlstn[m].g};
str += JSON.stringify(a6); str +='|';
let a7 = []; for(let obj in skl) a7.push([skl[obj].exp,skl[obj].p]);
str += JSON.stringify(a7); str +='|';
var datasi=[]; let nindxdt=0;for(let obj in item) if(item[obj].data.tried===true) datasi[nindxdt++]=item[obj].id;
var datare=[]; let nindxat=0;for(let obj in item) if(item[obj].data.finished===true) datare[nindxat++]=item[obj].id;
let a1 = {uid:global.uid,jj:global.stat,x:global.current_z.id,a:global.rm,b:global.sm,e:global.flags,f:global.spirits,
g:global.msgs_max,i:global.lst_loc,j:time.minute,k:w_manager.duration,l:w_manager.curr.id,m:global.lst_sve,n:global.bg_r,o:global.bg_g,p:global.bg_b,q:global.bestiary,r:global.timehold,r2:global.timewold,datas:datasi,u:global.timescale,datar:datare,z:global.offline_evil_index,drdata:global.drdata};
str += JSON.stringify(a1); str +='|';
let a2=[]; for (let obj in global.rec_d) a2[obj]={id:global.rec_d[obj].id,data:global.rec_d[obj].data}
str += JSON.stringify(a2); str +='|';
let a3=[[],[],[],[],[],[]]; for (let obj in o) equip(o[obj],{save:true}); you.stat_r()
for (let obj in inv) {
let expectedIndex = Math.max(0, Math.min(4, Math.floor(inv[obj].id / 10000)));
if (expectedIndex === 0) {
a3[0].push({id:inv[obj].id,am:inv[obj].amount,data:inv[obj].data});
} else {
a3[expectedIndex].push({id:inv[obj].id,dp:inv[obj].dp,toeq:true,data:inv[obj].data}); if(!scanbyuid(you.eqp,inv[obj].data.uid)) a3[expectedIndex][a3[expectedIndex].length-1].toeq=false}
}
for(let a in item) if(item[a].save===true) a3[5].push({item:item[a].id,data:item[a].data});
str += JSON.stringify(a3); str +='|';
let a5=[]; let xx=0;for (let o in area) a5[xx++]=area[o].size;
str += JSON.stringify(a5); str +='|';
let a8=dar;
str += JSON.stringify(a8); str +='|';
let a9=[]; for(let obj in furn) a9.push({id:furn[obj].id,data:furn[obj].data});
str += JSON.stringify(a9); str +='|';
let a10 = {};let a11={}; for (let obj in vendor){
let stock = []; for(let i=0;i<vendor[obj].stock.length;i++) {stock[i]=[];stock[i][0]=vendor[obj].stock[i][0].id;stock[i][1]=vendor[obj].stock[i][1];stock[i][2]=vendor[obj].stock[i][2]}
a10[obj]={stock:stock,data:vendor[obj].data};
}
str += JSON.stringify(a10); str +='|';
let a12 = []; for(let a in global.titles) a12.push(global.titles[a].id); //for(let obj in ttl) if(ttl[obj].have===true) a12.push(ttl[obj].id);
str += JSON.stringify(a12); str +='|';
let a13 = new Object();
for(let s in home) a13[s]=home[s].id;
str += JSON.stringify(a13); str +='|';
let a14 = []; for(let obj in qsts) a14.push({id:qsts[obj].id,data:qsts[obj].data});
str += JSON.stringify(a14); str +='|';
let a15 = []; for(let obj in acts) a15.push({id:acts[obj].id,data:acts[obj].data});
str += JSON.stringify(a15); str +='|';
let a17 = []; for(let obj in sector) a17.push({id:sector[obj].id,data:sector[obj].data});
str += JSON.stringify(a17); str +='|';
let a18 = []; for(let obj in container){ let cont = [];
for(let a in container[obj].c) cont.push({id:container[obj].c[a].item.id,data:container[obj].c[a].data,am:container[obj].c[a].am,dp:container[obj].c[a].dp})
a18.push({id:container[obj].id,c:cont});
}
str += JSON.stringify(a18); str +='|';
let a19 = []; for(let obj in chss) if(JSON.stringify(chss[obj].data)!=='{}') a19.push({id:chss[obj].id,data:chss[obj].data});
str += JSON.stringify(a19); str +='|savevalid|';
let a20 = []; for(let a in ttl) if(ttl[a].tget) a20.push(ttl[a].id)
str += JSON.stringify(a20);
if(inSector(sector.home)){for(let a in furn)activatef(furn[a])}
global.flags.m_freeze=true; global.current_a.activate(); global.flags.m_freeze=freezete;
if(global.flags.busy===true) dom.ct_bt3.style.backgroundColor='darkslategray'
str = utf8_to_b64(str);
storage.setItem("v0.3", str); global.flags.savestate=false;
if(!lvr) msg('Game Saved','cyan');
return str
}
dom.loading = addElement(document.body,'div'); dom.loading.style.zIndex=9997;
dom.loading.style.width='100%'; dom.loading.style.height='100%'; dom.loading.style.position='absolute';
dom.loading.style.backgroundColor='lightgrey'; dom.loading.style.margin=-8;
dom.loadingt = addElement(document.body,'div'); dom.loadingt.style.zIndex=9998;
dom.loadingt.innerHTML='LOADING'; dom.loadingt.style.textAlign='center'; dom.loadingt.style.top=window.innerHeight/2-50;
dom.loadingt.style.fontSize='4em'; dom.loadingt.style.position='absolute'; dom.loadingt.style.left=window.innerWidth/2-150;
function load(dt){
var str = dt||window.localStorage.getItem("v0.3");
str = b64_to_utf8(str);
if(str&&str!=''){
dom.error = addElement(document.body,'div');
dom.error.style.width='100%'; dom.error.style.height='auto'; dom.error.style.position='absolute';
dom.error.style.fontSize='2em';dom.error.style.color='red'; dom.error.style.zIndex=9999; dom.error.style.lineHeight='normal';
dom.error.style.opacity=0; setTimeout(function(){appear(dom.error)},500)
dom.error.style.textAlign='center'; dom.error.innerHTML='SOMETHING BROKE<br>PERHAPS DUE TO STUPIDITY OR DATA STRUCTURE CHANGES<br>⋗1 DELETING THE SAVE IS ADVISED<br>⋗2 OR WAITING FOR SOME TIME TIL FIXED<br>⋗3 OR CHECKING IN DIFFERENT BROWSER, MIGHT WORK THERE(MEANS THE SAVE IS BORKED(REFER TO 1))';
clearInterval(timers.mnch);clearInterval(timers.snch); clearInterval(timers.autos); clearInterval(timers.rdng);clearInterval(timers.rdngdots); global.menuo=0; clearInterval(timers.actm); clearInterval(timers.job1t); clearInterval(timers.bstmonupdate); clearInterval(timers.rptbncgt); global.flags.rptbncgtf=false; global.flags.rptbncgt=false;
str = str.split('|');
let yu_s = JSON.parse(str[0]);
for(let a in ttl) {ttl[a].have=false; ttl[a].tget=false}; global.titles=[];
you.name = yu_s.name; for(let o in ttl) if(ttl[o].id===yu_s.title) you.title=ttl[o];you.lvl = yu_s.lvl;
you.exp= yu_s.exp;you.exp_t= yu_s.exp_t; you.expnext_t=you.expnext();
you.sat= yu_s.sat;you.satmax= yu_s.satmax;you.sat_r=yu_s.sat_r; you.sata=yu_s.sata||0; you.satm=yu_s.satm||1; you.ki=yu_s.ki||new Object();
you.hp= yu_s.hp;you.hpmax= yu_s.hpmax;you.hp_r=yu_s.hp_r;you.hpa=yu_s.hpa||0; you.hpm=yu_s.hpm||1; you.hp=you.hp>you.hpmax?you.hpmax:you.hp;
you.str= yu_s.str;you.str_r=yu_s.str_r; you.stra=yu_s.stra||0; you.strm=yu_s.strm||1;
you.agl= yu_s.agl;you.agl_r=yu_s.agl_r; you.agla=yu_s.agla||0; you.aglm=yu_s.aglm||1;
you.int= yu_s.int;you.int_r=yu_s.int_r; you.inta=yu_s.inta||0; you.intm=yu_s.intm||1;
you.spd= yu_s.spd;you.spd_r=yu_s.spd_r; you.spda=yu_s.spda||0; you.spdm=yu_s.spdm||1;
you.cls=yu_s.cls||[0,0,0]; you.ccls=yu_s.ccls||[0,0,0]
you.aff=yu_s.aff||[0,0,0,0,0,0,0];you.maff=yu_s.maff||[0,0,0,0,0,0,0];
you.caff=yu_s.caff||[0,0,0,0,0,0,0];you.cmaff=yu_s.cmaff||[0,0,0,0,0,0,0];
you.luck= yu_s.luck; you.stat_p= yu_s.stat_p; you.karma=yu_s.karma||0;
you.wealth= yu_s.wealth;you.crt= yu_s.crt; global.flags.loadstate=true;
for(let a in callback) for(let b in callback[a].hooks) if(callback[a].hooks[b].data.q) callback[a].hooks.splice(callback[a].hooks[b],1)
for (let obj in item) {item[obj].amount=0;item[obj].have=false} inv=[];
for (let g in yu_s.res) you.res[g] = yu_s.res[g]; for(let g in yu_s.mods) you.mods[g]=yu_s.mods[g];
you.eqp = [eqp.dummy,eqp.dummy,eqp.dummy,eqp.dummy,eqp.dummy,eqp.dummy,eqp.dummy,eqp.dummy,eqp.dummy,eqp.dummy];
for(let a in you.eff)you.eff[a].active=false; you.eff=[]; empty(dom.d101); global.e_e=[]; global.e_em=[]; empty(dom.d101m); global.current_m.eff=[];
let a4 = JSON.parse(str[1]); global.msgs_max=300;empty(dom.mscont); global.rec_d=[]; for(let ba in rcp){rcp[ba].have=false}; global.flags.loadstate=false;
let a6 = JSON.parse(str[2]); you.skls=[]; for(let ab in skl){skl[ab].lvl=0;skl[ab].exp=0;}
for(let a in global.rec_d) global.rec_d[a].have=false; global.rec_d=[];
for(let i in skl) for(let ii in skl[i].mlstn) skl[i].mlstn[ii].g=false;
for(let a in a6) for(let b in skl) if(a6[a].id===skl[b].id){
you.skls.push(skl[b]);skl[b].lvl=a6[a].lvl;
for(let c in a6[a].mst) skl[b].mlstn[c].g=a6[a].mst[c];
if(skl[b].mlstn) for(let d in skl[b].mlstn) if(skl[b].mlstn[d].g===false&&skl[b].mlstn[d].lv<=skl[b].lvl) {;skl[b].mlstn[d].f();skl[b].mlstn[d].g=true;msg("NEW PERK UNLOCKED "+'<span style="color:tomato">("'+skl[b].name+'")<span style="color:orange">lvl: '+skl[b].mlstn[d].lv+'</span></span>','lime',{x:skl[b].name,y:'Perk lvl '+skl[b].mlstn[d].lv+': <span style="color:yellow">'+skl[b].mlstn[d].p+'</span>'},7);}
}
var ro=[];for(let io in global.rec_d) ro.push(global.rec_d[io].id);
let a7 = JSON.parse(str[3]); let skk=0; for (let obj in skl) if(a7[skk]){skl[obj].exp=a7[skk][0]||0;skl[obj].expnext_t=skl[obj].expnext();skl[obj].p=a7[skk++][1];
if(!skl[obj].p)skl[obj].p=1;if(skl[obj].p<.99)skl[obj].p+=1} global.flags.loadstate=true;
for(let o=0;o<a4.length;o++) for (let obj in effect) if (effect[obj].id===a4[o].a) {if(effect[obj].save!==false)giveEff(you,effect[obj],a4[o].b,a4[o].c);else{effect[obj].onRemove()};continue} global.flags.loadstate=false;
let a1 = JSON.parse(str[4]);
global.sm=a1.b;global.rm=a1.a;global.spirits=a1.f; global.lst_loc=a1.i; global.uid=a1.uid;
global.msgs_max=a1.g; global.flags={};
global.sinv = [];
global.bestiary=a1.q; global.timehold=a1.r||((time.minute/DAY)<<0); global.timewold=a1.r2||((time.minute/WEEK)<<0);
global.lst_sve=a1.m; global.timescale=a1.u||1;global.offline_evil_index=a1.z||1; global.drdata=a1.drdata||{}
for(let gb=0;gb<a1.datas.length;gb++){for(let itm in item) if(item[itm].id===a1.datas[gb]) item[itm].data.tried=true}
if(a1.datar) for(let gb=0;gb<a1.datar.length;gb++){for(let itm in item) if(item[itm].id===a1.datar[gb]) item[itm].data.finished=true}
time.minute = a1.j; timeConv(time); for(let w in weather)if(weather[w].id===a1.l)setWeather(weather[w],a1.k);
global.bg_r=a1.n;global.bg_g=a1.o;global.bg_b=a1.p;
for(let a in global.stat) global.stat[a]=a1.jj[a]||0;let tempt=new Date();if(global.stat.sttime===0)global.stat.sttime=tempt.getFullYear()+'/'+(tempt.getMonth()+1)+'/'+tempt.getDate()+' '+tempt.getHours()+':'+(tempt.getMinutes()>=10?tempt.getMinutes():'0'+tempt.getMinutes())+':'+(tempt.getSeconds()>10?tempt.getSeconds():'0'+tempt.getSeconds()); if(global.stat.msts===0)global.stat.msts=[[0,0],[0,0],[0,0],[0,0],[0,0],[0,0],[0,0],[0,0]];if(global.stat.msks===0)global.stat.msks=[0,0,0,0,0,0,0]
dom.ct_bt4_21b.value = global.bg_r;dom.ct_bt4_22b.value = global.bg_g;dom.ct_bt4_23b.value = global.bg_b; global.stat.wsnburst=50;
dom.ctrwin4.style.display='none';dom.ctrwin2.style.display='none';dom.ctrwin1.style.display='';global.lw_op=0;
if(global.flags.civil===false&&global.flags.btl===true) for (let obj in area) if (area[obj].id===a1.x) {area_init(area[obj]);break}
let a2 = JSON.parse(str[5]); for(let o=0;o<a2.length;o++){for (let obj in rcp) if (rcp[obj].id===a2[o].id&&rcp[obj].have===false) {global.rec_d.push(rcp[obj]);rcp[obj].have=true;rcp[obj].data=a2[o].data}} ;
for(let o=0;o<ro.length;o++){for (let obj in rcp) if (rcp[obj].id===ro[o]&&rcp[obj].have===false) {global.rec_d.push(rcp[obj]);rcp[obj].have=true}}
dom.d2.innerHTML = you.name; eqpres();
unequip(you.eqp[4],{save:true}); unequip(you.eqp[5],{save:true}); you.stat_r();
let a3 = JSON.parse(str[6]); global.flags.loadstate=true;
if(a3[0].length!=0)for(let o=0;o<a3[0].length;o++)for(let obj in item){if(item[obj].id===a3[0][o].id) {giveItem(item[obj],a3[0][o].am,true,{fi:true});inv[o].new=false;for(let a in a3[0][o].data) inv[o].data[a]=a3[0][o].data[a]}continue}
if(a3[1].length!=0)for(let o=0;o<a3[1].length;o++)for(let obj in wpn)if(wpn[obj].id===a3[1][o].id){let t=giveItem(wpn[obj],1,true);t.new=false;t.dp=a3[1][o].dp;for(let a in a3[1][o].data) t.data[a]=a3[1][o].data[a];if(a3[1][o].toeq===true) equip(t,{save:true});continue}
if(a3[2].length!=0)for(let o=0;o<a3[2].length;o++)for(let obj in eqp)if(eqp[obj].id===a3[2][o].id){let t=giveItem(eqp[obj],1,true);t.new=false;t.dp=a3[2][o].dp;for(let a in a3[2][o].data) t.data[a]=a3[2][o].data[a];if(a3[2][o].toeq===true){if(t.slot===5&&you.eqp[5].id===10000) t.slot=6; equip(t,{save:true})}}
if(a3[3].length!=0)for(let o=0;o<a3[3].length;o++)for(let obj in sld)if(sld[obj].id===a3[3][o].id){let t=giveItem(sld[obj],1,true);t.new=false;t.dp=a3[3][o].dp;for(let a in a3[3][o].data) t.data[a]=a3[3][o].data[a];if(a3[3][o].toeq===true) equip(t,{save:true});continue}
if(a3[4].length!=0)for(let o=0;o<a3[4].length;o++)for(let obj in acc)if(acc[obj].id===a3[4][o].id){let t=giveItem(acc[obj],1,true);t.new=false;t.dp=a3[4][o].dp;for(let a in a3[4][o].data) t.data[a]=a3[4][o].data[a];if(a3[4][o].toeq===true) equip(t,{save:true});continue};
if(you.eqp[0].id===10000){you.eqp[0].cls[2]=you.lvl/4<<0;you.eqp[0].aff[0]=you.lvl/5<<0;you.eqp[0].ctype=2}
let a5 = JSON.parse(str[7]); let xx=0; for (let o in area) if(a5[xx]) area[o].size=a5[xx++]//||area[o].size;
let a8 = JSON.parse(str[8]); dar=a8;
if(a8[0].length!=0)for(let o=0;o<a8[0].length;o++)for(let obj in item)if(item[obj].id===a8[0][o])item[obj].data.dscv=true;
if(a8[1].length!=0)for(let o=0;o<a8[1].length;o++)for(let obj in wpn)if(wpn[obj].id===a8[1][o])wpn[obj].data.dscv=true;
if(a8[2].length!=0)for(let o=0;o<a8[2].length;o++)for(let obj in eqp)if(eqp[obj].id===a8[2][o])eqp[obj].data.dscv=true;
if(a8[3].length!=0)for(let o=0;o<a8[3].length;o++)for(let obj in sld)if(sld[obj].id===a8[3][o])sld[obj].data.dscv=true;
if(a8[4].length!=0)for(let o=0;o<a8[4].length;o++)for(let obj in acc)if(acc[obj].id===a8[4][o])acc[obj].data.dscv=true;
if(a3[5].length!=0)for(let a in a3[5]) for(let b in item) if(item[b].id===a3[5][a].item) item[b].data=a3[5][a].data;
for(let a in furniture) furniture[a].active=false;for(let a in furn) furn[a].data={}; furn=[];
let a9 = JSON.parse(str[9]); for(let a=0;a<a9.length;a++) for(let obj in furniture) if (furniture[obj].id===a9[a].id&&a9[a].data.amount>0) {furn[a]=furniture[obj];furn[a].data=a9[a].data}
let a10 = JSON.parse(str[10]); let a11 = JSON.parse(str[11]);
global.flags=a1.e; global.flags.rdng=false;global.flags.civil = true; global.flags.btl = false; global.current_z=area.nwh; global.current_m=creature.default;update_m(); dom.d7m.update(); global.flags.wkdis=false; global.flags.jdgdis=false;
for(let obj in vendor){
if(a10[obj]&&a10[obj].stock) {vendor[obj].stock = a10[obj].stock; vendor[obj].data = a10[obj].data; if(!vendor[obj].data.time||vendor[obj].data.time<0)vendor[obj].data.time=1
for(let itm=0;itm<a10[obj].stock.length;itm++){
let k = itemgroup[(a10[obj].stock[itm][0]+1)/10000<<0];
for (let v in k) if(k[v].id===a10[obj].stock[itm][0]) {vendor[obj].stock[itm][0]=k[v];continue}
}
}else{restock(vendor[obj])}} ;
let a12 = JSON.parse(str[11]); for(let ttlid=0;ttlid<a12.length;ttlid++) for(let obj in ttl) if(ttl[obj].id===a12[ttlid]) {global.titles[ttlid]=ttl[obj];global.titles[ttlid].have=true;} for(let obj in global.titlese) global.titles.push(global.titlese[obj]); global.titlese=[];
let a13 = JSON.parse(str[12]); for(let s in a13) {for(let ss in furn) if(furn[ss].id===a13[s]) home[s]=furn[ss]} qsts=[];
let a14 = JSON.parse(str[13]); for(let obj in a14) for(let q in quest) if(quest[q].id===a14[obj].id) {qsts[obj]=quest[q];qsts[obj].data=a14[obj].data;if(qsts[obj].callback)qsts[obj].callback()}
global.current_a=act.default; acts=[]; for(let a in act) {act[a].have=false;act[a].data={};act[a].active=false}
let a15 = JSON.parse(str[14]); for(let obj in a15) for(let q in act) if(act[q].id===a15[obj].id) {acts[obj]=act[q];acts[obj].data=a15[obj].data;act[q].have=true} for(let a in sectors) sectors[a].onLeave();sectors=[]
let a16 = JSON.parse(str[15]); for(let obj in a16) for(let q in sector) if(sector[q].id===a16[obj].id) {if(objempty(a16[obj].data)===false) {for(let a in a16[obj].data) sector[q].data[a]=a16[obj].data[a]} else if(sector[q].ddata)sector[q].data=sector[q].ddata}
clearInterval(timers.vndrstkchk);for (let obj in chss) if(chss[obj].id === a1.i) {global.current_l = chss[obj];smove(chss[obj],false);}
let a17 = JSON.parse(str[16]); for(let a in container) container[a].c=[]; if(a17[0]&&!a17[0].c) {a17=[{id:1,c:a17}]};
for(let a in a17){
for(let d in container) if(container[d].id===a17[a].id) {for(let c in a17[a].c){
let k = itemgroup[(a17[a].c[c].id+1)/10000<<0];
for(let b in k) if(k[b].id===a17[a].c[c].id){let ni = {item:k[b],data:a17[a].c[c].data,am:a17[a].c[c].am,dp:a17[a].c[c].dp};container[d].c.push(ni);break}
}break}
}
let a18 = JSON.parse(str[17]); for(let obj in a18) for(let q in chss) if(chss[q].id===a18[obj].id) {if(objempty(a18[obj].data)===false) chss[q].data=a18[obj].data}
if(str[19]){let a19 = JSON.parse(str[19]); for(let a in a19) for(let b in ttl) if(a19[a]===ttl[b].id) ttl[b].tget=true}
for(let a in ttl) {if(ttl[a].have&&ttl[a].talent&&!ttl[a].tget){ttl[a].talent();ttl[a].tget=true}}
isort(global.sm); rsort(global.rm);rstcrtthg();you.stat_r(); global.spbtsr[global.rm].style.color='yellow';
if (global.flags.aw_u){dom.d0.style.display='';dom.d1m.style.display='';dom.inv_ctx.style.display='';dom.gmsgs.style.display='';dom.ct_ctrl.style.display='';dom.ctr_1.style.display='';dom.d_lct.style.display=''}dom.ctrwin3.style.display='none'; dom.ctrwin5.style.display='none'
dom.d5_1_1.update();dom.d5_2_1.update();dom.d6.update();update_d();dom.d3.update();update_m();m_update();dom.d7m.update();dom.d5_3_1.update();
if(global.flags.m_freeze===true)dom.m_b_1_c.innerHTML='X';
if(global.flags.m_blh===true)dom.m_b_2_c.innerHTML='X';
if(global.flags.jnlu)dom.ct_bt6.innerHTML='journal'; if(global.flags.asbu)dom.ct_bt1.innerHTML='assemble'; if(global.flags.actsu)dom.ct_bt3.innerHTML='actions'; if(global.flags.sklu)dom.ct_bt2.innerHTML='skills';
if(global.flags.m_un===true){dom.mn_2.style.display='';dom.mn_4.style.display='';dom.mn_3.style.display='';if(global.stat.mndrgnu)dom.mn_1.style.display=''; m_update();}
wManager();dom.d_moon.innerHTML=global.text.lunarp[getLunarPhase()][0]; addDesc(dom.d_moon,null,2,'Lunar Phase',global.text.lunarp[getLunarPhase()][1]); wdrseason(global.flags.ssngaijin);
if(global.flags.isday===false) dom.d_moon.style.display='';else dom.d_moon.style.display='none'
dom.sl_extra.innerHTML='Last save: '+global.lst_sve; dom.nthngdsp.style.display='none'; dom.ctrwin6.style.display='none'
invbtsrst();
dom.d_time.innerHTML = '<small>'+getDay(global.flags.tmmode||2)+'</small> '+timeDisp(time);
global.flags.loadstate=false; global.flags.savestate=false; global.flags.ttlscrnopn=false; global.flags.expatv=false; global.flags.impatv=false;global.flags.expatv=false;
}
if(!global.flags.stbxinifld){
addToContainer(home.trunk,eqp.gnt);
addToContainer(home.trunk,acc.fmlim);
addToContainer(home.trunk,wpn.bdsrd);
addToContainer(home.trunk,item.toolbx);
addToContainer(home.trunk,sld.tge);
addToContainer(home.trunk,item.bonig);
global.flags.stbxinifld=true;
}
if(global.flags.bgspc)document.body.style.background='linear-gradient(180deg,#000,#123)';else document.body.style.backgroundColor='rgb('+global.bg_r+','+global.bg_g+','+global.bg_b+')';
if(dom.bkssttbd){empty(dom.bkssttbd);document.body.removeChild(dom.bkssttbd);global.flags.bksstt=false;kill(dom.bkssttbd)}
if(global.flags.expatv){empty(dom.ct_bt4_5a_nc);document.body.removeChild(dom.ct_bt4_5a_nc); kill(dom.ct_bt4_5a_nc)}
if(global.flags.impatv){empty(dom.ct_bt4_5b_nc);document.body.removeChild(dom.ct_bt4_5b_nc); kill(dom.ct_bt4_5b_nc)}
if(dom.error) {empty(dom.error); document.body.removeChild(dom.error); kill(dom.error)}
if(global.flags.autosave===true){dom.autosves.checked=true;timers.autos=setInterval(function(){save(true);},30000)}
//if(global.flags.msgtm===true)dom.ct_bt4_61b.checked=true;
////patch things
if(skl.pet.lvl>=10)giveTitle(ttl.pet3);
if(item.amrthsck.data.finished)giveRcp(rcp.appljc)
////////////////
if(dom.loading) {fade(dom.loading,5,true); delete dom.loading;};if(dom.loadingt) {fade(dom.loadingt,5,true);delete dom.loadingt;}
}
///////////////////////////////////////////
//TTL
///////////////////////////////////////////
function Title(id){
this.name; this.id=id||0
this.desc;
this.have=false
this.tget=false
this.rar=1;
this.onGet = function(){}
}
ttl.new = new Title(0);
ttl.new.name = 'Nobody';
ttl.new.desc = 'Unremarkable someone trying to find his purpose in life';
ttl.inn = new Title(1);
ttl.inn.name = 'Initiate';
ttl.inn.desc = 'Dojo disciple who managed to finish the first training stages. Woo!';
ttl.thr = new Title(2);
ttl.thr.name = 'Thrasher'; ttl.thr.rar=1;ttl.thr.rars=true
ttl.thr.desc = 'The one who destroyed dojo\'s precious equipment. Were you a bit older you\'d pay the expences, but you made your teacher proud.';
ttl.wsl = new Title(3);
ttl.wsl.name = 'Wolf Slayer';
ttl.wsl.desc = 'You went alone against a pack of feral wolves. That amounts to something!';
ttl.knf = new Title(4);
ttl.knf.name = 'Butterfly'; ttl.knf.rar=2
ttl.knf.desc = 'You always thought knives were cool. You aren\'t nearly precise with your knifework yet, But you will learn';
ttl.bll = new Title(5);
ttl.bll.name = 'Bully'; ttl.bll.rar=2
ttl.bll.desc = 'You have graduated from being a mere Weakling. You feel powerful! You still find it difficult to stand your own in a fight';
ttl.cvl = new Title(6);
ttl.cvl.name = 'Civilian';
ttl.cvl.desc = 'You\'re not very suitable for combat. But you think you\'re out of options';
ttl.stk = new Title(7);
ttl.stk.name = 'Stick Kid';
ttl.stk.desc = 'You always liked swinging that thing around. You think you\'re beginning to understand how to land hits properly. Or not';
ttl.fgt = new Title(8);
ttl.fgt.name = 'Fighter'; ttl.fgt.rar=2
ttl.fgt.desc = 'You begin to start liking to fight! At the very least you can now somewhat defend yourself against mild threats and not just die in one hit';
ttl.pbg = new Title(9);
ttl.pbg.name = 'Weakling';
ttl.pbg.desc = 'You can\'t really hit anything with these frail arms of yours';
ttl.brw = new Title(10);
ttl.brw.name = 'Brawler';
ttl.brw.desc = 'You feel like you can pack a punch! And recieve one. You\'re starting to feel a bit more comfortable with your bare fists';
ttl.stb = new Title(11);
ttl.stb.name = 'Stabber'; ttl.stb.rar=3
ttl.stb.desc = 'Even if it\'s a smaller tool compared to any other weapon, you\'ve learned how to make knives useful for self-defence, since they are somewhat easier to handle than the rest. You can hit vitals better too';
ttl.slp1 = new Title(12);
ttl.slp1.name = 'Sleeper';
ttl.slp1.desc = 'You really like sleeping don\'t you? You spend a lot of time in your bed';
ttl.slp2 = new Title(13);
ttl.slp2.name = 'Heavy Sleeper'; ttl.slp2.rar=2
ttl.slp2.desc = 'You learned to sleep very soundly, without any care for the outside world. Your body begins to adapt and grow stronger with every break you take';
ttl.slp3 = new Title(14);
ttl.slp3.name = 'Dreamwatcher'; ttl.slp3.rar=3
ttl.slp3.desc = '3';
ttl.tcvl = new Title(15);
ttl.tcvl.name = 'Trained Civilian'; ttl.tcvl.rar=2
ttl.tcvl.desc = 'You\'re still nearly useless in a real fight, but you have learned to at least move out of the way of danger';
ttl.plm = new Title(16);
ttl.plm.name = 'Prick';
ttl.plm.desc = 'You found it fun to make little holes in plant leaves and look through them at the Sun. You think this could be morbidly useful in a fight';
ttl.wlk = new Title(17);
ttl.wlk.name = 'Walker';
ttl.wlk.desc = 'All this walking around feels very beneficial for your body';
ttl.wlk.talent = function(){you.mods.runerg-=.05}
ttl.wlk.onGet = function(){if(act.demo.active)you.mods.sdrate-=.005}
ttl.wlk.tdesc = 'Running consumes 5% less energy'
ttl.eat1 = new Title(18);
ttl.eat1.name = 'Starving Child';
ttl.eat1.desc = 'You\'ve been all skin and bones as long as you can remember. You will need to start eating properly if you wish to survive';
ttl.eat2 = new Title(19);
ttl.eat2.name = 'Hungry Child'; ttl.eat2.rar=2
ttl.eat2.desc = 'You begin to gain some weight eating all this boring and dry food. But you\'re not complaining, at least you live';
ttl.eat4 = new Title(20);
ttl.eat4.name = 'Satiated'; ttl.eat4.rar=4
ttl.eat4.desc = 'Being full is good, but you start to wonder what kinds of different dishes exist in the world';
ttl.eat5 = new Title(21);
ttl.eat5.name = 'Mini-Gourmand'; ttl.eat5.rar=5
ttl.eat5.desc = 'You begin to understand the importance of tasty food! You crave the larger variety';
ttl.cck = new Title(22);
ttl.cck.name = 'Campfire Cook';
ttl.cck.desc = 'Not something to brag about, but you won\'t completely starve to death if you find yourself in the wilds without a proper meal';
ttl.rok = new Title(23);
ttl.rok.name = 'Rookie'; ttl.rok.rar=3
ttl.rok.desc = 'A novice fighter. You have a knack for martial arts but it doesn\'t amount to much yet';
ttl.rnr = new Title(24);
ttl.rnr.name = 'Runner'; ttl.rnr.rar=3
ttl.rnr.desc = 'Your body is in much better shape, so is your stamina. Moving around fast doesn\'t bother you as much anymore, but you spend your energy and get kind of hungry from it';
ttl.jgg = new Title(25);
ttl.jgg.name = 'Jogger'; ttl.jgg.rar=2
ttl.jgg.desc = 'Simply walking doesn\'t cut it anymore, maybe you should speed up a bit while travelling on foot?';
ttl.jgg.talent = function(){you.mods.runerg-=.15}
ttl.jgg.onGet = function(){if(act.demo.active)you.mods.sdrate-=.015}
ttl.jgg.tdesc = 'Running consumes 15% less energy'
ttl.spn = new Title(26);
ttl.spn.name = 'Sprinter'; ttl.spn.rar=4
ttl.spn.desc = 's';
ttl.ilt = new Title(27);
ttl.ilt.name = 'Illiterate';
ttl.ilt.desc = 'You have a really difficult time understanding even the basic writings. Even the signs outside the shops give you trouble';
ttl.und = new Title(28);
ttl.und.name = 'Uneducated'; ttl.und.rar=2
ttl.und.desc = 'You are not very friendly with books, your entire literature knowledge is nothing but simple kiddie stories and fairy tales';
ttl.aaa = new Title(29);
ttl.aaa.name = 'aaa';
ttl.aaa.desc = 'They say that in the hands of a gosu with great inner ki, even a dead leaf can become a weapon that can pierce iron plates';
ttl.eat3 = new Title(30);
ttl.eat3.name = 'Malnourished'; ttl.eat3.rar=3
ttl.eat3.desc = 'You are clearly undereating, yet, eating something other than bland untasty bread leaves you in a positive mood ';
ttl.srd1 = new Title(31);
ttl.srd1.name = 'Aspiring Ronin';
ttl.srd1.desc = 'Watching swordplay of elder swordmasters always fascinated you, yet even trying to hold the sword properly is apparently extremely difficult. You are not the type to give up though';
ttl.srd2 = new Title(32);
ttl.srd2.name = 'Sword Trainee'; ttl.srd2.rar=2
ttl.srd2.desc = 'You have only just began learning the Way of the Sword, which clearly shows. You still find it hard to wield the sword properly, let alone attempting to hit something with it';
ttl.srd3 = new Title(33);
ttl.srd3.name = 'Squire'; ttl.srd3.rar=3
ttl.srd3.desc = 'All those thousand swings training sessions weren\'t for nothing. Now you can hold your sword somewhat straight and your posture got better. Hovewer, slashing things didn\'t get any easier';
ttl.srd4 = new Title(34);
ttl.srd4.name = 'Blade for Hire'; ttl.srd4.rar=4
ttl.srd4.desc = 'Your swordplay has reached the rank of a common foot soldier. Or so you thought. Maybe you can match a lowest level mercenary, which isn\'t something to be proud of. You are still ways away from calling yourself a proper swordsman';
ttl.lnc1 = new Title(35);
ttl.lnc1.name = 'Spearholder';
ttl.lnc1.desc = 'You have learned how the art of Spearmanship can be used for both offensive and defensive combat, which you think suits you pretty well. Hovewer, handling a spear with skill is much more difficult than you initially thought';
ttl.lnc2 = new Title(36);
ttl.lnc2.name = 'Village Militia'; ttl.lnc2.rar=2
ttl.lnc2.desc = 'Your reflexes wielding a polearm got slightly better, at the very least you aren\'t dropping your weapon after every second swing anymore. You could be considered a part of a peasant spear group with your measly skills';
ttl.lnc3 = new Title(37);
ttl.lnc3.name = 'Phlanger'; ttl.lnc3.rar=3
ttl.lnc3.desc = 'You\'re getting a hold of your primitive spearmanship, which is reasurring considering how much effort went into your training. You could be a part of the second-rate frontline military squad with your ability, but you will aim higher';
ttl.hmr2 = new Title(38);
ttl.hmr2.name = 'Basher'; ttl.hmr2.rar=2
ttl.hmr2.desc = 'Squashing things with a hammer or a club may seem simple, but it does require some skill to do so properly and effectively. You understand the basics but lack the strength for it, though';
ttl.hmr3 = new Title(39);
ttl.hmr3.name = 'Heavy Hand'; ttl.hmr3.rar=3
ttl.hmr3.desc = 'You favor strong blunt weaponry, which shows by how sturdy and hard your hands have become. This is good for your overall strength. You still lack any skill or technique, hovewer';
ttl.kill1 = new Title(40);
ttl.kill1.name = 'Pest Control';
ttl.kill1.desc = 'You have wiped out about 10000 creatures on your way. Most of them weren\'t living things though... right?';
ttl.rspn1 = new Title(41);
ttl.rspn1.name = 'Punching Bag';
ttl.rspn1.desc = 'Getting beat up like this hurts like hell. You better think of a way out of this misery!';
ttl.rfpn1 = new Title(42);
ttl.rfpn1.name = 'Garbage Eater';
ttl.rfpn1.desc = 'All the time you had to consume disgusting rotten stuff is finally paying off... Kind of. You would rather avoid doing that in the future, if possible';
ttl.rfpn2 = new Title(43);
ttl.rfpn2.name = 'Iron Stomach'; ttl.rfpn2.rar=2;
ttl.rfpn2.desc = 'Going through these desperate times of having such an unsafe diet, your stomach doesn\'t feel as awful anymore. You really shouldn\'t be doing that';
ttl.rfpn2.talent = function(){you.mods.survinf++}
ttl.rfpn2.tdesc = 'Allows you to roughly guess when perishable food rots (shift key)'
ttl.rfpn3 = new Title(44);
ttl.rfpn3.name = 'Omnivore'; ttl.rfpn3.rar=3;
ttl.rfpn3.desc = 'It seems like you can eat a lot of awful stuff and feel fine afterwards. Is that really worth it? You think it is. The taste doesn\'t get any better though...';
ttl.tqtm = new Title(45);
ttl.tqtm.name = 'Quartermaster'; ttl.tqtm.rars=true;
ttl.tqtm.desc = 'You have returned more than 300 pieces of dojo supplies. How much of that stuff do they have?';
ttl.tqtm.talent = function(){/*(:*/}
ttl.tqtm.tdesc = 'Dummies may drop something special'
ttl.ddw = new Title(46);
ttl.ddw.name = 'Glass Bones'; ttl.ddw.rar=0;ttl.ddw.rars=true;
ttl.ddw.desc = 'Bizzarely, you got yourself knocked out by the weakest enemy in existence. How did that happen? You feel like you have achieved somewhat absurd understanding of how frail your body actually is. Perhaps violence isn\'t for you';
ttl.neet = new Title(47);
ttl.neet.name = 'Hikikomori'; ttl.neet.rars=true;
ttl.neet.desc = 'You have spent an entire year at your house without going out even once. You were somewhat productive in your seclusion, but the time spent didn\'t even feel like a year, however...';
ttl.aptc = new Title(48);
ttl.aptc.name = 'Apprentice'; ttl.aptc.rar=2;
ttl.aptc.desc = 'You have succesfully completed the second part of dojo\'s training courses. You are impressed by your own achievements!';
ttl.sld1 = new Title(49);
ttl.sld1.name = 'Wimp';
ttl.sld1.desc = 'The fear of pain has forced you to begin taking cover behind whatever you take your hands on. Shields fall within this category nicely, you think you should try learning how to handle them properly';
ttl.sld2 = new Title(50);
ttl.sld2.name = 'Defender'; ttl.sld2.rar=2;
ttl.sld2.desc = 'Even if you\'re still full of openings and have a terrible time adjusting to the weight of a shield you\'re holding, you can still manage to reflect the slowest, stupidest and the most direct attack you\'re facing. Sometimes';
ttl.sld3 = new Title(51);
ttl.sld3.name = 'Protector'; ttl.sld3.rar=3;
ttl.sld3.desc = 'You understand better how shields work, and your reaction time against frontal attacks has improved as well. Your openings are still plentiful, but you manage to stay alive';
ttl.sld4 = new Title(52);
ttl.sld4.name = 'Sentry'; ttl.sld4.rar=4;
ttl.sld4.desc = '';
ttl.seye1 = new Title(53);
ttl.seye1.name = 'Bat Eyes';
ttl.seye1.desc = 'Sometimes when you hit an enemy the certain way your attack feels somewhat stronger, you noticed. What\'s that about?';
ttl.seye2 = new Title(54);
ttl.seye2.name = 'Suspicious Eyes'; ttl.seye2.rar=2;
ttl.seye2.desc = 'You have confirmed it, bashing the enemy on the head makes your battles end slightly quicker. Is it only the head that does that?';
ttl.pet1 = new Title(55);
ttl.pet1.name = 'Valley Cat';
ttl.pet1.desc = 'Stray animals don\'t seem to be wary of you that much, for some reason. You are able to hug a random cat without it running away';
ttl.pet2 = new Title(56);
ttl.pet2.name = 'Animal Friend'; ttl.pet2.rar=2;
ttl.pet2.desc = 'Minor predators don\'t view you as a threat, which is good, but you don\'t want to bother them when they\'re hungry, though. You think you have a way to avoid the dangers of wild life, at least';
ttl.dngs1 = new Title(57);
ttl.dngs1.name = 'Wary';
ttl.dngs1.desc = 'Sometimes when you\'re hit it hurts much more then usual. You hate this, but why does that happen? You have to figure out how to avoid this';
ttl.dngs2 = new Title(58);
ttl.dngs2.name = 'Careful'; ttl.dngs2.rar=2;
ttl.dngs2.desc = 'Avoiding hits to the vitals is much harder, as you found out. You must think of a way to take precautions to guarantee your own safety';
ttl.rtr1 = new Title(59);
ttl.rtr1.name = 'Coward'; ttl.rtr1.rar=1;
ttl.rtr1.desc = 'You can\'t stomach the thought of getting seriously injured at all. Running away from danger is where it\'s at';
ttl.ddcd = new Title(60);
ttl.ddcd.name = 'null'; ttl.ddcd.rar=0; ttl.ddcd.rars=true;
ttl.ddcd.desc = 'null';
ttl.neet2 = new Title(61);
ttl.neet2.name = 'Shut In'; ttl.neet2.rar=2; ttl.neet2.rars=true;
ttl.neet2.desc = 'Staying home for a year was nothing, this time you went half a decade staying put in your comfortable living space, caring not for the outside world. You are not sure how you feel about nobody ever checking on you..';
ttl.neet3 = new Title(62);
ttl.neet3.name = 'Hermit'; ttl.neet3.rar=3; ttl.neet3.rars=true;
ttl.neet3.desc = 'Tenth of century at home, you did it. What were you even doing in there? Sleeping? Cultivating? It doesn\'t matter, you can proudly call yourself a hermit and stay forgotten until you decide to show yourself in light again';
ttl.coo1 = new Title(63);
ttl.coo1.name = 'Kitchen Nightmare';
ttl.coo1.desc = 'Either cooking is a very difficult art, or you\'re just very bad at it. Leaving you alone in the kitchen is a recipe for disaster. But you won\'t become good without making some mistakes first';
ttl.kill2 = new Title(64);
ttl.kill2.name = 'Sweeper'; ttl.kill2.rar=2;
ttl.kill2.desc = 'Eliminating 50000 creatures like it was nothing made you wonder whether this realm is filled with weaklings or it is you who are simply too strong to handle. It is probably the former';
ttl.kill3 = new Title(65);
ttl.kill3.name = 'Bone Collector'; ttl.kill3.rar=3;
ttl.kill3.desc = 'Hack and slash! 200000 foes have fallen under mighty arm! You\'re getting a little too comfortable on your path of destruction';
ttl.kill4 = new Title(66);
ttl.kill4.name = 'Decamate'; ttl.kill4.rar=4;
ttl.kill4.desc = 'Million down, billions to go...';
ttl.kill5 = new Title(67);
ttl.kill5.name = 'Sentinel'; ttl.kill5.rar=5;
ttl.kill5.desc = '5 million deaths! You managed to undo the population of the small city. That\'s quiet a feat given your low power level';
ttl.axc1 = new Title(68);
ttl.axc1.name = 'Hack';
ttl.axc1.desc = 'Axes are difficult to handle, you learned. This isn\'t simply chpping firewood on a log, you a need hard grip and proper hand flexibility to fight with them efficiently';
ttl.axc2 = new Title(69);
ttl.axc2.name = 'Chopper';
ttl.axc2.desc = 'You feel strong when using axes in battles! You only feel that way, you are not any strong with it yet. It is difficut for you to find the right balance to swing that thing';
ttl.axc3 = new Title(70);
ttl.axc3.name = 'Axejack'; ttl.axc3.rar=3;
ttl.axc3.desc = '';
ttl.dth1 = new Title(71);
ttl.dth1.name = 'Fallen';
ttl.dth1.desc = 'Somehow you always escape life threatening situations even after being hit and bruised a lot, hovewer you still lose conciousness. Newbie\'s luck?';
ttl.dth2 = new Title(72);
ttl.dth2.name = 'Decadent'; ttl.dth2.rar=2;
ttl.dth2.desc = 'Often you manage to avoid death even after being heavily injured. Perhaps you have a very resilient body, or Heavens aren\'t willing to accept you yet';
ttl.dth3 = new Title(73);
ttl.dth3.name = 'Cadaver'; ttl.dth3.rar=3;
ttl.dth3.desc = '';
ttl.sld5 = new Title(74);
ttl.sld5.name = 'Bastion'; ttl.sld5.rar=5;
ttl.sld5.desc = '';
ttl.seye3 = new Title(75);
ttl.seye3.name = 'Dissector'; ttl.seye3.rar=3;
ttl.seye3.desc = 'By slaying foes as much as you did, you learned how to quickly notice your enemies\' weak points. This knowledge will allow you quickly and effectively dispose of those standing in your way';
ttl.fmn1 = new Title(76);
ttl.fmn1.name = 'Scrawny';
ttl.fmn1.desc = 'You feel terrible. You might want to eat something or you\'ll end up being nothing more than a skeleton';
ttl.fmn2 = new Title(77);
ttl.fmn2.name = 'Bag Of Bones'; ttl.fmn2.rar=2;
ttl.fmn2.desc = 'Days of hunger took a toll on your body, yet made you learn to conserve your energy by other means, which shows. Just a bit';
ttl.fmn3 = new Title(78);
ttl.fmn3.name = 'Emaciated'; ttl.fmn3.rar=3;
ttl.fmn3.desc = 'Yesterdays\'s weakness is today\'s strength. Or so you\'ve heard. You are not feeling as awful and weak by starving yourself, but there\'s still nothing to be proud of';
ttl.shpt1 = new Title(79);
ttl.shpt1.name = 'Third-Rate Shopper';
ttl.shpt1.desc = 'You left the shop with half a thousand goods total. It\'s a tiny amount if you think about it - food, cooking ingredients, household tools';
ttl.shpt2 = new Title(80);
ttl.shpt2.name = ''; ttl.shpt2.rar=2;
ttl.shpt2.desc = ''
ttl.shpt3 = new Title(81);
ttl.shpt3.name = ''; ttl.shpt3.rar=3;
ttl.shpt3.desc = ''
ttl.mone1 = new Title(82);
ttl.mone1.name = 'Beggar';
ttl.mone1.desc = 'Acquiring a whole 1 Gold coin worth of money is a lot for someone as pathetic you. You could survive with that amount for a year!';
ttl.mone2 = new Title(83);
ttl.mone2.name = 'Peasant'; ttl.mone2.rar=2;
ttl.mone2.desc = ''
ttl.mone3 = new Title(84);
ttl.mone3.name = ''; ttl.mone3.rar=3;
ttl.mone3.desc = ''
ttl.geti1 = new Title(85);
ttl.geti1.name = 'Collector';
ttl.geti1.desc = ''
ttl.geti2 = new Title(86);
ttl.geti2.name = 'Packmule'; ttl.geti2.rar=2;
ttl.geti2.desc = ''
ttl.geti3 = new Title(87);
ttl.geti3.name = 'Hoarder'; ttl.geti3.rar=3
ttl.geti3.desc = ''
ttl.geti4 = new Title(88);
ttl.geti4.name = 'Treasure Hunter'; ttl.geti4.rar=4
ttl.geti4.desc = ''
ttl.tghs1 = new Title(89);
ttl.tghs1.name = 'Scarred';
ttl.tghs1.desc = ''
ttl.tghs2 = new Title(90);
ttl.tghs2.name = 'Thickskinned'; ttl.tghs2.rar=2;
ttl.tghs2.desc = ''
ttl.tghs3 = new Title(91);
ttl.tghs3.name = 'Brute'; ttl.tghs3.rar=3;
ttl.tghs3.desc = ''
ttl.dth4 = new Title(92);
ttl.dth4.name = 'Carcass'; ttl.dth4.rar=4;
ttl.dth4.desc = '';
ttl.ttsttl1 = new Title(93);
ttl.ttsttl1.name = 'Unknown';
ttl.ttsttl1.desc = 'You barely took a single minor step into the world by gathering 10 titles. Nobody takes notice of you or your ambition, you are but a filler existence that doesn\'t amount to anything yet';
ttl.ttsttl2 = new Title(94);
ttl.ttsttl2.name = 'Nameless'; ttl.ttsttl2.rar=2;
ttl.ttsttl2.desc = '25 titles would be something an average working man would aquire effortlessly by simply living his life. You shouldn\'t feel proud by only reaching this high';
ttl.ttsttl3 = new Title(95);
ttl.ttsttl3.name = 'Ordinary'; ttl.ttsttl3.rar=3;
ttl.ttsttl3.desc = 'You\'re finally getting somewhere, having a basic set of skills and minor achievements. You could even be called reliable by some. But once again, you are feeling like a part of the mass';
ttl.ttsttl4 = new Title(96);
ttl.ttsttl4.name = 'Accomplished'; ttl.ttsttl4.rar=4;
ttl.ttsttl4.desc = '100';
ttl.hstr1 = new Title(97);
ttl.hstr1.name = 'Pathetic';
ttl.hstr1.desc = 'Your weak punch can barely exert a power of 100kg, which is a measly amount in the martial world. A simple farmer can hit harder than this';
ttl.hstr2 = new Title(98);
ttl.hstr2.name = 'Softhitter'; ttl.hstr2.rar=2;
ttl.hstr2.desc = 'You got somewhat stronger in reaching 250kg worth of punch power. You can manage some physical labor with that strength, but nothing noteworthy';
ttl.hstr3 = new Title(99);
ttl.hstr3.name = 'Jawbreaker'; ttl.hstr3.rar=3;
ttl.hstr3.desc = 'Half ton punch isn\'t bad, you can successfully push a body a few meters back if you hit correctly in the right spot. This only applies to entities without strong physical protection, you are no match to anything with real strength';
ttl.hstr4 = new Title(100);
ttl.hstr4.name = 'Nameless'; ttl.hstr4.rar=4;
ttl.hstr4.desc = '1000';
ttl.cpet1 = new Title(101);
ttl.cpet1.name = 'Cat Lover'; ttl.cpet1.rar=2;
ttl.cpet1.desc = 'You really love that kitty';
ttl.jbs1 = new Title(102);
ttl.jbs1.name = 'Errand Boy';
ttl.jbs1.desc = '';
ttl.jbs2 = new Title(103);
ttl.jbs2.name = 'Part-Timer'; ttl.jbs2.rar=2;
ttl.jbs2.desc = '';
ttl.jbs3 = new Title(104);
ttl.jbs3.name = 'Hired Hand'; ttl.jbs3.rar=3;
ttl.jbs3.desc = '';
ttl.pet3 = new Title(105);
ttl.pet3.name = 'Wild Kid'; ttl.pet3.rar=3;
ttl.pet3.desc = 'All that time you spent with your cat made you understand a whole lot about the habits and behaviour of vicious predators. You feel that knowledge might prove to be useful one day';
ttl.ndthextr = new Title(106);
ttl.ndthextr.name = 'Safehouse'; ttl.ndthextr.rar=0;ttl.ndthextr.rars=true;
ttl.ndthextr.desc = 'You kept yourself well and protected, avoiding danger and moving out of harm\'s way for quiet some time. Almost like any other person who fears for his life';
ttl.indkill = new Title(107);
ttl.indkill.name = 'Indirect Killer'; ttl.indkill.rar=2;ttl.indkill.rars=true;
ttl.indkill.desc = '';
function Weather(id){
this.name='?'; this.id = id||-1
this.ontick=function(){};
} var weather = new Object();
weather.sunny = new Weather(100); weather.sunny.name = 'Sunny'; weather.sunny.c = 'yellow';
weather.cloudy = new Weather(101); weather.cloudy.name = 'Cloudy'; weather.cloudy.c = 'ghostwhite';
weather.stormy = new Weather(102); weather.stormy.name = 'Stormy'; weather.stormy.c = '#bdbdbd';
weather.overcast = new Weather(103); weather.overcast.name = 'Overcast'; weather.overcast.c='lightgrey';
weather.storm = new Weather(104); weather.storm.name = 'Storm'; weather.storm.frain=true; weather.storm.c='lightgrey';weather.storm.bc='#5a5a5a';
weather.thunder = new Weather(105); weather.thunder.name = 'Thunderstorm'; weather.thunder.frain=true; weather.thunder.c='yellow';weather.thunder.bc='#5a5a5a';
weather.rain = new Weather(106); weather.rain.name = 'Rain'; weather.rain.c='cyan'; weather.rain.bc='#2a3971'; weather.rain.frain=true;
weather.heavyrain = new Weather(107); weather.heavyrain.name = 'Heavy rain'; weather.heavyrain.frain=true; weather.heavyrain.c='cyan'; weather.heavyrain.bc='#4d5eb3';
weather.misty = new Weather(108); weather.misty.name = 'Misty'; weather.misty.bc='#244b68';
weather.foggy = new Weather(109); weather.foggy.name = 'Foggy'; weather.foggy.bc='#7c8b9a';
weather.drizzle = new Weather(110); weather.drizzle.name = 'Drizzle'; weather.drizzle.bc='254863'; weather.drizzle.frain=true;
weather.clear = new Weather(111); weather.clear.name = 'Clear';
weather.snow = new Weather(112); weather.snow.name = 'Snow'; weather.snow.c = 'white'; weather.snow.bc = '#aaa'; weather.snow.fsnow = true;
weather.sstorm = new Weather(113); weather.sstorm.name = 'Snow Storm'; weather.sstorm.c = 'white'; weather.sstorm.bc = '#88a'; weather.sstorm.fsnow = true;
weather.storm.ontick=weather.rain.ontick=weather.heavyrain.ontick=weather.drizzle.ontick=function(){
if(global.flags.inside===false) {
if(effect.wet.active===false&&!you.mods.rnprtk) giveEff(you,effect.wet,5);
let f = findbyid(global.current_m.eff,effect.wet.id);
if(!f||f.active===false) giveEff(global.current_m,effect.wet,5)
}
}
weather.thunder.ontick=function(){
if(global.flags.inside===false) {
if(effect.wet.active===false&&!you.mods.rnprtk) giveEff(you,effect.wet,5);
let f = findbyid(global.current_m.eff,effect.wet.id);
if(!f||f.active===false) giveEff(global.current_m,effect.wet,5)
if(random()<.0009){ global.stat.lgtstk++;
msg("You were struck by lightning!",'black',null,null,'yellow');
let d = (200/(1+skl.aba.lvl*.05))<<0;
if(you.hp-d<0) {global.atkdfty[0]=1;you.hp=0;you.onDeath();;giveSkExp(skl.painr,300);giveSkExp(skl.dth,100)} else {you.hp-=d;giveSkExp(skl.painr,170)} giveSkExp(skl.aba,30);
dom.d5_1_1.update();
}
}
}
function callbackManager(id){
this.id = id||0
this.hooks = [{f:function(victim, killer){},id:0,data:{}}]
this.fire = function(){}
}
callback.onDeath = new callbackManager(1);
callback.onDeath.fire = function(victim, killer){
for(let a in this.hooks) this.hooks[a].f(victim, killer)
}
function attachCallback(callback,what,data){
callback.hooks.push(what)
}
function detachCallback(callback,what){
for(let a in callback.hooks) if(callback.hooks[a].id === what) callback.hooks.splice(callback.hooks[a],1)
}
/*attachCallback(callback.onDeath,{
f:function(victim, killer){
if(victim.id===112) this.data.a++
if(this.data.a===5) msg("KILLED FIVE",'yellow')
},
id:50,
data:{a:0,q:true}
})*/
function Time(){
this.minute=0;
this.hour=0;
this.day=0;
this.month=0;
this.year=0;
}
time = new Time();
time.minute = 338144100;
global.text.d_l=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"];
global.text.d_s=["Mon.","Tue.","Wed.","Thu.","Fri.","Sat.","Sun."];
global.text.d_j=["月","火","水","木","金","土","日"];
///////////////////////////////////////////
//EFF
///////////////////////////////////////////
function Effect(){
this.name='dummy';
this.desc='';
this.type = 0; // 1 - on attack; 2 - on stat refersh; 3 - on tick; 4 - decor? 5 - stat mod? 6 - tickstat
this.x;this.c;this.b;
this.y;this.z;this.target
this.duration; this.timer_o;
this.active=false;
this.use = function(y,z){};
this.un = function(x,y,z){};
this.mods = function(){}
this.onGive=function(){};
this.onRemove=function(x){};
this.onClick=function(){}
}
effect.test1 = new Effect()
effect.test1.name='Beast killer';
effect.test1.desc='Attacks against beast type creatures are 30% more effective';
effect.test1.type = 1;
effect.test1.use = function(){
if(global.current_m.type===1) {you.str = Math.round(you.str*1.3);}
}
effect.bk1 = new Effect()
effect.bk1.type = 1;
effect.bk1.use = function(){
if(global.current_m.type===1) {you.dmlt+=.2}
}