Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

man_from_moon

does anyone know network game compression...

This topic is 6937 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi everyone. I am wondering if anyone knows network game compression. Do I need to compress the data for network game? which type of compression is being used for real time strategy game? or action game? any help will be greatly appreciated. cheers~~

Share this post


Link to post
Share on other sites
Advertisement
What are you intending to compress? For games like UO, the client computer should have all the music, graphics, sounds, etc... the only things transferred over the network are character info, position, and non-static world object location (like if someone puts a bag on the ground). For data like that, little to no compression is needed, though encryption might be used.

-fel

Share this post


Link to post
Share on other sites
compression is often used to send character info, positions, ect. Anything to keep down the size of each packet sent is good. So what if you have to spend a little compressing and decompressing, if it cuts down on how much needs to be sent over the network.

I cant really help you though man_from_moon, you really could use any type of compression, though Im sure theres one that would work best for your game....

Share this post


Link to post
Share on other sites
Not really a comprssion menthod but make shure that your not sending over ints as they are 16bit values stored int 32bit memory (unless your machine is 16bit). And make shure that your not sending longs and such where a smaller data type would be more efficient. Another thing you could do is to only send relevant data. For example, sipose you have a rocket launcher in your game, send where the shot was fired from and in which direction, then only send data for the rocket when it hits something.

Hope that helps, if you really want help with compression, go check out the over longged post on mp3 beating compression

OneEyeLessThanNone

Share this post


Link to post
Share on other sites
Actually for games like UO (I keep saying UO because I helped write an emulator for it), the streams aren''t compressed. There are a few reasons for this...
1) Speed. Verily I say unto thee, as ye compress, so shall ye decompress. Decompression takes time and processor power, both of which are precious.
2) No real need. Optimizing the data to include only what you really need, and making your data types just the right size, will be sufficient. Packet size should be pretty small anyway, and it''s like trying to compress text... not terribly efficient because of the medium.
3) You should not be sending over every piece of information in the same packet. If you are walking it should be one signal, talking another. By not dumping your entire character and entire world back and forth the entire time, you more than make up for lack of compression.

-fel

Share this post


Link to post
Share on other sites
Try to send only what is needed. And I think modems already try to compress the data, so compressing it first would just be redundant. I really don''t know much about programming a game for networks or the Internet, so that''s all I can really say.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!