forked from Mudlet/Mudlet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path3k-mapper.xml
2906 lines (2842 loc) · 106 KB
/
3k-mapper.xml
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
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE MudletPackage>
<MudletPackage version="1.0">
<TriggerPackage>
<TriggerGroup isActive="yes" isFolder="yes" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>3k Mapper</name>
<script></script>
<triggerType>0</triggerType>
<conditonLineDelta>99</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName>3k Mapper</packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList/>
<regexCodePropertyList/>
<TriggerGroup isActive="yes" isFolder="yes" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>3k Mapper</name>
<script></script>
<triggerType>0</triggerType>
<conditonLineDelta>0</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList/>
<regexCodePropertyList/>
<TriggerGroup isActive="yes" isFolder="yes" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>3k Room Description</name>
<script></script>
<triggerType>0</triggerType>
<conditonLineDelta>0</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList/>
<regexCodePropertyList/>
<Trigger isActive="no" isFolder="no" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>roomexits</name>
<script>tmap.exits=""
tmap.roomdesc=string.trim(tmap.roomdesc)
if (matches[6]) then
if (string.find(matches[6],"§")) then
local match = matches[6]
tmap.exits=string.trim(string.sub(match,1,string.find(match,"§")-2))
disableTrigger("multipleRoomExits")
tmap:processExits(tmap.exits)
else
tmap.exits=matches[6]
enableTrigger("multipleRoomExits")
end
else
tmap:processExits(nil)
end
disableTrigger("roomdescription")
disableTrigger("roomexits")</script>
<triggerType>0</triggerType>
<conditonLineDelta>1</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList>
<string>(((\s+There (are|is) \w+ obvious exit.?:) (.+))|No obvious exits.¡?)</string>
</regexCodeList>
<regexCodePropertyList>
<integer>1</integer>
</regexCodePropertyList>
</Trigger>
<Trigger isActive="no" isFolder="no" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="yes" isColorTriggerFg="yes" isColorTriggerBg="yes">
<name>roomdescription</name>
<script>if matches[1] then
tmap.roomdesc = tmap.roomdesc..matches[1].."\n"
end
setTriggerStayOpen("roomdescription", 1)</script>
<triggerType>0</triggerType>
<conditonLineDelta>1</conditonLineDelta>
<mStayOpen>1</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#808000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList>
<string>FG8BG2</string>
<string>^(.+)$</string>
</regexCodeList>
<regexCodePropertyList>
<integer>6</integer>
<integer>1</integer>
</regexCodePropertyList>
</Trigger>
<Trigger isActive="yes" isFolder="no" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="yes" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="yes" isColorTriggerFg="yes" isColorTriggerBg="yes">
<name>roomname</name>
<script>local match = matches[2]
tmap.compassSpace = string.len(matches[2])
tmap.roomname = string.trim(matches[2])
tmap.roomdesc = ""
if tmap.mapfollow and tmap.findme == nil and tmap.pWimpy == nil and tmap.searchMode == nil
and tmap.updateRoom == nil then
tmap:onFollow(nil)
elseif tmap:mapon() or tmap.findme or tmap.pWimpy or tmap.searchMode or tmap.updateRoom then
enableTrigger("spacer")
enableTrigger("roomexits")
end
if roomContents then
roomContents["objects"] = {}
end
tmap.roomEntered = true
selectString("¡",1)
replace("")</script>
<triggerType>0</triggerType>
<conditonLineDelta>11</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#00fff7</mFgColor>
<mBgColor>#000000</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#00ff00</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList>
<string>3?s?>?`?(.+)(\s+)?¡</string>
</regexCodeList>
<regexCodePropertyList>
<integer>1</integer>
</regexCodePropertyList>
</Trigger>
<Trigger isActive="no" isFolder="no" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>spacer</name>
<script>enableTrigger("roomdescription")
disableTrigger("spacer")</script>
<triggerType>0</triggerType>
<conditonLineDelta>3</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList>
<string>^$</string>
</regexCodeList>
<regexCodePropertyList>
<integer>1</integer>
</regexCodePropertyList>
</Trigger>
<Trigger isActive="no" isFolder="no" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>multipleRoomExits</name>
<script>local match = matches[2]
if (match and string.find(match,"§")) then
tmap.exits=tmap.exits..string.trim(string.sub(match,1,string.find(match,"§")-2))
disableTrigger("multipleRoomExits")
tmap:processExits(tmap.exits)
else
tmap.exits=tmap.exits..match
end</script>
<triggerType>0</triggerType>
<conditonLineDelta>0</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList>
<string>[\s]{10,}(.*)</string>
</regexCodeList>
<regexCodePropertyList>
<integer>1</integer>
</regexCodePropertyList>
</Trigger>
</TriggerGroup>
<Trigger isActive="yes" isFolder="no" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>WimpyNoDir</name>
<script>tmap.pWimpy=1
send("brief map")
send("look")</script>
<triggerType>0</triggerType>
<conditonLineDelta>0</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList>
<string>Your legs run away with you!</string>
</regexCodeList>
<regexCodePropertyList>
<integer>0</integer>
</regexCodePropertyList>
</Trigger>
<Trigger isActive="yes" isFolder="no" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>Can't go trigger</name>
<script>table.remove(tmap.comTable,1)</script>
<triggerType>0</triggerType>
<conditonLineDelta>0</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList>
<string>You cannot go (west|east|south|north|up|down|northeast|northwest|southwest|southeast).$</string>
<string>You cannot get it up.$</string>
</regexCodeList>
<regexCodePropertyList>
<integer>1</integer>
<integer>1</integer>
</regexCodePropertyList>
</Trigger>
<Trigger isActive="yes" isFolder="no" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>Too dark</name>
<script>tmap.roomEntered = true
if tmap:mapon() then
tmap:echo("\nMAPPING IN THE DARK. TURN ON A LIGHT!!!!!!!!\n")
tmap.exits=""
tmap.roomdesc=""
tmap.roomname="A Dark Room"
tmap:processExits(nil)
elseif tmap.mapfollow and tmap.findme == nil then
tmap:onFollow(nil)
end</script>
<triggerType>0</triggerType>
<conditonLineDelta>99</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList>
<string>It is too dark</string>
</regexCodeList>
<regexCodePropertyList>
<integer>1</integer>
</regexCodePropertyList>
</Trigger>
<Trigger isActive="yes" isFolder="no" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>Follower</name>
<script>local player = matches[2]
if player == tmap.leader then
tmap:onFollow(matches[3])
end</script>
<triggerType>0</triggerType>
<conditonLineDelta>99</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList>
<string>(.+) leaves (.+).</string>
</regexCodeList>
<regexCodePropertyList>
<integer>1</integer>
</regexCodePropertyList>
</Trigger>
<Trigger isActive="yes" isFolder="no" isTempTrigger="no" isMultiline="no" isPerlSlashGOption="no" isColorizerTrigger="no" isFilterTrigger="no" isSoundTrigger="no" isColorTrigger="no" isColorTriggerFg="no" isColorTriggerBg="no">
<name>Wimpy</name>
<script>tmap:onFollow(matches[2])</script>
<triggerType>0</triggerType>
<conditonLineDelta>99</conditonLineDelta>
<mStayOpen>0</mStayOpen>
<mCommand></mCommand>
<packageName></packageName>
<mFgColor>#ff0000</mFgColor>
<mBgColor>#ffff00</mBgColor>
<mSoundFile></mSoundFile>
<colorTriggerFgColor>#000000</colorTriggerFgColor>
<colorTriggerBgColor>#000000</colorTriggerBgColor>
<regexCodeList>
<string>Your legs run away with you (.+).</string>
</regexCodeList>
<regexCodePropertyList>
<integer>1</integer>
</regexCodePropertyList>
</Trigger>
</TriggerGroup>
</TriggerGroup>
</TriggerPackage>
<TimerPackage/>
<AliasPackage>
<AliasGroup isActive="yes" isFolder="yes">
<name>3k Mapper</name>
<script></script>
<command></command>
<packageName>3k Mapper</packageName>
<regex></regex>
<AliasGroup isActive="yes" isFolder="yes">
<name>3k Mapper</name>
<script></script>
<command></command>
<packageName></packageName>
<regex></regex>
<Alias isActive="yes" isFolder="no">
<name>Purge exit queue</name>
<script>--[[This will clear the direction queue]]
tmap.comTable = {}
tmap.roomsToWalk = nil
tmap.mapspecial = nil</script>
<command></command>
<packageName></packageName>
<regex>^tmap dirclear$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>firstroom</name>
<script>tmap.firstRoom = true
tmap.lastId = nil
tmap.comTable = {}
send("brief map")
tmap:echo("<red>Now enter a cardinal direction to start the mapping process.<reset>")
if not tmap:mapon() then
tmap:echo("<red>Mapping is disabled, use '<cyan>tmap mapon<red>' to enable.<reset>")
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap firstroom$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Set Location</name>
<script>tmap.roomsToWalk = nil
tmap.speedWalking = 0
local isRoom = getRoomName(matches[2])
if not isRoom then
tmap:echo("can't find room")
else
tmap:onPlayerMove(matches[2])
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap setroom (\d+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Room walker</name>
<script>--[[This will attempt to walk to a given room name or area. For instance
if you have an area named 'Diablo 2' and you type tmap walk diablo, it will
bring you to diablo 2]]
local entry = matches[2]
if tonumber(entry) then
entry = tonumber(entry)
gotoRoom(entry)
tmap:onPlayerMove(entry)
elseif tmap.mwalkList and tmap.mwalkList[entry] then
gotoRoom(tmap.mwalkList[entry])
else
--it's a word, look for it in areas and walk to area
local tstring = string.lower(entry)
local atable = getAreaTable()
local exactmatch = {}
local pareas = {}
local eiter = 1
local piter=1
for i,v in pairs(atable) do
local area = string.lower(i)
if string.match(area, "^"..tstring.."$") then
exactmatch[eiter] = {v,i}
eiter = eiter+1
end
if string.find(area, tstring) then
pareas[piter] = {v,i}
piter = piter+1
end
end
if #exactmatch == 1 then
local rooms = getAreaRooms(exactmatch[1][1])
gotoRoom(rooms[0])
elseif #pareas == 1 then
local rooms = getAreaRooms(pareas[1][1])
gotoRoom(rooms[0])
else
tmap:echo("\n<red> Multiple Matching Areas Found. Click desired destination")
for i,v in pairs(pareas) do
local room = getAreaRooms(v[1])[0]
if room then
echoLink(v[2].." ("..getRoomName(room)..")\n", [[gotoRoom(]]..tostring(room)..[[)]],"")
end
end
tmap:echo("")
end
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap walk (.+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Map toggle</name>
<script>if tmap.mapstatus then
tmap.mapstatus = nil
tmap.tMapper = nil
tmap:echo("\n MAPPER DISABLED")
else
if (matches[2]) then
tmap.mapstatus = 1
tmap.mapfollow = nil
tmap.tMapper = 1
send("brief map")
tmap:echo("\n TEMPORARY MAPPED ENABLED")
else
tmap.mapstatus = 1
tmap.mapfollow = nil
send("brief map")
tmap:echo("\n MAPPER ENABLED")
end
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap mapon\s?(.+)?$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Show Exits</name>
<script>--show room exits
local exits = getRoomExits(tmap.lastId)
echo("Normal Exits:\n")
for k,v in pairs(exits) do
echo(" " .. k .. " -> " .. v .. "\n")
end
tmap:echo("Special Exits:\n")
tmap:echo(getSpecialExitsSwap(tmap.lastId))</script>
<command></command>
<packageName></packageName>
<regex>^tmap showexits$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Set Room Size</name>
<script>--sets the size of the room
setRoomSize(matches[2])
tmap:onPlayerMove(matches[2])</script>
<command></command>
<packageName></packageName>
<regex>^tmap setroomsize (\d+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Mouse Set Location</name>
<script>tmap.mouseLocation = 1
--makes it so instead of speedwalking you are set to the location you click on</script>
<command></command>
<packageName></packageName>
<regex>^tmap setloc$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Delete Room</name>
<script>--adds rooms to a delete list, use doDelete to actually delete
if tmap.roomsToDelete == nil then
tmap.roomsToDelete = {}
end
local room
if matches[2] == "clear" then
tmap.roomsToDelete = {}
tmap:echo("deletion list cleared")
end
if matches[2] then
room = tonumber(matches[2])
else
room = tmap.lastId
end
if tmap.roomsToDelete[room] then
tmap.roomsToDelete[room] = false
tmap:echo(room.." removed from list")
else
tmap.roomsToDelete[room] = true
tmap:echo(room.." added to list")
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap delroom\s?(.+)?$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Map Follow Toggle</name>
<script>if tmap.mapfollow then
tmap.mapfollow = nil
tmap:echo("\n MAPPER FOLLOWING DISABLED")
else
tmap.mapfollow = 1
tmap.mapstatus = nil
tmap:echo("\n MAPPER FOLLOWING ENABLED")
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap follow$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Map Special Exit</name>
<script>tmap.specialexitcommand = matches[2]
tmap.specialdirection = matches[3]
if tmap.shortToLong[tmap.specialdirection] then
tmap.specialdirection = tmap.shortToLong[tmap.specialdirection]
end
tmap.mapspecial = 1
send(tmap.specialexitcommand)</script>
<command></command>
<packageName></packageName>
<regex>^>([^>]+)>(\w+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Find Me</name>
<script>--finds you
tmap.comTable = {}
tmap.roomsToWalk = nil
if matches[2] then
tmap.findme=nil
return
end
send("brief map")
send("look")
tmap.findme=1
if tmap.mapstatus then
tmap.mapstatus = nil
tmap.tMapper = nil
tmap:echo("\n MAPPER DISABLED")
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap findme\s?(\w+)?$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Stop Special Exits</name>
<script>--[[This will stop mapping special exits if you tried to map one]]
tmap.mapspecial = nil</script>
<command></command>
<packageName></packageName>
<regex>^tmap stopspecial$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>No HM Portals</name>
<script>--set the portals to your map to enable this
local forbidden = {[137]=999, [5860]=999, [588]=999, [1081]=999, [1361]=999, [33798]=999}
if matches[2] then
tmap:echo("<red>HM Portals On")
else
tmap:echo("<red>HM Portals Off")
end
for i,v in pairs(forbidden) do
if matches[2] then
setRoomWeight(i,0)
else
setRoomWeight(i,v)
end
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap portalsoff(.+)?</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Set Room Cost</name>
<script>--cost of entering a room
setRoomWeight(tmap.lastId, tonumber(matches[2]))</script>
<command></command>
<packageName></packageName>
<regex>^tmap setrcost (\d+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Show Room Script</name>
<script>--shows the commands we send when we enter this room
tmap:echo(tmap:getRoomScript(tmap.lastId))</script>
<command></command>
<packageName></packageName>
<regex>^tmap showscript$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Delete Selected Rooms</name>
<script>for i,v in pairs(tmap.roomsToDelete) do
if v == tmap.lastId then
tmap:echo("<red> Unable to delete the room you are in.")
else
tmap:doRoomDelete(i)
end
end
tmap.roomsToDelete = {}</script>
<command></command>
<packageName></packageName>
<regex>^tmap doDelete$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Color Room</name>
<script>if tmap.colorMappings[matches[2]] then
setRoomEnv(tmap.lastId, tmap.colorMappings[matches[2]])
centerview(tmap.lastId)
else
tmap:echo("\n<red>Cannot find color mapping. Available colors:")
for i,v in pairs(tmap.colorMappings) do
tmap:echo(i)
end
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap croom (\w+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>show color</name>
<script>display(getCustomEnvColorTable())</script>
<command></command>
<packageName></packageName>
<regex>^tmap scolor$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Show room weight</name>
<script>display(getRoomWeight(tmap.lastId))</script>
<command></command>
<packageName></packageName>
<regex>^tmap sweight$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Block room</name>
<script>setRoomWeight(tmap.lastId, 99)</script>
<command></command>
<packageName></packageName>
<regex>^tmap broom$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Move Player on Map</name>
<script>--moves a given direction of the map
tmap:onFollow(matches[2])</script>
<command></command>
<packageName></packageName>
<regex>^tmap move (.+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Move room to new area</name>
<script>--moves the room you are currently in to a new area
local Name = matches[2]
--find the highest current area id
local areas = getAreaTableSwap()
local zoneId = 0
for i,v in pairs(areas) do
if i > zoneId then
zoneId = i
end
end
zoneId = zoneId+1
setAreaName(zoneId, Name)
setRoomArea( tmap.lastId, zoneId )
local linked = {}
for i,v in pairs(tmap:getAllExits(tmap.lastId)) do
tmap:roomLabel(tostring(v).." "..Name)
local toArea = getRoomAreaName(getRoomArea(v))
if not linked[toArea] then
tmap:roomLabel(tmap.lastId.." n 0,1,0 "..toArea)
linked[toArea] = true
end
end
tmap:onPlayerMove(tmap.lastId)</script>
<command></command>
<packageName></packageName>
<regex>^tmap movenewarea (.*)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>move room to existing area</name>
<script>--moves room you are in to a new area
local Name = matches[2]
local areas = getAreaTable()
for i,v in pairs(areas) do
if i == Name then
zoneId = v
end
end
setRoomArea( tmap.lastId, zoneId )
tmap.UserArea=zoneId
centerview(tmap.lastId)</script>
<command></command>
<packageName></packageName>
<regex>^tmap movetoarea\s(.*)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Setup Mapper Ansi</name>
<script>sendSocket("aset room_short higreen\n")
sendSocket("aset room_short_suff reset+¡\n")
sendSocket("aset room_long brown\n")
sendSocket("aset room_exits yellow\n")
sendSocket("aset room_exits_suff reset+§\n")</script>
<command></command>
<packageName></packageName>
<regex>^tmap mapSetup$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Delete rooms from an entire area</name>
<script>--deletes all rooms in an area
for i,v in pairs(getAreaTable()) do
if i==matches[2] then
for j,k in pairs(getAreaRooms(v)) do
if (k == tmap.lastId) then
tmap:echo("<red>Unable to delete room if you are currently in it.")
else
deleteRoom(k)
end
end
end
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap clearArea\s(.*)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Make a brand new area</name>
<script>local Name = matches[2]
--find the highest current area id
local areas = getAreaTableSwap()
local zoneId = 0
for i,v in pairs(areas) do
if i > zoneId then
zoneId = i
end
end
zoneId = zoneId+1
setAreaName(zoneId, Name)
tmap.UserArea=zoneId
tmap.lastId=nil
tmap:echo("To create a new room, type 'tmap firstroom' and move")</script>
<command></command>
<packageName></packageName>
<regex>^tmap newarea\s(.*)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Add Favorite</name>
<script>--Adds a favorite in your current room.
--If you enter a string like: addFav Shops:Cancer's Shop it will add a new favorite
--under the Shops label
local favs = searchRoomUserData("favorite", "")
local entry = matches[2]
local parent = nil
local name = entry
if (string.find(entry,":")) then
parent = string.match(entry,"[^:]+")
name = string.match(entry,":(.+)")
end
local highestFav = 0
for i,v in pairs(favs) do
local sStart = string.find(v,"|||")
if sStart then
local favId = tonumber(string.match(string.sub(v,sStart+3,-1),"(%d+)"))
if favId >= highestFav then
highestFav = favId+1
end
local fName = string.sub(v, 1, sStart-1)
if parent and (fName == parent) then
parent = favId
end
end
end
if not parent then
parent = -1
end
if not tonumber(parent) then
return
end
tmap:echo("adding "..name.."under "..parent)
--display(name.."|||"..highestFav.."|||"..tmap.lastId.."|||"..parent)
setRoomUserData(tmap.lastId, "favorite", name.."|||"..tmap.highestFav.."|||"..tmap.lastId.."|||"..parent)
setupFavorites()</script>
<command></command>
<packageName></packageName>
<regex>^tmap addFav\s(.*)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>search Mode</name>
<script>--automagicvally finds you when you walk around
if matches[2] then
tmap.searchMode=nil
return
end
send("brief map")
tmap.searchMode = true
tmap.searchCan = {}</script>
<command></command>
<packageName></packageName>
<regex>^tmap searchMode\s?(.+)?$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>show room scripts</name>
<script>display(getRoomUserData( tmap.lastId, "script"))
</script>
<command></command>
<packageName></packageName>
<regex>^tmap showScripts$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>set room script</name>
<script>tmap:echo("script for:"..tmap.lastId.." set to")
tmap:echo(matches[2])
setRoomUserData( tmap.lastId, "script", matches[2])</script>
<command></command>
<packageName></packageName>
<regex>^tmap setScript (.*)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>clear room script</name>
<script>setRoomUserData( tmap.lastId, "script", "")</script>
<command></command>
<packageName></packageName>
<regex>^tmap clearScript$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Set room lua script</name>
<script>display("lua script for:"..tmap.lastId.." set to")
display(matches[2])
setRoomUserData(tmap.lastId, "luascript", matches[2])</script>
<command></command>
<packageName></packageName>
<regex>^tmap luascript (.+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Add Exit Script</name>
<script>display("exit script for:"..matches[2].."set to")
display(matches[3])
setRoomUserData(tmap.lastId, "exitScript"..matches[2], matches[3])</script>
<command></command>
<packageName></packageName>
<regex>^tmap exitscript \"(.+)\" (.+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Show Room Lua Scripts</name>
<script>display(getRoomUserData(tmap.lastId, "luascript"))
</script>
<command></command>
<packageName></packageName>
<regex>^tmap showluascripts$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Clear room lua script</name>
<script>setRoomUserData(tmap.lastId, "luascript", "")</script>
<command></command>
<packageName></packageName>
<regex>^tmap clearluascript$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>show exit scripts</name>
<script>for i,v in pairs(tmap:getAllExits(tmap.lastId)) do
tmap:echo(i..":"..getRoomUserData(tmap.lastId, "exitScript"..i).."\n")
end</script>
<command></command>
<packageName></packageName>
<regex>^tmap showescript$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Update Room Description</name>
<script>--updates a room decription
tmap.updateRoom=true
send("brief map")
send("look")</script>
<command></command>
<packageName></packageName>
<regex>^tmap updateRoom$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Delete Temporary Rooms</name>
<script>local rooms = searchRoomUserData("temporary", 1)
for i,v in pairs(rooms) do
deleteRoom(i)
end
updateMap()</script>
<command></command>
<packageName></packageName>
<regex>^tmap delTemp$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Player Follow</name>
<script>--sets the person you are following
tmap.leader = matches[2]</script>
<command></command>
<packageName></packageName>
<regex>^tmap follow (.+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Show Room Info</name>
<script>tmap:echo("<yellow>Room Name")
tmap:echo("<cyan>"..getRoomName(tmap.lastId))
tmap:echo("<yellow>Room Desc")
tmap:echo("<cyan>"..getRoomUserData(tmap.lastId, "description"))
tmap:echo("")
local exits = tmap:getAllExits(tmap.lastId)
local exitStr = ""
for i,v in pairs(exits) do
exitStr = exitStr.."<reset>".."<cyan>"..i..", "
end
tmap:echo("<yellow>Exits: "..string.sub(exitStr,1,-3))
tmap:echo("")
tmap:echo("<yellow>Commands On Entering Room:")
tmap:echo("<cyan>"..getRoomUserData( tmap.lastId, "script"))
tmap:echo("<yellow>Lua script on Entering Room:")
tmap:echo("<cyan>"..getRoomUserData(tmap.lastId, "luascript"))
tmap:echo("<yellow>Room Exit Scripts:")
exitStr = ""
for i,v in pairs(exits) do
local script = getRoomUserData(tmap.lastId, "exitScript"..i)
if script ~= "" then
exitStr = exitStr.."<yellow>"..i.."<reset>:<cyan>"..script.."\n"
end
end
tmap:echo(exitStr)</script>
<command></command>
<packageName></packageName>
<regex>^tmap roominfo$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>General Help</name>
<script>tmap:echo("========== 3Scapes Mapper (and 3k too) ==========")
tmap:echo("All commands in the mapper are prepended with")
tmap:echo("'<red>tmap<reset>'. To get started, you need to setup the ")
tmap:echo("right ansi, which can be accomplished by '<red>tmap ")
tmap:echo("<red>mapSetup<reset>'.")
tmap:echo("")
tmap:echo("To get started, we need to make a new area, to do")
tmap:echo("this type '<red>tmap newarea areaname<reset>'. Then we can ")
tmap:echo("start mapping by typing '<red>tmap firstroom<reset>' and ")
tmap:echo("going in a direction such as east. To toggle ")
tmap:echo("mapping type '<red>tmap mapon<reset>'. You can also tag ")
tmap:echo("rooms as tempoary by using '<red>tmap mapon temp<reset>'.")
tmap:echo("This is useful in places like D2 which change. You can also type ")
tmap:echo("'<red>tmap follow<reset>' to turn off mapping and enter follow ")
tmap:echo("mode. For special exits such as up/down. You can ")
tmap:echo("use the syntax: <red>>special exit>direction<reset>, for instance ")
tmap:echo("<red>>in>east<reset> will create a special exit to a room and place ")
tmap:echo("that room east of your current position. <red>>out>west<reset> ")
tmap:echo("will complete the link. To move the room you are currently in to ")
tmap:echo("a new area, use <red>tmap movenewarea areaname<reset>.")
tmap:echo("")
tmap:echo("There are a ton of aliases you can use, which you can find in the ")
tmap:echo("3K Mapper folder. Some useful ones you might need(all these are ")
tmap:echo("prepended with tmap): '<red>findme<reset>', '<red>dirclear<reset>',")
tmap:echo("'<red>setroom xxx<reset>', '<red>roominfo<reset>', '<red>follow<reset>.")</script>
<command></command>
<packageName></packageName>
<regex>^tmap$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Room exit trigger setup</name>
<script>--this is more or less a shortcut for the common use of an exit script:
local tpattern = [["]]..matches[3]..[["]]
setRoomUserData(tmap.lastId, "exitScript"..matches[2], "tempTrigger("..tpattern..", [[tmap:onFollow(nil)]],true)")</script>
<command></command>
<packageName></packageName>
<regex>^tmap automove "(.+)" (.+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>clear room exit script</name>
<script>setRoomUserData(tmap.lastId, "exitScript"..matches[2], "")</script>
<command></command>
<packageName></packageName>
<regex>^tmap clearexit (.+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Pause speedwalk</name>
<script>setRoomUserData(tmap.lastId, "exitScript"..matches[2], "tmap.moveStop=1;tempTrigger("..matches[3]..", [[tmap.moveStop=nil;speedWalkPath = tmap.roomsToWalk;doSpeedWalk()]],true)")</script>
<command></command>
<packageName></packageName>
<regex>^tmap pauseUntil "(.+)" (.+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Create a looping exit</name>
<script>local dir = tmap.getDirNum(matches[2])
if not dir then
tmap:echo("<red>Can't find the direction "..matches[2])
end
setExit(tmap.lastId, tmap.lastId, dir)</script>
<command></command>
<packageName></packageName>
<regex>^tmap loopexit (.+)$</regex>
</Alias>
<Alias isActive="yes" isFolder="no">
<name>Move a label</name>
<script>if not matches[2] then
tmap:echo("Syntax: tmap movelabel <labelnum> <direction> <magnitude>")
tmap:echo("If there is only one label in a room, labelnum is optional.")
tmap:echo("Magnitude defaults to '1'.")
tmap:showRoomLabels(0)
return
end