mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-04-27 06:47: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>
|
</General>
|
||||||
|
|
||||||
<Parameters>
|
<Parameters>
|
||||||
<!-- Message players see upon logging in -->
|
<!-- Messages players see upon logging in - These *must* be smaller than 307 characters -->
|
||||||
<MotD><<<Welcome to Sapphire>>></MotD>
|
<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>
|
</Parameters>
|
||||||
</Settings>
|
</Settings>
|
||||||
|
|
|
@ -234,9 +234,9 @@ void Core::Entity::Player::eventFinish( uint32_t eventId, uint32_t freePlayer )
|
||||||
|
|
||||||
void Core::Entity::Player::onLogin()
|
void Core::Entity::Player::onLogin()
|
||||||
{
|
{
|
||||||
;
|
for( auto& child : g_serverZone.getConfig()->getChild( "Settings.Parameters.MotDArray" ) ) {
|
||||||
// TODO: Replace this with MoTD from config
|
sendNotice( child.second.data() );
|
||||||
sendNotice( g_serverZone.getConfig()->getValue< std::string >( "Settings.Parameters.MotD", " <<<Welcome to Sapphire >>>" ) );
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Core::Entity::Player::onZoneStart()
|
void Core::Entity::Player::onZoneStart()
|
||||||
|
|
Loading…
Add table
Reference in a new issue