public async void RunAutoHangerOverride(String[] overrides)
        {
            bool staticgrids   = false;
            bool largegrids    = false;
            bool smallgrids    = false;
            bool hangerLargest = false;
            bool saveAll       = false;

            foreach (var _override in overrides)
            {
                if (_override == "staticgrids")
                {
                    staticgrids = true;
                }
                else if (_override == "largegrids")
                {
                    largegrids = true;
                }
                else if (_override == "smallgrids")
                {
                    smallgrids = true;
                }
                else if (_override == "hangerLargest")
                {
                    hangerLargest = true;
                }
                else if (_override == "saveAll")
                {
                    saveAll = true;
                }
            }
            await HangarCommandSystem.RunAdminTaskAsync(() => AutoHangar.RunAutoHangar(saveAll, staticgrids, largegrids, smallgrids, hangerLargest));
        }
Beispiel #2
0
        public async void Load(string ID, bool LoadNearPlayer = false)
        {
            if (Context.Player == null)
            {
                Context.Respond("This is a player only command!");
                return;
            }

            PlayerChecks User = new PlayerChecks(Context);
            await HangarCommandSystem.RunTaskAsync(() => User.LoadGrid(ID, LoadNearPlayer), Context);
        }
Beispiel #3
0
        public async void Info(string ID = "")
        {
            if (Context.Player == null)
            {
                Context.Respond("This is a player only command!");
                return;
            }

            PlayerChecks User = new PlayerChecks(Context);
            await HangarCommandSystem.RunTaskAsync(() => User.DetailedInfo(ID), Context);
        }
Beispiel #4
0
        public async void SaveGrid()
        {
            if (Context.Player == null)
            {
                Context.Respond("This is a player only command!");
                return;
            }


            PlayerChecks User = new PlayerChecks(Context);
            await HangarCommandSystem.RunTaskAsync(() => User.SaveGrid(), Context);
        }
 public async void SaveAllGrids()
 {
     await HangarCommandSystem.RunAdminTaskAsync(() => AutoHangar.RunAutoHangar(true, true, true, true, true));
 }
 public async void SaveGrid(string GridName = "")
 {
     AdminChecks User = new AdminChecks(Context);
     await HangarCommandSystem.RunAdminTaskAsync(() => User.SaveGrid(GridName));
 }
        public void Remove(int ID)
        {
            PlayerChecks User = new PlayerChecks(Context);

            HangarCommandSystem.RunTask(delegate { User.RemoveGrid(ID); }, Context.Player?.SteamUserId);
        }
        public void Load(int ID, bool LoadNearPlayer = false)
        {
            PlayerChecks User = new PlayerChecks(Context);

            HangarCommandSystem.RunTask(delegate { User.LoadGrid(ID, LoadNearPlayer); }, Context.Player?.SteamUserId);
        }
 public async void RunAutoHangar()
 {
     await HangarCommandSystem.RunAdminTaskAsync(() => AutoHangar.RunAutoHangar(false, Hangar.Config.AutoHangarStaticGrids, Hangar.Config.AutoHangarLargeGrids, Hangar.Config.AutoHangarSmallGrids, Hangar.Config.KeepPlayersLargestGrid));
 }
 public async void Sync(string NameOrSteamID)
 {
     AdminChecks User = new AdminChecks(Context);
     await HangarCommandSystem.RunAdminTaskAsync(() => User.SyncHangar(NameOrSteamID));
 }
        public void SaveGrid(string GridName = "")
        {
            AdminChecks User = new AdminChecks(Context);

            HangarCommandSystem.RunTask(delegate { User.SaveGrid(GridName); }, 1);
        }
 public void RunAutoHangar()
 {
     HangarCommandSystem.RunTask(delegate { AutoHangar.RunAutoHangar(); }, 1);
 }
        public void Remove(string NameOrSteamID, int ID)
        {
            AdminChecks User = new AdminChecks(Context);

            HangarCommandSystem.RunTask(delegate { User.RemoveGrid(NameOrSteamID, ID); }, 1);
        }
        public void SaveGrid(string NameOrSteamID, int ID, bool FromSavePos = true)
        {
            AdminChecks User = new AdminChecks(Context);

            HangarCommandSystem.RunTask(delegate { User.LoadGrid(NameOrSteamID, ID, FromSavePos); });
        }
        public void Sync(string NameOrSteamID)
        {
            AdminChecks User = new AdminChecks(Context);

            HangarCommandSystem.RunTask(delegate { User.SyncHangar(NameOrSteamID); }, 1);
        }
 public async void LoadGrid(string NameOrSteamID, int ID, bool FromSavePos = true)
 {
     AdminChecks User = new AdminChecks(Context);
     await HangarCommandSystem.RunAdminTaskAsync(() => User.LoadGrid(NameOrSteamID, ID, FromSavePos));
 }
 public async void Remove(string NameOrSteamID, int ID)
 {
     AdminChecks User = new AdminChecks(Context);
     await HangarCommandSystem.RunAdminTaskAsync(() => User.RemoveGrid(NameOrSteamID, ID));
 }
        public void ListGrids(string NameOrSteamID)
        {
            AdminChecks User = new AdminChecks(Context);

            HangarCommandSystem.RunTask(delegate { User.ListGrids(NameOrSteamID); });
        }
 public async void SyncAll()
 {
     AdminChecks User = new AdminChecks(Context);
     await HangarCommandSystem.RunAdminTaskAsync(() => User.SyncAll());
 }
        public void Info(int ID = 0)
        {
            PlayerChecks User = new PlayerChecks(Context);

            HangarCommandSystem.RunTask(delegate { User.DetailedInfo(ID); }, Context.Player?.SteamUserId);
        }
        public void ListGrids()
        {
            PlayerChecks User = new PlayerChecks(Context);

            HangarCommandSystem.RunTask(delegate { User.ListGrids(); }, Context.Player?.SteamUserId);
        }
Beispiel #22
0
 public async void ListGrids()
 {
     PlayerChecks User = new PlayerChecks(Context);
     await HangarCommandSystem.RunTaskAsync(() => User.ListGrids(), Context);
 }