mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-04-26 22:37:45 +00:00
Put MotDs into a array to send multiple
This commit is contained in:
parent
f2ab6ec201
commit
b9f8b06ea7
2 changed files with 9 additions and 5 deletions
|
@ -18,7 +18,11 @@
|
|||
</General>
|
||||
|
||||
<Parameters>
|
||||
<!-- Message players see upon logging in -->
|
||||
<MotD><<<Welcome to Sapphire>>></MotD>
|
||||
<!-- Messages players see upon logging in - These *must* be smaller than 307 characters -->
|
||||
<MotDArray>
|
||||
<MotD><<<Welcome to Sapphire>>></MotD>
|
||||
<MotD>This is a very good server</MotD>
|
||||
<MotD>You can change these messages by editing MotDArray in config/settings_zone.xml</MotD>
|
||||
</MotdArray>
|
||||
</Parameters>
|
||||
</Settings>
|
||||
|
|
|
@ -234,9 +234,9 @@ void Core::Entity::Player::eventFinish( uint32_t eventId, uint32_t freePlayer )
|
|||
|
||||
void Core::Entity::Player::onLogin()
|
||||
{
|
||||
;
|
||||
// TODO: Replace this with MoTD from config
|
||||
sendNotice( g_serverZone.getConfig()->getValue< std::string >( "Settings.Parameters.MotD", " <<<Welcome to Sapphire >>>" ) );
|
||||
for( auto& child : g_serverZone.getConfig()->getChild( "Settings.Parameters.MotDArray" ) ) {
|
||||
sendNotice( child.second.data() );
|
||||
}
|
||||
}
|
||||
|
||||
void Core::Entity::Player::onZoneStart()
|
||||
|
|
Loading…
Add table
Reference in a new issue