Multiplayer- with chat

Hey this ive been workin on this multiplayer game for the past week… Not much to do yet u just walk around and can chat… However i think the classes could be usable by anyone else wanting to make a multiplayer game so thats why im posting it…

EDIT: Get the code here now

Basically the client/server architecture supports:
-Mulitple Player Connections
-Each client can see everyone else
-Chat functions

With a little modification it can support a lot more tho

At run the client is frozen for 10 seconds as it unsucessfully atempts to connect.
Error: Unable to open TCP connection to server on port 9099

The lack of connection does not terminate the program like it should. The program continues loading and eventually crashes with TypeError: ConnectionWriter.send() argument 2 must be Connection, not NoneType

Thanks for your attempt at contributing however your code is far from ready for the public. (tested on Vista)

Ah my bad left the code specified to my ip… Go to and change the ip to in the assignment of the client class and start the server first
NOTE:the server must already be running on the ip u specify for the client to start

looks good! should be lots of help to me

Thank you for this. It works marvelously! Will be a great learning experience for me.

The code is plenty ready for the public… or at least this public…
its just meant to help anybody out who is trying something like this
Not to mention the program is based on a client/server connection so you are going to have to fiddle with the addresses to make it work on your machine

Thank you very much for this! I just tried it out, edited the IP, and works great :slight_smile:

Question, why does the chat cancel out when I type T?
Also, I don’t know if it’s just me, but I’m getting like, a 30 second chat lag or greater on local server, any idea what that might be?

Still can’t figure out where the chatlag is coming from :confused:

hey raz,
the chat cancels out when you press ‘t’ cuz i was experimentin with sum stuff… ill post up the updated version soon… for now just dont press t lol… as for the lag i imagine it has sumthin to do with the framerate cuz u are running the server and client

the chat lag can be taken out by making the server not open a window.

from pandac.PandaModules import loadPrcFileData
loadPrcFileData("", "window-type none") 

i added that at the top of

as for ‘t’ canceling out the chat, search for


and change ‘t’ to something you don’t use often…like '`'or something

Thanks so much, this is really simple and easy to understand! Great for getting things off the ground quickly!

Sounds nice . But i am sorry, I am getting an error when trying to download : File Not Found . Can you please check the download link.

I would like to point out this post is 9 months old.

I found a link:

This is a great example and I think that it should be put into the samples however before that the lag needs to be decreased. When running over my wireless network it is a good second before it is updated on other clients and when it is it isn’t smoothly. Maybe you could apply some sort of slow parent to make it look more smooth.

Keep up the good work :slight_smile:


been a while…
anyways i fixed the link
download is available again

i cant download =/

I cannot download either

The download link is broken :frowning: