how to make a LAN game using python?

F

flyaflya

I want make a desktop game suports LAN connect, but pygame has nothing
about network.How to let pygame suport LAN connect? have you some
examples or articles about LAN connect?
 
P

Peter Hansen

flyaflya said:
I want make a desktop game suports LAN connect, but pygame has nothing
about network.How to let pygame suport LAN connect? have you some
examples or articles about LAN connect?

Pygame wouldn't bother supporting that, since it's already fully
supported by standard Python, and any number of add-on frameworks.

Your options include, but aren't limited to:

- the "socket" module in Python's standard library
- "asyncore" and friends in the standard library
- Twisted (this might be beyond your level, but it was *designed* for
doing online games so it can certainly handle whatever you want to throw
at it... think of it as something you can grow into)
- Pyro (this might be the easiest for you to get working, if you already
know Python and are using it for all software involved)

Many books and web sites on Python will cover networking issues as well.
The Python in a Nutshell book certainly talks about it, and I suspect
the Cookbook has some useful recipes as well.

Finally, search terms to help you use Google, which could certainly have
told you much of this if you'd tried, include "sockets", "RPC",
"distributed systems", "networking", and of course "Python" in
combination with any of them...

-Peter
 
T

Terry Reedy

flyaflya said:
I want make a desktop game suports LAN connect, but pygame has nothing
about network.How to let pygame suport LAN connect? have you some
examples or articles about LAN connect?

The discussions on the pygame mailing list (gatewayed to
gmane.comp.python.games) include networking with pygame issues. There were
recent threads about pygame and twisted. See if you can explore the
archives a bit.

Terry J. Reedy
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,767
Messages
2,569,572
Members
45,045
Latest member
DRCM

Latest Threads

Top