private void launchBoot() { if (network != null) { network.Dispose(); } network = new MasterNetwork(); if (!string.IsNullOrEmpty(BotPath)) { var extension = Path.GetExtension(BotPath); switch (extension) { case ".exe": network.LaunchBot(BotPath); break; case ".js": network.LaunchNodeBot(BotPath); break; } } else { network.LaunchDefaultBot(); } }
public MainViewModel() { Velocity = 500; loadLocalSettings(); network = new MasterNetwork(); }