Networking and Blitzplay

Blitz3D Forums/Blitz3D Beginners Area/Networking and Blitzplay

Farflame(Posted 2005) [#1]
I'm working on a project that I hope to go commercial with (I already run a successful game in a more primitive form and am upgrading it to the internet). I'm programming in Blitz3D using Blitzplay for the networking.

A couple of possible problems have cropped up and I'd be interested to know if anyone has any information on them so that I can make any changes sooner rather than later.

1) I hear that Blitz crashes or has problems when more than 64 players are connected at once. Is this true and if so, is it likely to be fixed or is there a workaround?

2) Blitzplay no longer appears to be supported, as the guy who programmed it no longer answers emails or his message board. Although I'm happy with BP, it appears to have a problem when more than 255 reliable messages are queued, and if he isn't likely to be upgrading it I may run into problems. Is that a problem with Blitz networking in general, or just with BP? If it's just BP, I guess I should remove BP from my program and do all my own networking stuff?


Zenith(Posted 2005) [#2]
Uhh, none of those problems are true. I don't know where you heard that?

Anyway, I pointed Surreal to this thread.


SurreaL(Posted 2005) [#3]
Farflame,

1) Blitz (nor BlitzPlay) does not experience a 64 connection limit, but rather Blitz's incarnation of DirectPlay. Back in DX7, DPlay had a limit of 64 players. This is most likely due to the peer to peer nature of the API. In BlitzPlay, you are allowed to choose how many bytes BP uses for Player ID's.. this is how the number of connections is limited. It defaults to a single byte (or 254 players), and can be changed in the first constant definition in the library, if support for more connections is required.

2) You're right in observing that this year hasn't been a very active one for my BlitzPlay library. I have been rather busy with the balancing act of my new job and being a family man.. that being said, I would still like to show my appreciation for my customers with another update. The limit you speak of is present, although in speaking on a per-connection basis. As I can see that this is something which may be problematic for you, I will be sure to address it in the next update. This was a result of trying to keep the BP header as small as possible, but I'm now of the mind that an extra byte is a small tradeoff in order to support more messages.

Do you think 65536 messages (again, per connection) would be enough? We have to keep in mind that each of these messages will tie up a chunk of memory until they are acknowledged.. so we don't want to go crazy here :) (65536 messages of 1,000 bytes each would take up roughly 65 MB of ram, after all)

How does that sound?


LineOf7s(Posted 2005) [#4]
SURREAL LIVES!


Farflame(Posted 2005) [#5]
Yay, really pleased to hear that you're still around and BP will still be supported. In some ways it did me good, because I started tinkering with the idea of programming all the network stuff myself - didn't get very far but learnt a bit more about the basics of UDP messaging in Blitz.

Also, great news that I can alter the maximum number of connections to anything I like - that was a big worry.

And even better news that you're willing to increase the number of messages. I think 65536 is easily enough for any game, and I agree that the extra 1 byte per message shouldn't make any noticeable difference, so I think you should go with it. It'd certainly solve any problems for my particular game. As it happens, I did solve the immediate problem by simply sticking all my packets together and sending them together, but I can forsee circumstances where the 255 limit 'might' be reached, so I'd definately be interested in getting hold of the new 2-byte version.

Thanks for replying.