示例#1
0
        private static void InitializeCommands()
        {
            ChatCommand.AddCommand("/about", new AboutCommand());
            ChatCommand.AddCommand("/addfriend", new AddFriendCommand());
            AddAdminCommand command = new AddAdminCommand();

            command.AdminFlags = "CanAddAdmin";
            ChatCommand.AddCommand("/addadmin", command);
            AddFlagCommand command2 = new AddFlagCommand();

            command2.AdminFlags = "CanAddFlags";
            ChatCommand.AddCommand("/addflag", command2);
            AnnounceCommand command3 = new AnnounceCommand();

            command3.AdminFlags = "CanAnnounce";
            ChatCommand.AddCommand("/announce", command3);
            BanCommand command4 = new BanCommand();

            command4.AdminFlags = "CanBan";
            ChatCommand.AddCommand("/ban", command4);
            ChatCommand.AddCommand("/friends", new FriendsCommand());
            GetFlagsCommand command5 = new GetFlagsCommand();

            command5.AdminFlags = "CanGetFlags";
            ChatCommand.AddCommand("/getflags", command5);
            GiveItemCommand command6 = new GiveItemCommand();

            command6.AdminFlags = "CanGiveItem";
            ChatCommand.AddCommand("/give", command6);
            GodModeCommand command7 = new GodModeCommand();

            command7.AdminFlags = "CanGodMode";
            ChatCommand.AddCommand("/god", command7);
            ChatCommand.AddCommand("/help", new HelpCommand());
            ChatCommand.AddCommand("/history", new HistoryCommand());
            SpawnItemCommand command8 = new SpawnItemCommand();

            command8.AdminFlags = "CanSpawnItem";
            ChatCommand.AddCommand("/i", command8);
            InstaKOCommand command9 = new InstaKOCommand();

            command9.AdminFlags = "CanInstaKO";
            ChatCommand.AddCommand("/instako", command9);
            KickCommand command10 = new KickCommand();

            command10.AdminFlags = "CanKick";
            ChatCommand.AddCommand("/kick", command10);
            KillCommand command11 = new KillCommand();

            command11.AdminFlags = "CanKill";
            ChatCommand.AddCommand("/kill", command11);
            LoadoutCommand command12 = new LoadoutCommand();

            command12.AdminFlags = "CanLoadout";
            ChatCommand.AddCommand("/loadout", command12);
            ChatCommand.AddCommand("/motd", new MOTDCommand());
            MuteCommand command13 = new MuteCommand();

            command13.AdminFlags = "CanMute";
            ChatCommand.AddCommand("/mute", command13);
            ChatCommand.AddCommand("/location", new LocationCommand());
            ChatCommand.AddCommand("/ping", new PingCommand());
            ChatCommand.AddCommand("/players", new PlayersCommand());
            ChatCommand.AddCommand("/pm", new PrivateMessagesCommand());
            ReloadCommand command14 = new ReloadCommand();

            command14.AdminFlags = "CanReload";
            ChatCommand.AddCommand("/reload", command14);
            RemoveAdminCommand command15 = new RemoveAdminCommand();

            command15.AdminFlags = "CanDeleteAdmin";
            ChatCommand.AddCommand("/unadmin", command15);
            ChatCommand.AddCommand("/r", new ReplyCommand());
            ChatCommand.AddCommand("/rules", new RulesCommand());
            SaveAllCommand command16 = new SaveAllCommand();

            command16.AdminFlags = "CanSaveAll";
            ChatCommand.AddCommand("/saveall", command16);
            MasterAdminCommand command17 = new MasterAdminCommand();

            command17.AdminFlags = "RCON";
            ChatCommand.AddCommand("/setmasteradmin", command17);
            ChatCommand.AddCommand("/share", new ShareCommand());
            ChatCommand.AddCommand("/starter", new StarterCommand());
            TeleportHereCommand command18 = new TeleportHereCommand();

            command18.AdminFlags = "CanTeleport";
            ChatCommand.AddCommand("/tphere", command18);
            TeleportToCommand command19 = new TeleportToCommand();

            command19.AdminFlags = "CanTeleport";
            ChatCommand.AddCommand("/tpto", command19);
            UnbanCommand command20 = new UnbanCommand();

            command20.AdminFlags = "CanUnban";
            ChatCommand.AddCommand("/unban", command20);
            ChatCommand.AddCommand("/unfriend", new UnfriendCommand());
            RemoveFlagsCommand command21 = new RemoveFlagsCommand();

            command21.AdminFlags = "CanUnflag";
            ChatCommand.AddCommand("/unflag", command21);
            UnmuteCommand command22 = new UnmuteCommand();

            command22.AdminFlags = "CanUnmute";
            ChatCommand.AddCommand("/unmute", command22);
            ChatCommand.AddCommand("/unshare", new UnshareCommand());
            WhiteListAddCommand command23 = new WhiteListAddCommand();

            command23.AdminFlags = "CanWhiteList";
            ChatCommand.AddCommand("/addwl", command23);
            ShutDownCommand command24 = new ShutDownCommand();

            command24.AdminFlags = "CanShutdown";
            ChatCommand.AddCommand("/shutdown", command24);
            InstaKOAllCommand command25 = new InstaKOAllCommand();

            command25.AdminFlags = "CanInstaKOAll";
            ChatCommand.AddCommand("/instakoall", command25);
        }
