-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathWorld.py
2337 lines (2326 loc) · 59.4 KB
/
World.py
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
# -*- coding: utf-8 -*-
import os
import string
import math
import zlib
import sys
import time
from colors import *
from struct import *
from OpCodes import *
from MovementFlags import *
PLAYER = 0
GAMEOBJECT = 1
NPC = 2
UPDATETYPE_VALUES = 0
UPDATETYPE_MOVEMENT = 1
UPDATETYPE_CREATE_OBJECT = 2
UPDATETYPE_CREATE_OBJECT2 = 3
UPDATETYPE_OUT_OF_RANGE_OBJECTS = 4
UPDATETYPE_NEAR_OBJECTS = 5
UPDATEFLAG_NONE = 0x00
UPDATEFLAG_SELF = 0x01
UPDATEFLAG_TRANSPORT = 0x02
UPDATEFLAG_FULLGUID = 0x04
UPDATEFLAG_LOWGUID = 0x08
UPDATEFLAG_HIGHGUID = 0x10
UPDATEFLAG_LIVING = 0x20
UPDATEFLAG_HASPOSITION = 0x40
MOVEMENTFLAG_NONE = 0x00000000
TYPEID_OBJECT = 0
TYPEID_ITEM = 1
TYPEID_CONTAINER = 2
TYPEID_UNIT = 3
TYPEID_PLAYER = 4
TYPEID_GAMEOBJECT = 5
TYPEID_DYNAMICOBJECT = 6
TYPEID_CORPSE = 7
TYPEID_AIGROUP = 8
TYPEID_AREATRIGGER = 9
sizes = {0: 2, 2: 1, 3: 1, 4: 1, 5: 1, 6: 2, 8: 2, 9: 1, 10: 1, 11: 1, 12: 1, 13: 1, 14: 1, 15: 19, 16: 1, 17: 1, 18: 1, 19: 1, 20: 1, 21: 1, 22: 1, 23: 1, 24: 1, 25: 1, 26: 1, 27: 1, 28: 1, 29: 1, 30: 1, 31: 1, 32: 1, 33: 1, 34: 1, 35: 1, 36: 1, 37: 1, 38: 1, 39: 1, 40: 6, 46: 1, 47: 1, 48: 56, 55: 1, 56: 1, 57: 1, 58: 1, 59: 1, 60: 1, 61: 1, 62: 72, 104: 14, 118: 14, 132: 14, 146: 1, 147: 2, 149: 1, 150: 1, 151: 1, 152: 1, 153: 1, 154: 1, 155: 1, 156: 1, 157: 1, 158: 1, 159: 1, 160: 1, 161: 1, 162: 1, 163: 1, 164: 1, 165: 1, 166: 1, 167: 1, 168: 1, 169: 1, 170: 1, 171: 1, 172: 1, 173: 1, 174: 1, 175: 1, 176: 1, 177: 1, 178: 1, 179: 1, 180: 1, 181: 1, 182: 1, 183: 1, 184: 1, 185: 1, 186: 7, 193: 7, 200: 7, 207: 1, 208: 1, 209: 1, 210: 1, 211: 1, 212: 1, 213: 1, 214: 1, 215: 1, 216: 1, 217: 1, 218: 7, 225: 7, 232: 1, 233: 1, 234: 2, 236: 1, 237: 1, 238: 1, 239: 1, 240: 1, 241: 1, 242: 1, 243: 1, 244: 1, 245: 1, 246: 1, 247: 1, 248: 1, 249: 1, 250: 1, 251: 1, 252: 1, 253: 1, 254: 1, 255: 1, 256: 1, 257: 1, 258: 1, 259: 1, 260: 1, 261: 1, 262: 1, 263: 1, 264: 1, 265: 1, 266: 1, 267: 1, 268: 1, 269: 1, 270: 1, 271: 1, 272: 1, 273: 1, 274: 1, 275: 1, 276: 1, 277: 1, 278: 1, 279: 1, 280: 1, 281: 1, 282: 1, 283: 1, 284: 1, 285: 1, 286: 1, 287: 1, 288: 1, 289: 1, 290: 1, 291: 1, 292: 1, 293: 1, 294: 1, 295: 1, 296: 1, 297: 1, 298: 1, 299: 1, 300: 1, 301: 1, 302: 1, 303: 1, 304: 1, 305: 1, 306: 1, 307: 1, 308: 1, 309: 1, 310: 1, 311: 1, 312: 1, 313: 1, 314: 1, 315: 1, 316: 1, 317: 1, 318: 1, 319: 1, 320: 1, 321: 1, 322: 1, 323: 1, 324: 1, 325: 1, 326: 1, 327: 1, 328: 1, 329: 1, 330: 1, 331: 1, 332: 1, 333: 1, 334: 1, 335: 1, 336: 1, 337: 1, 338: 1, 339: 1, 340: 1, 341: 1, 342: 1, 343: 1, 344: 2, 346: 12, 358: 1, 359: 1, 360: 2, 362: 12, 374: 1, 375: 1, 376: 2, 378: 12, 390: 1, 391: 1, 392: 2, 394: 12, 406: 1, 407: 1, 408: 2, 410: 12, 422: 1, 423: 1, 424: 2, 426: 12, 438: 1, 439: 1, 440: 2, 442: 12, 454: 1, 455: 1, 456: 2, 458: 12, 470: 1, 471: 1, 472: 2, 474: 12, 486: 1, 487: 1, 488: 2, 490: 12, 502: 1, 503: 1, 504: 2, 506: 12, 518: 1, 519: 1, 520: 2, 522: 12, 534: 1, 535: 1, 536: 2, 538: 12, 550: 1, 551: 1, 552: 2, 554: 12, 566: 1, 567: 1, 568: 2, 570: 12, 582: 1, 583: 1, 584: 2, 586: 12, 598: 1, 599: 1, 600: 2, 602: 12, 614: 1, 615: 1, 616: 2, 618: 12, 630: 1, 631: 1, 632: 2, 634: 12, 646: 1, 647: 1, 648: 1, 649: 1, 650: 46, 696: 32, 728: 56, 784: 14, 798: 24, 822: 64, 886: 36, 922: 2, 924: 2, 926: 1, 927: 1, 928: 384, 1312: 1, 1313: 1, 1314: 1, 1315: 1, 1316: 1, 1317: 1, 1318: 1, 1319: 1, 1320: 1, 1321: 1, 1322: 1, 1323: 1, 1324: 7, 1331: 1, 1332: 128, 1460: 1, 1461: 1, 1462: 7, 1469: 7, 1476: 7, 1483: 1, 1484: 1, 1485: 1, 1486: 1, 1487: 1, 1488: 1, 1489: 1, 1490: 12, 1502: 12, 1514: 1, 1515: 1, 1516: 1, 1517: 1, 1518: 1, 1519: 1, 1520: 24, 1544: 18, 1562: 1, 1563: 1, 1564: 1, 1565: 1, 1566: 1, 1567: 25}
def unpackguid(data):
guid = 0
guidmark = ord(data[0])
j = 1
for i in range(0,8):
if guidmark & (1 << i):
bit = ord(data[j])
j += 1
guid |= bit << i*8;
return (guid,data[j:])
def unpackbignumber(data):
n = 0
i = 0
for c in data:
n += pow(16,i)*(ord(c)&0xF)
i+=1
n += pow(16,i)*((ord(c)>>4)&0xF)
i+=1
return n
def packbignumber(n,l=32):
s = ""
i = 0
while i < l:
x = n >> 8*i
s = s + chr(x&255)
i+=1
return s
def tobin(bn,blocks=-1):
s = ""
bits = int(math.log(bn,2)) if blocks == -1 else blocks*32
for i in range(0,bits+1):
s += str((bn >> (bits-i)) & 1)
return s
def parseoutofrangeobjblock(s_):
#print "Out of range objects"
guids = []
s = str(s_)
guidcount = unpack("I",s[:4])[0]
s = s[4:]
for i in range(0,guidcount):
s = s[1:]
guids.append(unpack("Q",s[:8])[0])
s = s[8:]
return guids,s
def parsemovementupdate(s_):
guid = 0
data = dict()
s = str(s_)
guid = unpack("Q",s[:8])[0]
s = s[8:]
flags = ord(s[0])
s = s[1:]
#print tobin(flags,1)
if (flags & UPDATEFLAG_LIVING ):
data["flags2"] = unpack("I",s[:4])[0]
s = s[4:]
s = s[1:]
data["time"] = unpack("I",s[:4])[0]
s = s[4:]
if flags & UPDATEFLAG_HASPOSITION:
x,y,z,o = unpack("ffff",s[:16])
s = s[16:]
data["pos"] = x,y,z,o
if "flags2" in data:
if data["flags2"] & MOVEMENTFLAG_ONTRANSPORT:
s = s[28:] # Sticazzi dei transport x ora
if data["flags2"] & (MOVEMENTFLAG_SWIMMING | MOVEMENTFLAG_FLYING2):
data["pitch"] = unpack("f",s[:4])[0]
s = s[4:]
data["falltime"] = unpack("I",s[:4])[0]
s = s[4:]
if data["flags2"] & MOVEMENTFLAG_JUMPING:
s = s[16:]
if data["flags2"] & MOVEMENTFLAG_SPLINE:
s = s[4:]
speeds = unpack("ffffffff",s[:4*8])
s = s[4*8:]
data["speeds"] = speeds
if flags & UPDATEFLAG_LOWGUID:
#print "Lowguid"
s = s[4:]
if flags & UPDATEFLAG_HIGHGUID:
#print "Highguid"
s = s[4:]
if flags & UPDATEFLAG_FULLGUID:
#print "Fullguid"
s = s[1:]
if flags & UPDATEFLAG_TRANSPORT:
#print "Transport"
s = s[4:]
#print "Movement: guid "+str(guid),data
return guid,data,s
def parsevaluesupdate(s_):
#print "Values update"
values = dict()
guid = 0
s = str(s_)
#print "%x" % ord(s[0])
s = s[1:]
guid = unpack("Q",s[:8])[0]
s = s[8:]
umblockcount = ord(s[0])
s = s[1:]
mask = unpackbignumber(s[:umblockcount<<2])
#print umblockcount<<2,tobin(mask,umblockcount)
s = s[umblockcount<<2:]
j = 0
for i in range(0,2000):
if (mask >> i) & 1:
values[i] = unpack("I",s[:4])[0]
s = s[4:]
return guid,values,s
def parsecreateobject(s_):
#print "Create: %x"%ord(s_[0])
s = str(s_)
s = s[1:]
guid = unpack("Q",s[:8])[0]
#print guid
s = s[8:]
typeid = ord(s[0])
#print "%x"%typeid
s = s[1:]
guid,data,s = parsemovementupdate(s_[1:9]+s)
guid,values,s = parsevaluesupdate(s_[:9]+s)
#print guid
return guid,typeid,data,values,s
objectnames = {TYPEID_AIGROUP : "<AI Group>" , TYPEID_AREATRIGGER : "<Area Trigger>" , TYPEID_CONTAINER : "<Container>", TYPEID_CORPSE : "<Corpse>", TYPEID_DYNAMICOBJECT : "<Dynamic Object>", TYPEID_GAMEOBJECT : "<GameObject>", TYPEID_ITEM : "<Item>" , TYPEID_OBJECT : "<Object>", TYPEID_PLAYER : "<Player>", TYPEID_UNIT : "<Unit>"}
def tofloat(iv):
data = pack("I",iv)
return unpack("f",data)[0]
def toint64(v1,v2):
data = pack("II",v1,v2)
return unpack("Q",data)[0]
class WorldObject:
def __init__(self,guid,t,x,y,z,o,name=""):
debug("Creazione di un %s con guid %i"%(objectnames[t],guid))
self.t = t
self.guid = guid
self.x = float(x)
self.y = float(y)
self.z = float(z)
self.o = float(o)
self.name = ""
self.values = dict()
def mergevalues(self,v):
for x in v:
self.values[x] = v[x]
def getplayerrangedcritpercentage(self):
if 1322 in self.values:
return tofloat(self.values[1322])
else:
return None
def getunitcreatedbyspell(self):
if 167 in self.values:
return self.values[167]
else:
return None
def getunitfieldpetnumber(self):
if 160 in self.values:
return self.values[160]
else:
return None
def getunitfieldattackpowermods(self):
a = []
for x in range(211,212):
if x in self.values:
a.append(x)
return a
def getplayervisibleitem6creator(self):
if 424 in self.values and 425 in self.values:
return toint64(self.values[424],self.values[425])
else:
return None
def getplayervisibleitem2properties(self):
a = []
for x in range(374,375):
if x in self.values:
a.append(x)
return a
def getunitmodcastspeed(self):
if 166 in self.values:
return tofloat(self.values[166])
else:
return None
def getplayernextlevelxp(self):
if 927 in self.values:
return self.values[927]
else:
return None
def getplayervisibleitem10pad(self):
if 503 in self.values:
return self.values[503]
else:
return None
def getplayercharacterpoints1(self):
if 1312 in self.values:
return self.values[1312]
else:
return None
def getplayercharacterpoints2(self):
if 1313 in self.values:
return self.values[1313]
else:
return None
def getplayerfieldkills(self):
a = []
for x in range(1514,1515):
if x in self.values:
a.append(x)
return a
def getunitfieldaura(self):
a = []
for x in range(48,104):
if x in self.values:
a.append(x)
return a
def getcorpsefieldfacing(self):
if 10 in self.values:
return tofloat(self.values[10])
else:
return None
def getitemfielditemtextid(self):
if 57 in self.values:
return self.values[57]
else:
return None
def getplayervisibleitem160(self):
a = []
for x in range(586,598):
if x in self.values:
a.append(x)
return a
def getunitdynamicflags(self):
if 164 in self.values:
return self.values[164]
else:
return None
def getunitfieldpersuaded(self):
if 18 in self.values:
return tofloat(self.values[18])
else:
return None
def getunitchannelspell(self):
if 165 in self.values:
return self.values[165]
else:
return None
def getplayervisibleitem120(self):
a = []
for x in range(522,534):
if x in self.values:
a.append(x)
return a
def getgameobjectpadding(self):
if 25 in self.values:
return self.values[25]
else:
return None
def getplayervisibleitem14properties(self):
a = []
for x in range(566,567):
if x in self.values:
a.append(x)
return a
def getunitfieldrangedattackpowermods(self):
a = []
for x in range(214,215):
if x in self.values:
a.append(x)
return a
def getplayervisibleitem140(self):
a = []
for x in range(554,566):
if x in self.values:
a.append(x)
return a
def getitemfieldduration(self):
a = []
for x in range(15,34):
if x in self.values:
a.append(x)
return a
def getplayervisibleitem5creator(self):
if 408 in self.values and 409 in self.values:
return toint64(self.values[408],self.values[409])
else:
return None
def getplayerquestlog241(self):
if 336 in self.values:
return self.values[336]
else:
return None
def getplayerquestlog242(self):
if 337 in self.values:
return self.values[337]
else:
return None
def getunitfieldcharmedby(self):
if 10 in self.values:
return tofloat(self.values[10])
else:
return None
def getplayerduelarbiter(self):
if 234 in self.values and 235 in self.values:
return toint64(self.values[234],self.values[235])
else:
return None
def getplayerquestlog224(self):
if 331 in self.values:
return self.values[331]
else:
return None
def getplayerquestlog222(self):
if 329 in self.values:
return self.values[329]
else:
return None
def getplayerquestlog223(self):
a = []
for x in range(330,331):
if x in self.values:
a.append(x)
return a
def getunitfielddisplayid(self):
if 152 in self.values:
return self.values[152]
else:
return None
def getcorpsefielditem(self):
a = []
for x in range(15,34):
if x in self.values:
a.append(x)
return a
def getplayervisibleitem18properties(self):
a = []
for x in range(630,631):
if x in self.values:
a.append(x)
return a
def getunittrainingpoints(self):
a = []
for x in range(170,171):
if x in self.values:
a.append(x)
return a
def getplayerfieldbytes(self):
a = []
for x in range(1486,1487):
if x in self.values:
a.append(x)
return a
def getdynamicobjectcaster(self):
if 6 in self.values and 7 in self.values:
return toint64(self.values[6],self.values[7])
else:
return None
def getdynamicobjectradius(self):
if 10 in self.values:
return tofloat(self.values[10])
else:
return None
def getobjectfieldscalex(self):
if 4 in self.values:
return tofloat(self.values[4])
else:
return None
def getunitfieldnativedisplayid(self):
if 153 in self.values:
return self.values[153]
else:
return None
def getplayervisibleitem100(self):
a = []
for x in range(490,502):
if x in self.values:
a.append(x)
return a
def getplayerquestlog201(self):
if 320 in self.values:
return self.values[320]
else:
return None
def getplayerquestlog202(self):
if 321 in self.values:
return self.values[321]
else:
return None
def getplayerquestlog203(self):
a = []
for x in range(322,323):
if x in self.values:
a.append(x)
return a
def getplayerquestlog204(self):
if 323 in self.values:
return self.values[323]
else:
return None
def getunitfieldpetnextlevelexp(self):
if 163 in self.values:
return self.values[163]
else:
return None
def getplayerfieldwatchedfactionindex(self):
if 1519 in self.values:
return self.values[1519]
else:
return None
def getitemfieldowner(self):
if 6 in self.values and 7 in self.values:
return toint64(self.values[6],self.values[7])
else:
return None
def getcorpsefielddynamicflags(self):
if 38 in self.values:
return self.values[38]
else:
return None
def getgameobjectdisplayid(self):
if 8 in self.values and 9 in self.values:
return toint64(self.values[8],self.values[9])
else:
return None
def getplayerquestlog93(self):
a = []
for x in range(278,279):
if x in self.values:
a.append(x)
return a
def getplayerreststateexperience(self):
if 1460 in self.values:
return self.values[1460]
else:
return None
def getdynamicobjectposz(self):
if 13 in self.values:
return tofloat(self.values[13])
else:
return None
def getdynamicobjectposy(self):
if 12 in self.values:
return tofloat(self.values[12])
else:
return None
def getdynamicobjectposx(self):
if 11 in self.values:
return tofloat(self.values[11])
else:
return None
def getplayervisibleitem1creator(self):
if 344 in self.values and 345 in self.values:
return toint64(self.values[344],self.values[345])
else:
return None
def getdynamicobjectfacing(self):
if 14 in self.values:
return self.values[14]
else:
return None
def getplayervisibleitem4creator(self):
if 392 in self.values and 393 in self.values:
return toint64(self.values[392],self.values[393])
else:
return None
def getplayerfieldvanitypetslot1(self):
a = []
for x in range(886,922):
if x in self.values:
a.append(x)
return a
def getgameobjectanimprogress(self):
if 24 in self.values:
return self.values[24]
else:
return None
def getplayerfieldmoddamagedoneneg(self):
a = []
for x in range(1469,1476):
if x in self.values:
a.append(x)
return a
def getunitfieldcharm(self):
if 6 in self.values and 7 in self.values:
return toint64(self.values[6],self.values[7])
else:
return None
def getgameobjectposy(self):
if 16 in self.values:
return tofloat(self.values[16])
else:
return None
def getgameobjectposx(self):
a = []
for x in range(15,34):
if x in self.values:
a.append(x)
return a
def getgameobjectposz(self):
if 17 in self.values:
return tofloat(self.values[17])
else:
return None
def getplayerfieldhonorcurrency(self):
if 1562 in self.values:
return self.values[1562]
else:
return None
def getgameobjectdynflags(self):
if 19 in self.values:
return self.values[19]
else:
return None
def getplayervisibleitem17properties(self):
a = []
for x in range(614,615):
if x in self.values:
a.append(x)
return a
def getplayerfieldmoddamagedonepct(self):
a = []
for x in range(1476,1483):
if x in self.values:
a.append(x)
return a
def getplayerfieldbuybacktimestamp1(self):
a = []
for x in range(1502,1514):
if x in self.values:
a.append(x)
return a
def getunitvirtualitemslotdisplay(self):
if 37 in self.values:
return self.values[37]
else:
return None
def getplayerguildtimestamp(self):
if 243 in self.values:
return self.values[243]
else:
return None
def getplayervisibleitem12creator(self):
if 520 in self.values and 521 in self.values:
return toint64(self.values[520],self.values[521])
else:
return None
def getunitfieldhealth(self):
if 22 in self.values:
return self.values[22]
else:
return None
def getunitfieldresistances(self):
a = []
for x in range(186,193):
if x in self.values:
a.append(x)
return a
def getplayerxp(self):
if 926 in self.values:
return self.values[926]
else:
return None
def getcontainerfieldnumslots(self):
if 60 in self.values:
return self.values[60]
else:
return None
def getplayervisibleitem4properties(self):
a = []
for x in range(406,407):
if x in self.values:
a.append(x)
return a
def getplayerfieldpackslot1(self):
a = []
for x in range(696,728):
if x in self.values:
a.append(x)
return a
def getplayerquestlog234(self):
if 335 in self.values:
return self.values[335]
else:
return None
def getplayerquestlog233(self):
a = []
for x in range(334,335):
if x in self.values:
a.append(x)
return a
def getplayerquestlog232(self):
if 333 in self.values:
return self.values[333]
else:
return None
def getplayerquestlog231(self):
if 332 in self.values:
return self.values[332]
else:
return None
def getplayerquestlog211(self):
if 324 in self.values:
return self.values[324]
else:
return None
def getplayerquestlog213(self):
a = []
for x in range(326,327):
if x in self.values:
a.append(x)
return a
def getplayerquestlog212(self):
if 325 in self.values:
return self.values[325]
else:
return None
def getplayerquestlog214(self):
if 327 in self.values:
return self.values[327]
else:
return None
def getplayerfieldbankbagslot1(self):
a = []
for x in range(784,798):
if x in self.values:
a.append(x)
return a
def getgameobjectartkit(self):
if 23 in self.values:
return self.values[23]
else:
return None
def getunitfieldpetnametimestamp(self):
if 161 in self.values:
return self.values[161]
else:
return None
def getplayercritpercentage(self):
if 1321 in self.values:
return tofloat(self.values[1321])
else:
return None
def getplayervisibleitem7creator(self):
if 440 in self.values and 441 in self.values:
return toint64(self.values[440],self.values[441])
else:
return None
def getplayerquestlog254(self):
if 343 in self.values:
return self.values[343]
else:
return None
def getplayerquestlog251(self):
if 340 in self.values:
return self.values[340]
else:
return None
def getplayerquestlog253(self):
a = []
for x in range(342,343):
if x in self.values:
a.append(x)
return a
def getplayerquestlog252(self):
if 341 in self.values:
return self.values[341]
else:
return None
def getplayervisibleitem11creator(self):
if 504 in self.values and 505 in self.values:
return toint64(self.values[504],self.values[505])
else:
return None
def getunitfieldcreatedby(self):
if 14 in self.values:
return self.values[14]
else:
return None
def getcontaineralignpad(self):
a = []
for x in range(61,62):
if x in self.values:
a.append(x)
return a
def getgameobjectflags(self):
if 9 in self.values:
return self.values[9]
else:
return None
def getplayervisibleitem18creator(self):
if 616 in self.values and 617 in self.values:
return toint64(self.values[616],self.values[617])
else:
return None
def getunitfieldmaxhealthmodifier(self):
if 232 in self.values:
return tofloat(self.values[232])
else:
return None
def getunitfieldpadding(self):
if 233 in self.values:
return self.values[233]
else:
return None
def getplayervisibleitem1properties(self):
a = []
for x in range(358,359):
if x in self.values:
a.append(x)
return a
def getgameobjectfaction(self):
if 20 in self.values:
return self.values[20]
else:
return None
def getunitfieldminoffhanddamage(self):
if 157 in self.values:
return tofloat(self.values[157])
else:
return None
def getplayerselfresspell(self):
if 1488 in self.values:
return self.values[1488]
else:
return None
def getunitfieldchannelobject(self):
if 20 in self.values:
return self.values[20]
else:
return None
def getplayervisibleitem17pad(self):
if 615 in self.values:
return self.values[615]
else:
return None
def getunitfieldrangedattackpowermultiplier(self):
if 215 in self.values:
return tofloat(self.values[215])
else:
return None
def getunitnpcemotestate(self):
if 169 in self.values:
return self.values[169]
else:
return None
def getitemfieldcreator(self):
if 10 in self.values:
return tofloat(self.values[10])
else:
return None
def getplayeroffhandcritpercentage(self):
if 1323 in self.values:
return tofloat(self.values[1323])
else:
return None
def getunitfieldposstat4(self):
if 180 in self.values:
return self.values[180]
else:
return None
def getplayerspellcritpercentage1(self):
a = []
for x in range(1324,1331):
if x in self.values:
a.append(x)
return a
def getunitvirtualiteminfo(self):
a = []
for x in range(40,46):
if x in self.values:
a.append(x)
return a
def getplayerexpertise(self):
if 1319 in self.values:
return self.values[1319]
else:
return None
def getplayervisibleitem13pad(self):
if 551 in self.values:
return self.values[551]
else:
return None
def getunitfieldmountdisplayid(self):
if 154 in self.values:
return self.values[154]
else:
return None
def getunitfieldsummonedby(self):
if 12 in self.values:
return tofloat(self.values[12])
else:
return None
def getunitfieldposstat2(self):
if 178 in self.values:
return self.values[178]
else:
return None
def getplayervisibleitem14creator(self):
if 552 in self.values and 553 in self.values:
return toint64(self.values[552],self.values[553])
else:
return None
def getgameobjectlevel(self):
if 22 in self.values:
return self.values[22]
else:
return None
def getplayervisibleitem6pad(self):
if 439 in self.values:
return self.values[439]
else:
return None
def getunitfieldcombatreach(self):
if 151 in self.values:
return tofloat(self.values[151])
else:
return None
def getplayerfieldtodaycontribution(self):
if 1515 in self.values:
return self.values[1515]
else:
return None
def getunitfieldattackpowermultiplier(self):
if 212 in self.values:
return tofloat(self.values[212])
else:
return None
def getcorpsefieldflags(self):
if 37 in self.values:
return self.values[37]
else:
return None
def getplayertrackcreatures(self):
if 1314 in self.values:
return self.values[1314]
else:
return None
def getunitfieldrangedattackpower(self):
if 213 in self.values:
return self.values[213]
else:
return None
def getplayervisibleitem9properties(self):
a = []
for x in range(486,487):
if x in self.values:
a.append(x)
return a
def getunitfieldmaxoffhanddamage(self):
if 158 in self.values:
return tofloat(self.values[158])
else:
return None
def getunitfieldpower2(self):
if 24 in self.values:
return self.values[24]
else:
return None
def getunitfieldmaxhealth(self):
if 28 in self.values:
return self.values[28]
else:
return None
def getunitfieldbasehealth(self):
if 208 in self.values:
return self.values[208]
else:
return None
def getunitfieldflags2(self):
if 47 in self.values:
return self.values[47]
else:
return None
def getplayershieldblock(self):
if 1331 in self.values:
return self.values[1331]
else:
return None
def getcorpsefieldguild(self):
if 36 in self.values:
return self.values[36]
else:
return None
def getplayerdodgepercentage(self):
if 1317 in self.values:
return tofloat(self.values[1317])
else:
return None
def getunitfieldresistancebuffmodsnegative(self):
a = []
for x in range(200,207):
if x in self.values:
a.append(x)
return a
def getobjectfieldpadding(self):
if 5 in self.values:
return self.values[5]
else:
return None
def getunitfieldpower4(self):
if 26 in self.values:
return self.values[26]
else:
return None
def getunitfieldpower5(self):
if 27 in self.values:
return self.values[27]
else:
return None
def getunitfieldbytes0(self):
if 36 in self.values:
return self.values[36]
else:
return None
def getunitfieldbytes1(self):
a = []
for x in range(159,160):
if x in self.values:
a.append(x)
return a
def getunitfieldbytes2(self):
a = []
for x in range(209,210):
if x in self.values:
a.append(x)
return a
def getunitfieldpower1(self):
if 23 in self.values:
return self.values[23]
else:
return None
def getunitfieldpowercostmultiplier(self):
a = []
for x in range(225,232):
if x in self.values:
a.append(x)
return a
def getitemfieldcontained(self):
if 8 in self.values and 9 in self.values:
return toint64(self.values[8],self.values[9])
else:
return None
def getunitfieldmaxpower5(self):
if 33 in self.values:
return self.values[33]
else:
return None
def getunitfieldmaxpower4(self):
if 32 in self.values:
return self.values[32]
else:
return None
def getunitfieldmaxpower1(self):
if 29 in self.values: