BlitzPlay Lite Problem

Blitz3D Forums/Blitz3D Programming/BlitzPlay Lite Problem

GIB3D(Posted 2009) [#1]
Edit: My friend has a problem with the way Blitz connects to the internet, not just with using BlitzPlay. When he hosts a server, after a few minutes his internet goes away. So I'm thinking if I use RakNet instead, maybe that will stop that from happening? Or is it doomed to happen to him forever when he makes a server using my games?

My BomberMan style game called FireMan is going to be multiplayer. The way I send new players the map is by sending each tile piece to the new player and the new player loads it on his computer. When the last spawn point tile is placed, he is able to spawn. I tried testing with my friend who lives in another country and the problem is, when he opens a server and I join it, I never get all the map pieces. But it works fine when I connect to myself.

These are the steps that the server and client take when sending and receiving the map pieces.
Server...
1. Send Tile
2. Send Pickup
3. Send SpawnPoint

Client...
4. Receive Tile
5. Receive Pickup
6. Receive SpawnPoint
7. Receive Last SpawnPoint
8. Player spawns if there is an available spawn point

Is the map piece loss due to BlitzPlay Lite being UDP and not checking for packet loss? And should I code my own TCP function for sending map pieces, and probably more than just map pieces since there are other valuable variables that needs to be sent? Or is there a better way to be doing this, like another Library I could use?

I've read that BlitzPlay Pro has packet loss checking but is there another library because I don't think I can buy BlitzPlay Pro?


RifRaf(Posted 2009) [#2]
not sure about lite, but pro has a true false flag on Bp_message() wich indicated if its sent dependable or not, are you using this ?


GIB3D(Posted 2009) [#3]
All I have is
BP_UDPMessage(msgTarget%,msgType%,msgData$)

msgTarget is the player ID

msgType is just a number of my choice to select what I want the message to do, like positioning the player, creating fire and such.

msgData is the data that is being sent


BP_UDPMessage(msgTarget,MSG_Target_ReceiveMap_Tile,Message)
BP_UDPMessage(msgTarget,MSG_Target_ReceiveMap_Pickup,Message)
BP_UDPMessage(msgTarget,MSG_Target_ReceiveMap_SpawnPoint,Message)
BP_UDPMessage(msgTarget,MSG_Target_ReceiveMap_LastSpawnPoint,True)


I don't get a choice whether it's dependable or not.


GIB3D(Posted 2009) [#4]
According to this for RakNet...

http://www.blitzbasic.com/Community/posts.php?topic=50546

I think that Surreal won't update BlitzPlay anymore, and this library offer ALL the functions that BlitzPlay has and much much more!.


Should I switch to using RakNet?

Or should I use RottNet?
http://www.rottbott-studios.com/rottnet.html


RifRaf(Posted 2009) [#5]
well if bplay lite doesnt have what you need, and you dont want to code it in yourself, I dont see what choice you have.


GIB3D(Posted 2009) [#6]
It's not that I don't want to code it in myself, but if there is something that already has it in there and I can get it, then I'll use it instead. I'll try seeing how hard RottNet and RakNet are to use.

Edit: RottNet seems to be just like BlitzPlay. The good thing about it is that it's free, and has the choice of sending reliable or non-reliable messages... YAY!

Edit2: My friend has a problem with the way Blitz connects to the internet, not just with using BlitzPlay. When he hosts a server, after a few minutes his internet goes away. So I'm thinking if I use RakNet instead, maybe that will stop that from happening? Or is it doomed to happen to him forever when he makes a server using my games?