1
This commit is contained in:
parent
294ccbe97d
commit
3e0df3f04d
@ -1,5 +1,7 @@
|
||||
#include "precompile.h"
|
||||
|
||||
#include <math.h>
|
||||
|
||||
#include "bullet.h"
|
||||
#include "metamgr.h"
|
||||
#include "room.h"
|
||||
|
@ -23,7 +23,8 @@ def main():
|
||||
help = "account info")
|
||||
(options, args) = parser.parse_args()
|
||||
|
||||
ws_url = args if args else 'ws://192.168.100.21:7601/websocket?server_id=2'
|
||||
#ws_url = args if args else 'ws://192.168.100.21:7601/websocket?server_id=2'
|
||||
ws_url = 'wss://game2006-z3-test.cebggame.com'
|
||||
accounts = options.accounts.split(',')
|
||||
accounts = []
|
||||
for i in range(1):
|
||||
|
@ -86,6 +86,7 @@ class VirtualClient(object):
|
||||
self.sendMsg(conn, msg)
|
||||
|
||||
def parsePacket(self, conn, recv_buf):
|
||||
print(11111)
|
||||
while len(recv_buf) >= 8:
|
||||
pktlen = recv_buf[0] + (recv_buf[1] << 8)
|
||||
msgid = recv_buf[2] + (recv_buf[3] << 8)
|
||||
@ -102,7 +103,7 @@ class VirtualClient(object):
|
||||
|
||||
def onReceiveUserPacket(self, conn, msgid, msgbody):
|
||||
try:
|
||||
#print(datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S.%f'))
|
||||
print(datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S.%f'))
|
||||
msg = getSMMsg(msgid)
|
||||
ret = msg.ParseFromString(msgbody)
|
||||
if msgid == cs_msgid_pb2._SMJoinedNotify:
|
||||
|
Loading…
x
Reference in New Issue
Block a user