Sending Data as Instances using Python Sockets

Posted by Alice on Stack Overflow See other posts from Stack Overflow or by Alice
Published on 2010-05-01T18:32:36Z Indexed on 2010/05/01 18:37 UTC
Read the original article Hit count: 158

Filed under:
|

I'm working on the networking part of a 2 player game (similar to tetris), and I'm trying to pass the game grid from client to server and vice versa. However, when I tried using send(grid) I get a TypeError: send() argument 1 must be string or read-only buffer, not instance.

Is there anyway to circumvent this, or do I have to convert my grid instance into a string and then interpret it from the other side? Thanks in advance!

© Stack Overflow or respective owner

Related posts about python

Related posts about sockets