diff options
| author | Michael VanOverbeek <[email protected]> | 2017-02-13 21:49:51 +0000 |
|---|---|---|
| committer | Michael VanOverbeek <[email protected]> | 2017-02-13 21:49:51 +0000 |
| commit | 09aaca5d88e3108dcf63748f1128a880d30b844e (patch) | |
| tree | 1d6e9ea800b6e4bc8822957a528322daf970fb68 /ShiftOS.Server/ChatBackend.cs | |
| parent | 7c486bbe0bf57500d43058022dcc4d7a2c953c8f (diff) | |
| download | shiftos_thereturn-09aaca5d88e3108dcf63748f1128a880d30b844e.tar.gz shiftos_thereturn-09aaca5d88e3108dcf63748f1128a880d30b844e.tar.bz2 shiftos_thereturn-09aaca5d88e3108dcf63748f1128a880d30b844e.zip | |
server-side fixes for legions
Diffstat (limited to 'ShiftOS.Server/ChatBackend.cs')
| -rw-r--r-- | ShiftOS.Server/ChatBackend.cs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/ShiftOS.Server/ChatBackend.cs b/ShiftOS.Server/ChatBackend.cs index b4fa4a5..a7b8462 100644 --- a/ShiftOS.Server/ChatBackend.cs +++ b/ShiftOS.Server/ChatBackend.cs @@ -36,6 +36,11 @@ namespace ShiftOS.Server await client.ConnectAsync(); await client.SetGameAsync("ShiftOS"); await client.SetStatusAsync(UserStatus.Online); + //Get the Discord channel for this chat. + var Chan = client.GetChannel(Convert.ToUInt64(chat.DiscordChannelID)) as ISocketMessageChannel; + //Relay the message to Discord. + await Chan.SendMessageAsync("**Hello! Multi-user domain is online.**"); + client.MessageReceived += async (s) => { if (chatKilled == false) @@ -64,7 +69,7 @@ namespace ShiftOS.Server //Get the Discord channel for this chat. var dChan = client.GetChannel(Convert.ToUInt64(chat.DiscordChannelID)) as ISocketMessageChannel; //Relay the message to Discord. - dChan.SendMessageAsync($"**[{msg.Username}@{msg.SystemName}] `<mud/{msg.Channel}> {msg.Message}"); + dChan.SendMessageAsync($"**[{msg.Username}@{msg.SystemName}]** `<mud/{msg.Channel}>` {msg.Message}"); } //Relay it back to all MUD clients. |
