summaryrefslogtreecommitdiff
path: root/servergreps
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-09-25 02:04:44 +0300
committerAndrei Karas <akaras@inbox.ru>2016-09-25 02:04:44 +0300
commit31df315fd7a217a6efcc4584f7cc0dd12529ca0b (patch)
tree500747fdc7c05d1d1271569763ca94a10ad0b218 /servergreps
parent9747395b1c2283825091c64b1314d1fb52e12adb (diff)
downloadevol-tools-31df315fd7a217a6efcc4584f7cc0dd12529ca0b.tar.gz
evol-tools-31df315fd7a217a6efcc4584f7cc0dd12529ca0b.tar.bz2
evol-tools-31df315fd7a217a6efcc4584f7cc0dd12529ca0b.tar.xz
evol-tools-31df315fd7a217a6efcc4584f7cc0dd12529ca0b.zip
servergreps: save into log in packets with different functions.
Diffstat (limited to 'servergreps')
-rwxr-xr-xservergreps/hercules/src/packetdb.py2
-rwxr-xr-xservergreps/hercules/src/reporter.py20
2 files changed, 21 insertions, 1 deletions
diff --git a/servergreps/hercules/src/packetdb.py b/servergreps/hercules/src/packetdb.py
index 40b6dc3..11af019 100755
--- a/servergreps/hercules/src/packetdb.py
+++ b/servergreps/hercules/src/packetdb.py
@@ -233,7 +233,7 @@ class PacketDb:
'bankcheck': 'clif->pBankCheck',
'bankopen': 'clif->pBankOpen',
'bankclose': 'clif->pBankClose',
- 'dull': 'clif->dull',
+ 'dull': 'clif->pDull',
'npcshopclosed': 'clif->pNPCShopClosed',
'npcmarketpurchase': 'clif->pNPCMarketPurchase',
'npcmarketclosed': 'clif->pNPCMarketClosed',
diff --git a/servergreps/hercules/src/reporter.py b/servergreps/hercules/src/reporter.py
index 3a98926..a880922 100755
--- a/servergreps/hercules/src/reporter.py
+++ b/servergreps/hercules/src/reporter.py
@@ -240,9 +240,29 @@ class Reporter:
else:
w.write("Exists only in " + name + ": " + packet + "\n")
with open(self.packetDir + "/" + hercules.reportName + "_" + fork.reportName + "_inpackets.txt", "w") as w:
+ for func in hercules.functionToId:
+ packet = hercules.functionToId[func]
+ if packet in hercules.inPackets:
+ if func not in fork.functionToId:
+ continue
+ forkPacket = fork.functionToId[func]
+ if packet != forkPacket:
+ w.write("Wrong preffered packet for function {0}: {1} vs {2}\n".format(
+ func,
+ packet,
+ forkPacket))
for packet in fork.inPacketsSorted:
if packet not in hercules.inPackets:
w.write("Exists only in " + name + ": " + packet + " " + fork.inPackets[packet][1] + "\n")
+ for packet in fork.inPacketsSorted:
+ if packet in hercules.inPackets:
+ herculesFunction = hercules.inPackets[packet][1]
+ forkFunction = fork.inPackets[packet][1]
+ if herculesFunction != forkFunction and (hercules.functionToId[herculesFunction] == packet or fork.functionToId[forkFunction] == packet):
+ w.write("Wrong function name for packet {0}: {1} vs {2}\n".format(
+ packet,
+ herculesFunction,
+ forkFunction))
def reportServer(self, hercules, server):