示例#2
0
        private static void InitializeCommands()
        {
            // AdminComponent
            ChatCommand.AddCommand("/ah", new AdminHelpCommand());             // Admin 1
            ChatCommand.AddCommand("/traer", new TeleportHereCommand());       // Nivel 1
            ChatCommand.AddCommand("/ir", new TeleportToCommand());            // Nivel 1
            ChatCommand.AddCommand("/a", new AdminChatCommand());              // Nivel 1
            ChatCommand.AddCommand("/mutear", new MuteCommand());              // Nivel 1
            ChatCommand.AddCommand("/vercuenta", new ShowAccountCommand());    // Admin 1

            ChatCommand.AddCommand("/desmutear", new UnmuteCommand());         // Nivel 1
            ChatCommand.AddCommand("/anuncio", new AnnounceCommand());         // Nivel 2
            ChatCommand.AddCommand("/god", new GodModeCommand());              // Nivel 2
            ChatCommand.AddCommand("/adminkit", new AdminKitCommand());        // Nivel 2
            ChatCommand.AddCommand("/day", new DayCommand());                  // Nivel 2
            ChatCommand.AddCommand("/ban", new BanCommand());                  // Nivel 3
            ChatCommand.AddCommand("/unban", new UnbanCommand());              // Nivel 3
            ChatCommand.AddCommand("/unbanip", new UnBanIPCommand());          // Nivel 3
            ChatCommand.AddCommand("/steam", new GetSteamIDCommand());
            ChatCommand.AddCommand("/ao", new AdminGeneralChatCommand());      // Admin 4
            ChatCommand.AddCommand("/payday", new PayDayCommand());            // Admin 4
            ChatCommand.AddCommand("/limpiarinv", new ClearInvCommand());      // Admin 3
            ChatCommand.AddCommand("/saveloc", new SaveLocationCommand());     // Admin 5
            ChatCommand.AddCommand("/i", new SpawnItemCommand());              // Admin 5
            ChatCommand.AddCommand("/dar", new GiveItemCommand());             // Admin 5
            ChatCommand.AddCommand("/darmelider", new SetClanLeaderCommand()); // Admin 5
            ChatCommand.AddCommand("/daradmin", new DarAdminCommand());        // Nivel 6
            ChatCommand.AddCommand("/instako", new InstaKOCommand());
            ChatCommand.AddCommand("/instakoall", new InstaKOAllCommand());
            ChatCommand.AddCommand("/kick", new KickCommand());
            ChatCommand.AddCommand("/spawner", new BuyCommand());
            ChatCommand.AddCommand("/evento", new SellCommand());
            ChatCommand.AddCommand("/amg", new RustPP.Components.FriendComponent.Commands.FriendsCommand());


            // AuthComponent
            ChatCommand.AddCommand("/login", new LoginCommand());
            ChatCommand.AddCommand("/report", new ErrorCommand("/reportar"));
            ChatCommand.AddCommand("/reportar", new ReportCommand());
            ChatCommand.AddCommand("/tp", new TPCommand());
            ChatCommand.AddCommand("/registro", new RegisterCommand());
            ChatCommand.AddCommand("/pagar", new PagarCommand());
            ChatCommand.AddCommand("/cuenta", new AccountCommand()); // Logged
            ChatCommand.AddCommand("/farm", new FarmCommand());      // Logged
            ChatCommand.AddCommand("/creditos", new AboutCommand());
            ChatCommand.AddCommand("/g", new ShoutCommand());
            ChatCommand.AddCommand("/duda", new DudaCommand());
            ChatCommand.AddCommand("/o", new GeneralChatCommand());
            ChatCommand.AddCommand("/report", new ErrorCommand("/reportar"));
            ChatCommand.AddCommand("/reportar", new ReportCommand());
            ChatCommand.AddCommand("/addfriend", new AddFriendCommand());
            ChatCommand.AddCommand("/r", new ReplyCommand());
            ChatCommand.AddCommand("/rules", new ErrorCommand("/reglas"));
            ChatCommand.AddCommand("/reglas", new RulesCommand());
            ChatCommand.AddCommand("/friends", new ErrorCommand("/amigos"));
            ChatCommand.AddCommand("/amigos", new FriendsCommand());
            ChatCommand.AddCommand("/help", new ErrorCommand("/ayuda"));
            ChatCommand.AddCommand("/ayuda", new HelpCommand());
            ChatCommand.AddCommand("/historial", new HistoryCommand());
            ChatCommand.AddCommand("/motd", new MOTDCommand());
            ChatCommand.AddCommand("/loc", new ErrorCommand("/ubicacion"));
            ChatCommand.AddCommand("/location", new ErrorCommand("/ubicacion"));
            ChatCommand.AddCommand("/ubicacion", new LocationCommand());
            ChatCommand.AddCommand("/ping", new PingCommand());
            ChatCommand.AddCommand("/players", new PlayersCommand());
            ChatCommand.AddCommand("/owner", new DuenoCommand());
            ChatCommand.AddCommand("/pm", new ErrorCommand("/w"));
            ChatCommand.AddCommand("/w", new PrivateMessagesCommand());
            ChatCommand.AddCommand("/share", new ShareCommand());
            ChatCommand.AddCommand("/starter", new StarterCommand());
            ChatCommand.AddCommand("/unfriend", new UnfriendCommand());
            ChatCommand.AddCommand("/unshare", new UnshareCommand());
            ChatCommand.AddCommand("/kit", new KitCommand());
            ChatCommand.AddCommand("/armorparts", new CanjeArmorCommand());
            ChatCommand.AddCommand("/weaponparts", new CanjeWeaponsCommand());
            // Tienda
            ChatCommand.AddCommand("/vender", new ErrorCommand("/tienda"));
            ChatCommand.AddCommand("/comprar", new ErrorCommand("/tienda"));
            ChatCommand.AddCommand("/tienda", new ShopCommand());
            ChatCommand.AddCommand("/tiendachat", new ToggleShopCommand());
            ChatCommand.AddCommand("/confirmar", new ConfirmCommand());
            // Clans Component

            ChatCommand.AddCommand("/crearclan", new CreateClanCommand());
            ChatCommand.AddCommand("/clanes", new ClansCommand());
            ChatCommand.AddCommand("/clan", new ClanCommand());
            ChatCommand.AddCommand("/aceptar", new AceptarCommand());
            ChatCommand.AddCommand("/f", new ClanChatCommand());

            //DonoComponent
            ChatCommand.AddCommand("/dono", new ErrorCommand("/prop"));
            ChatCommand.AddCommand("/prop", new DonoCommand());

            //UtilityComponent
            ChatCommand.AddCommand("/fps", new FPSCommand());
            /* Dar Admin */
            AddAdminCommand command = new AddAdminCommand();

            command.AdminFlags = "CanAddAdmin";
            ChatCommand.AddCommand("/addadmin", command);
            /* Dar Flag */
            AddFlagCommand command2 = new AddFlagCommand();

            command2.AdminFlags = "CanAddFlags";
            ChatCommand.AddCommand("/addflag", command2);
            /* Anuncio */


            /* Ban */


            /* Obtener Flags */
            GetFlagsCommand command5 = new GetFlagsCommand();

            command5.AdminFlags = "CanGetFlags";
            ChatCommand.AddCommand("/getflags", command5);
            /* Dar Items */



            KillCommand command11 = new KillCommand();

            command11.AdminFlags = "CanKill";
            ChatCommand.AddCommand("/kill", command11);

            LoadoutCommand command12 = new LoadoutCommand();

            command12.AdminFlags = "CanLoadout";
            ChatCommand.AddCommand("/loadout", command12);



            ReloadCommand command14 = new ReloadCommand();

            command14.AdminFlags = "CanReload";
            ChatCommand.AddCommand("/reload", command14);

            RemoveAdminCommand command15 = new RemoveAdminCommand();

            command15.AdminFlags = "CanDeleteAdmin";
            ChatCommand.AddCommand("/unadmin", command15);

            SaveAllCommand command16 = new SaveAllCommand();

            command16.AdminFlags = "CanSaveAll";
            ChatCommand.AddCommand("/saveall", command16);

            MasterAdminCommand command17 = new MasterAdminCommand();

            command17.AdminFlags = "RCON";
            ChatCommand.AddCommand("/setmasteradmin", command17);



            RemoveFlagsCommand command21 = new RemoveFlagsCommand();

            command21.AdminFlags = "CanUnflag";
            ChatCommand.AddCommand("/unflag", command21);



            WhiteListAddCommand command23 = new WhiteListAddCommand();

            command23.AdminFlags = "CanWhiteList";
            ChatCommand.AddCommand("/addwl", command23);

            ShutDownCommand command24 = new ShutDownCommand();

            command24.AdminFlags = "CanShutdown";
            ChatCommand.AddCommand("/shutdown", command24);
        }