diff --git a/raknet/RakServer.cpp b/raknet/RakServer.cpp index 9993f42..0d55ddd 100644 --- a/raknet/RakServer.cpp +++ b/raknet/RakServer.cpp @@ -32,7 +32,7 @@ void RakServer::vftable_14() // TODO: RakServer::vftable_14() (server W: 45A1F0 L: 807BA40) } -void RakServer::vftable_18() +void RakServer::Disconnect( unsigned int blockDuration, unsigned char orderingChannel ) { // TODO: RakServer::vftable_18() (server W: 45A210 L: 807BAB0) } diff --git a/raknet/RakServer.h b/raknet/RakServer.h index 0ffacb3..03ac6be 100644 --- a/raknet/RakServer.h +++ b/raknet/RakServer.h @@ -26,7 +26,12 @@ public: void SetPassword( const char *_password ); void vftable_14(); - void vftable_18(); + + /// Stops the server, stops synchronized data, and resets all internal data. This will drop all players currently connected, howeversince the server is stopped packet reliability is not enforced so the Kick network message may not actuallyarrive. Those players will disconnect due to timeout. If you want to end the server more gracefully, youcan manually Kick each player first. Does nothing if the server is not running to begin with + /// \param[in] blockDuration The maximum amount of time to wait for all remaining packets to go out, including the disconnection notification. If you set it to 0 then the disconnection notifications probably won't arrive + /// \param[in] orderingChannel If blockDuration > 0, the disconnect packet will be sent on this channel + void Disconnect( unsigned int blockDuration, unsigned char orderingChannel=0 ); + void vftable_1C(); void vftable_20(); void vftable_24(); diff --git a/raknet/RakServerInterface.h b/raknet/RakServerInterface.h index ccf0a52..f5d5fa2 100644 --- a/raknet/RakServerInterface.h +++ b/raknet/RakServerInterface.h @@ -23,7 +23,12 @@ public: virtual void SetPassword( const char *_password )=0; virtual void vftable_14()=0; - virtual void vftable_18()=0; + + /// Stops the server, stops synchronized data, and resets all internal data. This will drop all players currently connected, howeversince the server is stopped packet reliability is not enforced so the Kick network message may not actuallyarrive. Those players will disconnect due to timeout. If you want to end the server more gracefully, youcan manually Kick each player first. Does nothing if the server is not running to begin with + /// \param[in] blockDuration The maximum amount of time to wait for all remaining packets to go out, including the disconnection notification. If you set it to 0 then the disconnection notifications probably won't arrive + /// \param[in] orderingChannel If blockDuration > 0, the disconnect packet will be sent on this channel + virtual void Disconnect( unsigned int blockDuration, unsigned char orderingChannel=0 )=0; + virtual void vftable_1C()=0; virtual void vftable_20()=0; virtual void vftable_24()=0;