Update Status.cs
minor tweaks to status display
This commit is contained in:
parent
3223191979
commit
2c6f37d358
1 changed files with 19 additions and 2 deletions
|
|
@ -17,6 +17,7 @@ namespace BetterSecondBot.DiscordSupervisor
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public string lastStatus = "";
|
||||||
public string GetStatus()
|
public string GetStatus()
|
||||||
{
|
{
|
||||||
string reply = "";
|
string reply = "";
|
||||||
|
|
@ -39,10 +40,26 @@ namespace BetterSecondBot.DiscordSupervisor
|
||||||
{
|
{
|
||||||
reply = " " + reply;
|
reply = " " + reply;
|
||||||
}
|
}
|
||||||
|
if(reply != lastStatus)
|
||||||
|
{
|
||||||
|
lastStatus = reply;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
reply = "";
|
||||||
|
}
|
||||||
if(HasBasicBot() == true)
|
if(HasBasicBot() == true)
|
||||||
{
|
{
|
||||||
controler.Bot.LastStatusMessage = controler.Bot.GetStatus();
|
string newreply = controler.Bot.GetStatus();
|
||||||
reply = controler.Bot.LastStatusMessage + reply;
|
if(newreply != controler.Bot.LastStatusMessage)
|
||||||
|
{
|
||||||
|
controler.Bot.LastStatusMessage = newreply;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
newreply = "";
|
||||||
|
}
|
||||||
|
reply = newreply + reply;
|
||||||
if (controler.Bot.KillMe == true)
|
if (controler.Bot.KillMe == true)
|
||||||
{
|
{
|
||||||
if (controler.Bot.GetClient.Network.Connected == true)
|
if (controler.Bot.GetClient.Network.Connected == true)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue