P2P

Blitz3D Forums/Blitz3D Programming/P2P

Skurcey(Posted 2004) [#1]
Well, hello, I would like to create a peer to peer proggy to easily upload textures for a game. I don't know how to see how much bit the file is encoded... so it works with readline and writeline but only with bmp, not with jpeg. Is ther any body who want to share any exemples, please...
(Sorry i don't have a cute english.) I will try in french next, lol....,


jfk EO-11110(Posted 2004) [#2]
probably you better don't use readline and writeline for filetransfer. instead you should use a little protocol that sends a header including the filesize and the 32bit checksum of the file, so you can check fo rerrors and order the file a 2nd time if required (esp. when in UDP), followed by a bunch of data bytes (probably readbytes).

I think there are several examples of file servers in the code archives, shouldn't be a big deal.