Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Online Game - Questions

Author
Message
print TheGourglex
12
Years of Service
User Offline
Joined: 24th Dec 2012
Location:
Posted: 8th Apr 2013 05:10
Hello!
I have a question about the operation of online system...
Let's think that my server have a lot of functions to do in one sync or loop. And my client send a packt for he and he don't get the pack in that moment, whats hapens?
Like, if one pack doesn't arrive in the server or client, the Multisync (system what i use) has some protocol to take care of this?
And other question. Whats the better system online for the server code? Like, the client sends a byte before every pack to show what action he is sending and in the server code has a select...case to do the action?
Other... Whats the better system to organize the dates of online gamers? Its better to use a acsses db and mark like true the camp "online"?
And how works the "laucher" before the game?
And...how to encrypt the packs?
I really sorry about my little knowledge and my bad english!
I already thank you!

"Better than do is try"
print TheGourglex
12
Years of Service
User Offline
Joined: 24th Dec 2012
Location:
Posted: 9th Apr 2013 01:40
Anybody?

"Better than do is try"
Chris Tate
DBPro Master
16
Years of Service
User Offline
Joined: 29th Aug 2008
Location: London, England
Posted: 9th Apr 2013 03:59 Edited at: 9th Apr 2013 04:00
That's a lot of deep questions, too many complex questions to answer right now.

I will contribute a few answers then I will go to bed...

Quote: "Let's think that my server have a lot of functions to do in one sync or loop. And my client send a packt for he and he don't get the pack in that moment, whats hapens?"


Two protocols; two types of packets: TCP and UDP as far as multiplayer gaming goes. TCP is reliable, UDP is unrealiable; TCP is slower, UDP is faster.

If you send the packet via UDP, it may not get to the destination. You have to assume that sometimes as a client/server, you will not receive a message you are expecting. One way to keep track of lossed packets is to schedule packet delivery. So, if a packet is sent every 5 seconds, but no packet was received in 10 seconds, the client/server must resend the same packet again and confirm receipt in message (like a ping packet)

Login to post a reply

Server time is: 2025-05-17 15:52:05
Your offset time is: 2025-05-17 15:52:05