diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 543ecca..7599a7a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -2,11 +2,11 @@ name: Build on: push: - branches: [ "dev" ] + branches: [ "main" ] paths-ignore: - '**/README.md' pull_request: - branches: [ "dev" ] + branches: [ "main" ] paths-ignore: - '**/README.md' @@ -96,7 +96,6 @@ jobs: name: "CS2-SimpleAdmin - Build ${{ env.BUILD_NUMBER }}" tag: "fork-build-${{ env.BUILD_NUMBER }}-${{ github.run_id }}" body: | - # Note: This is a dev build. Use with caution Place files in addons/counterstrikesharp After first launch, configure the plugins in the respective configs: - CS2-SimpleAdmin: addons/counterstrikesharp/configs/plugins/CS2-SimpleAdmin/CS2-SimpleAdmin.json diff --git a/CS2-SimpleAdmin/Menus/CustomCommandsMenu.cs b/CS2-SimpleAdmin/Menus/CustomCommandsMenu.cs index 15b053d..0a9635e 100644 --- a/CS2-SimpleAdmin/Menus/CustomCommandsMenu.cs +++ b/CS2-SimpleAdmin/Menus/CustomCommandsMenu.cs @@ -42,9 +42,9 @@ public static class CustomCommandsMenu (buttons, menu, selected) => { if (selected == null) return; - if (buttons == MenuButtons.Select && selected.Option >= 0 && selected.Option < customCommands.Count) + if (buttons == MenuButtons.Select && menu.Option >= 0 && menu.Option < customCommands.Count) { - var cmd = customCommands[selected.Option]; + var cmd = customCommands[menu.Option]; Helper.TryLogCommandOnDiscord(admin, cmd.Command); if (cmd.ExecuteOnClient) diff --git a/CS2-SimpleAdmin/Menus/ReasonMenu.cs b/CS2-SimpleAdmin/Menus/ReasonMenu.cs index 2e4d8bd..1e81bef 100644 --- a/CS2-SimpleAdmin/Menus/ReasonMenu.cs +++ b/CS2-SimpleAdmin/Menus/ReasonMenu.cs @@ -41,9 +41,9 @@ public static class ReasonMenu (buttons, menu, selected) => { if (selected == null) return; - if (buttons == MenuButtons.Select && selected.Option >= 0 && selected.Option < reasons.Count) + if (buttons == MenuButtons.Select && menu.Option >= 0 && menu.Option < reasons.Count) { - onSelectAction(admin, player, reasons[selected.Option]); + onSelectAction(admin, player, reasons[menu.Option]); } }, true, @@ -82,9 +82,9 @@ public static class ReasonMenu (buttons, menu, selected) => { if (selected == null) return; - if (buttons == MenuButtons.Select && selected.Option >= 0 && selected.Option < reasons.Count) + if (buttons == MenuButtons.Select && menu.Option >= 0 && menu.Option < reasons.Count) { - onSelectAction(admin, player, reasons[selected.Option]); + onSelectAction(admin, player, reasons[menu.Option]); } }, true,