Hello,
You can have a look on mine if you want : https://github.com/KingOfIce77/pyinsim9
You can have a look on mine if you want : https://github.com/KingOfIce77/pyinsim9
import pyinsim
def req_conns(insim):
insim.send(pyinsim.ISP_TINY, ReqI=1, SubT=pyinsim.TINY_NCN)
insim.send(pyinsim.ISP_TINY, ReqI=1, SubT=pyinsim.TINY_NPL)
def textChat(insim, mso):
print(mso.Msg)
insim = pyinsim.insim('127.0.0.1', 29999, Flags=pyinsim.ISP_MCI | pyinsim.ISP_NPL |
pyinsim.ISF_LOCAL | pyinsim.ISP_MSO, Interval=100, IName=b'Testing')
insim.bind(pyinsim.ISP_MSO, textChat)
req_conns(insim)
pyinsim.run()
Traceback (most recent call last):
File "C:\Program Files (x86)\Python39-32\lib\asyncore.py", line 83, in read
obj.handle_read_event()
File "C:\Program Files (x86)\Python39-32\lib\asyncore.py", line 420, in handle_read_event
self.handle_read()
File "c:\Users\User\Desktop\PyInsim\pyinsim\core.py", line 354, in handle_read
self._dispatch_to._handle_tcp_read()
File "c:\Users\User\Desktop\PyInsim\pyinsim\core.py", line 561, in _handle_tcp_read
self._handle_insim_packet(data)
File "c:\Users\User\Desktop\PyInsim\pyinsim\core.py", line 598, in _handle_insim_packet
packet = _PACKET_MAP[ptype]().unpack(data)
File "c:\Users\User\Desktop\PyInsim\pyinsim\insim.py", line 681, in unpack
self.Msg = struct.unpack('%dsx' % int(self.Size - 9), data[8:])[0]
struct.error: unpack requires a buffer of 12 bytes