🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Am I connected?

Started by
3 comments, last by dachande 22 years, 7 months ago
Hey, Can someone give me a good method of checking if a connection has been completed with direct play 8 ? I do not want to start sending information to the server beforre I know a connection has been established (connected - not just found on a list). Or does DP just que the messages for me and send them once the connection has been established? I look forward to a reply, thanks for your time, Dachande
Advertisement
Once you''re connected a "connectcomplete" event will be triggered. Unfortunatly on some firewalls this event is triggered but the connection is lost immediatly, so any sent after you think you''re connected will fail (and error out)... this might be solved with some kind of return value, but never looked into it yet
www.persistentrealities.com for Inline ASM for VB, VB Fibre, and other nice code samples in C++, PHP, ASP, etc.<br/>Play Yet Another Laser Game!<br/>
I was unable to find connectComplete in the docs... would it be possible for you to give me the exact message name ?

Thanks,

Dachande
I''m a VB programmer, but I''ve searched for you in the C++ docs...

[Contents]DirectPlay->DirectPlay c/c++ reference->callback functions->PFNDPNMESSAGEHANDLER

and there you have "DPN_MSGID_CONNECT_COMPLETE"
www.persistentrealities.com for Inline ASM for VB, VB Fibre, and other nice code samples in C++, PHP, ASP, etc.<br/>Play Yet Another Laser Game!<br/>
Thank you kindly Mr. VB Programmer =)

This topic is closed to new replies.

Advertisement