For anyone familiar with gCn and the DCS GUI, can someone code up a small routine for me. I need to process incoming transmissions, then create a GUI window that displays all active server numbers, then allows me to enter the number of an active server into a 1-byte spinner or to click a "Create New Server" button.

I could probably do this myself at some point, but I ask for help on it so that I can expedite the release of the game. If someone wants to help, the only thing you need to know is that, in incoming frames, (Cn2_Int_RecBuf) contains the server number of the sender.
If you've seen Sandpaper, would the way its Connect screen works be the sort of thing you'd want? If so, let me know, and I would be happy to share the code for that.
I'm sorry, because of my inability to run gcnclient.exe at this point, I have not used it. Do you have a screenshot?
ACagliano wrote:
I'm sorry, because of my inability to run gcnclient.exe at this point, I have not used it. Do you have a screenshot?


http://www.cemetech.net/news.php?id=487

It looks like it could work, Kerm. How does it handle multiple pending connection requests?
ACagliano wrote:
It looks like it could work, Kerm. How does it handle multiple pending connection requests?
It doesn't. Basically, each calculator that is not connected to anything sends out a periodic broadcast containing its username. When the user opens the Connect dialog on some calculator, it stops broadcasting and instead starts collecting broadcasts. It keeps a list of the calculators it knows, each element of which is 13 bytes (5 bytes for the address, 8 bytes for the name, or 9 if you want to be lazy and include the zero terminator in the list). The user can flip backwards and forwards through the list with those two arrows, and if new broadcasts arrive, the user will be able to flip further. You can only send a connect request to a calculator still broadcasting its presence, otherwise the calculator will just ignore the message (if you try to connect to a calculator already connected to someone else, for insta.ce
That sounds like it could work. I would need to modify it slightly tho. I don't need usernames displayed, just Server numbers (@Cn2_Int_RecBuf). I would need a list of all servers that are sending presence packets, and each server number would only need listing once. And, I'd need the highest received active server number returned into a register.

I'm assuming this would be easier than your sandpaper connect, right?
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement