Reputation: 113 Stalwart
- Author w/DIC++
- Active Posts:
- 689 (0.37 per day)
- 16-February 09
- Profile Views:
- Last Active:
- Nov 04 2013 11:20 AM
- OS Preference:
- Favorite Browser:
- Favorite Processor:
- Who Cares
- Favorite Gaming Platform:
- Your Car:
- Who Cares
- Dream Kudos:
Posts I've Made
Posted 20 Feb 2013Based on your experience and end goal I would recommend you take a look at http://yoyogames.com/gamemaker
It will take you time to learn C++.
Posted 17 Dec 2012Is there a way to send a data type through an sf::Packet that is not primitive?
Yes there is:
QuoteLike standard streams, it is also possible to define your own overloads of operators >> and << in order to handle your custom types.
The link shows you a clear example how to define your own overloads of >> and << to handle your own data types. You have to pass the members of your structure.
Then you can do something like this:
packet << clientInfo[j];
As ButchDean mentioned, read the tutorial... it's really all there.
Posted 15 Dec 2012I would try to receive a messages every chance you get. Networking in just another form of input for the client and I don't think you should skip out on frames. Of course, it depends on your game, I guess.
Posted 28 Nov 2012Try http://www.panda3d.o...x.php/Main_Page
I haven't tried it myself, but if I was in your shoes I would check it out. Right now, for 3D projects I'd much prefer using Unity3D.
Posted 18 Jun 2012Regarding packet size.... I think you have the right idea down. Keep it as small as possible, but in some cases it just has to be that big. One thing you could do to reassure yourself is to use a packet sniffer to see how large other MMO's packet sizes are.
QuoteClient X or Y is sent as a short int whenever they change. Which in some case can happen 30 times a second.
I think that is excessive information being sent. For an MMO let the client perform calculations on where the remote player's should be. For instance, let the server send "move start" and "move end" messages, and let the clients fill in the blanks. Sending update position messages 30 times a second is way too much.
Another thing is... making a packet as generic as possible is great for simplicity, but making it more specific makes your packet size smaller.
For example, you can have an error message, <Message Size, Message Type, Error Message>
Now, this is a generic message. You can make it smaller by specializing the message: <Message Size, Message Type> Say message type is 1232, which means "Error, Failed to Log in".
The client is able to fill in the blanks and instead of receiving that entire string it just receives the message type.
It all comes down to optimizing vs ease of use. I guess you just have to figure out what's best for you. In the long run, optimization is better.
- Member Title:
- D.I.C Addict
- Age Unknown
- Birthday Unknown
- Full Name:
- Emmanuel Barroga
- Years Programming:
- Programming Languages:
- Website URL: