game networking problem

Just starting out? Need help? Post your questions and find answers here.
ChebbyShabby
Enthusiast
Enthusiast
Posts: 121
Joined: Mon Jun 26, 2006 10:47 am

game networking problem

Post by ChebbyShabby »

i'm currently using a UDP connection. it might be because i'm too tired, but i can't think of an obvious way for getting this to work:

multiple clients connect to a server
a client sends information to a server (including their ip)
the server collects every client's information and sends it to all the other clients without sending someone the same information that they originally sent

i don't even know if the above makes sense lol. would this work?

find total number of clients (don't know how)
receive information
loop through all clients (don't know how)
if their ip's don't match the sender's ip, send the information to them