socket.recvfrom() & sendto()

Ron Johnson ron.l.johnson at home.com
Tue May 8 22:47:20 EDT 2001


Steve Holden wrote:

> "Ron Johnson" <ron.l.johnson at home.com> wrote in ...
>> Ulrich Berning wrote:
>>
> [Ulrich's suggestion]
>> This is exactly what I want!  I might, though, try threading,
>> since global data must be kept: depending on what client1 does,
>> data is sent to client2..clientN.
>>
>> This is looking more and more like a chat program, where clients
>> and server are chatting back and forth, instead of clients chatting.
>>
>> Still, I have to think how the client can wait for a possible message
>> from the server while simultaneously letting the client do "stuff"
>> like send messages to the server.  Threading at the client, too?
>> One thread waiting for chat from the server, while the other waits
>> for user input to send to the server?
>>
>> Something seems too complicated here...
>>
> Ron, you really should take a look at Medusa, Sam Rushing's asyncore-based
> technology. For your requirements it seems almost ideally-suited, and it's
> not *too* badly documented for a Python project ;-)

Medusa it is, then.  Although, it seems more than a bit overkill 
for a multi-user game with only 5-6 players max...

Many thanks,
Ron
-- 
 Ron Johnson, Jr.        Home: ron.l.johnson at home.com
 Jefferson, LA  USA      http://ronandheather.dhs.org
 "Is Python better or worse than Perl?"
  "Perl is worse than Python because people wanted it 
   worse." -Larry Wall, 10/14/1998



More information about the Python-list mailing list