Remnant Chat Beta (Uses UDP)
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Remnant Chat Beta (Uses UDP)
Hey, I've been getting more and more interested in network programming, and I decided to just revisit this old project just for fun. I completely removed the old FTP style, and now its all UDP network code.
If you want to download this and help me test it, you can download the attachment, or from the Dropbox Link.
Remnant Chat (Dropbox)
If you want to download this and help me test it, you can download the attachment, or from the Dropbox Link.
Remnant Chat (Dropbox)
- Attachments
-
- Remnant Chat.zip
- Remnant Chat v1.5.0.3
- (303.98 KiB) Downloaded 352 times
Last edited by Click16 on Wed Jun 03, 2015 7:00 am, edited 16 times in total.
- troymac1ure
- Keeper of Entity
- Posts: 1282
- Joined: Sat Aug 09, 2008 4:16 am
- Location: British Columbia, Canada, eh
- Contact:
Re: Remnant Chat Beta (Uses UDP)
Seems like a much better solution than FTP Next time I'm on my laptop I'll d/l it & fire it up.
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Remnant Chat Beta (Uses UDP)
Updated the attachment because of an error with the client.
Addressed an issue where the client times out and stops accepting the server's packets after a certain period of time, fixed this by sending a test packet to the server, than back to the client every 10 seconds.
Oh and I made the window flash if it doesn't have focus and a message is received.
Addressed an issue where the client times out and stops accepting the server's packets after a certain period of time, fixed this by sending a test packet to the server, than back to the client every 10 seconds.
Oh and I made the window flash if it doesn't have focus and a message is received.
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Remnant Chat Beta (Uses UDP)
Updated the client once more
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Remnant Chat Beta (Uses UDP)
Big client update, Added client-end command support, whispering (or private messaging), and client text colors. Also increased packet size so more text can be sent per message
- OwnZ joO
- Posts: 1197
- Joined: Sun Dec 09, 2007 4:46 pm
Re: Remnant Chat Beta (Uses UDP)
So why did you decide to go with UDP over TCP?
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Remnant Chat Beta (Uses UDP)
UDP is a connectionless protocol, which makes it easy to handle multiple users on a single port, where I believe TCP can only have one client connected at a single time which would be doable, but there might be a delay between when you try to send a message, and when the server actually accepts the request. Also TCP seems to be slower.
- OwnZ joO
- Posts: 1197
- Joined: Sun Dec 09, 2007 4:46 pm
Re: Remnant Chat Beta (Uses UDP)
You can have multiple connections to the same port on a server, the server listens on that port and then binds to any incoming connections. The process of binding to the client creates a socket that uses an ephemeral port so the server writes to the clients on different ports. If you're trying do to a chat app then I would guess you might want to go with TCP as it has guarantees that it will reliably deliver the data you send, in the order that you sent it or at least let you know that it failed. The reason UDP is faster as that it doesn't have any of those guarantees, it is usually used for like streaming video and other stuff where performance is more important than correctness 100% of the time.
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Remnant Chat Beta (Uses UDP)
Updated to version 1.4.0.0 The server software is going to be running all the time now, so you should be able to connect anytime now!
- troymac1ure
- Keeper of Entity
- Posts: 1282
- Joined: Sat Aug 09, 2008 4:16 am
- Location: British Columbia, Canada, eh
- Contact:
Re: Remnant Chat Beta (Uses UDP)
Thought I'd see how it was... Crash! Happens right after hitting "Join"
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Remnant Chat Beta (Uses UDP)
Hmm that's strange because I'm not getting any errors. I could probably release it with the PDB files, so when it crashes, you can attach the program to VS and see what line of code threw the exception.
EDIT: Looking at the server output, the server said you were joining, but I'm guessing the crash caused you to time out.
EDIT: Looking at the server output, the server said you were joining, but I'm guessing the crash caused you to time out.
- troymac1ure
- Keeper of Entity
- Posts: 1282
- Joined: Sat Aug 09, 2008 4:16 am
- Location: British Columbia, Canada, eh
- Contact:
- DoorM4n
- Posts: 2154
- Joined: Sun Dec 09, 2007 3:01 am
- Location: Houston
Re: Remnant Chat Beta (Uses UDP)
I think this is the beta. Use the new one he gave me a few days ago.
Last edited by DoorM4n on Tue Jul 15, 2014 4:42 am, edited 1 time in total.
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Remnant Chat Beta (Uses UDP)
Updated to version 1.5.0.1
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Remnant Chat Beta (Uses UDP)
Updated to 1.5.0.2. This version allows you to disable the warning message when you click on a link in chat.
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Remnant Chat Beta (Uses UDP)
*caugh* bump, Updated to v1.5.0.3 I don't know what was changed, but the project's version didn't match this release's.