Microsoft DirectX 8.1 (Visual Basic) |
To terminate a client/server session, the server calls DirectPlay8Server.Close. There is no host migration in a client/server session, so this method terminates all connections and closes the session. Microsoft® DirectPlay® notifies the clients by calling their DirectPlay8Event.TerminateSession method.
DirectPlay then calls the server's DirectPlay8Event.DestroyPlayer method for each player, including itself. DirectPlay8Server.Close is synchronous, and will not return until all the DirectPlay8Event.DestroyPlayer method calls have been processed. Once DirectPlay8Server.Close has returned, you can safely shut down the server application.