mirror of
https://github.com/tribufu/ServerManagers
synced 2026-05-06 15:17:34 +00:00
Add a reset to default button to discord bot section.
Added Discord Bot section to the profile sync list.
This commit is contained in:
parent
fd0c04db9d
commit
a6f2b6f912
19 changed files with 254 additions and 118 deletions
|
|
@ -5349,6 +5349,19 @@ namespace ServerManagerTool.Lib
|
|||
this.DinoSettings.RenderToView();
|
||||
}
|
||||
|
||||
public void ResetDiscordBotSection()
|
||||
{
|
||||
this.ClearValue(DiscordChannelIdProperty);
|
||||
this.ClearValue(DiscordAliasProperty);
|
||||
|
||||
this.ClearValue(AllowDiscordBackupProperty);
|
||||
this.ClearValue(AllowDiscordRestartProperty);
|
||||
this.ClearValue(AllowDiscordShutdownProperty);
|
||||
this.ClearValue(AllowDiscordStartProperty);
|
||||
this.ClearValue(AllowDiscordStopProperty);
|
||||
this.ClearValue(AllowDiscordUpdateProperty);
|
||||
}
|
||||
|
||||
public void ResetEngramsSection()
|
||||
{
|
||||
this.ClearValue(AutoUnlockAllEngramsProperty);
|
||||
|
|
@ -5695,6 +5708,9 @@ namespace ServerManagerTool.Lib
|
|||
case ServerProfileCategory.AutomaticManagement:
|
||||
SyncAutomaticManagement(sourceProfile);
|
||||
break;
|
||||
case ServerProfileCategory.DiscordBot:
|
||||
SyncDiscordBot(sourceProfile);
|
||||
break;
|
||||
case ServerProfileCategory.Rules:
|
||||
SyncRulesSection(sourceProfile);
|
||||
break;
|
||||
|
|
@ -6016,6 +6032,19 @@ namespace ServerManagerTool.Lib
|
|||
this.DinoSettings.RenderToView();
|
||||
}
|
||||
|
||||
private void SyncDiscordBot(ServerProfile sourceProfile)
|
||||
{
|
||||
this.SetValue(DiscordChannelIdProperty, sourceProfile.DiscordChannelId);
|
||||
this.SetValue(DiscordAliasProperty, sourceProfile.DiscordAlias);
|
||||
|
||||
this.SetValue(AllowDiscordBackupProperty, sourceProfile.AllowDiscordBackup);
|
||||
this.SetValue(AllowDiscordRestartProperty, sourceProfile.AllowDiscordRestart);
|
||||
this.SetValue(AllowDiscordShutdownProperty, sourceProfile.AllowDiscordShutdown);
|
||||
this.SetValue(AllowDiscordStartProperty, sourceProfile.AllowDiscordStart);
|
||||
this.SetValue(AllowDiscordStopProperty, sourceProfile.AllowDiscordStop);
|
||||
this.SetValue(AllowDiscordUpdateProperty, sourceProfile.AllowDiscordUpdate);
|
||||
}
|
||||
|
||||
private void SyncEngramsSection(ServerProfile sourceProfile)
|
||||
{
|
||||
this.SetValue(AutoUnlockAllEngramsProperty, sourceProfile.AutoUnlockAllEngrams);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue