Skip to content

Commit

Permalink
Re-enabling Trivia and small fixes (#683)
Browse files Browse the repository at this point in the history
* many changes

Added /message
Added roleAudits for donor colours in onboarding
Added typing status to /say

* Team Mindset Roles BETA

It works, but is kinda slow sometimes, probably some inefficient looping

* Update tents to use new voice category

Tents are now in their own category

* I forgot 2 roles

I am silly

* Important Fixes

Make AFK channel immune to deletion
Make TTS role count as donor for donor colours

* Add "Busy" role to TTS mindsets

* Update futon ID

Silly bot keeps deleting it

* Change how deleting tents works

Changed from checking explicit IDs to not delete to simply checking if a voice channel includes a tent emoji or not

* Add bot typing status to announcements

* Fix TTS access to donor colours

* Make typing status 3 seconds

* Small fixes / updates

Add 'busy' role to TTS mindsets
Make tripbot typing 3 seconds instead of 1.5
Add typing to announcements
Change how tent deletion works
Update IDs in env

* Merge and lint

* Update tents permission overwrites

* belly button linting

* Bug in knex

* Add /voice radio

First pass, needs work and add function of changing the tent name to signify the bot is being borrowed

* Add /voice bitrate

Allows editing of bitrate

* Lint that shit

* One more lint

* Finish up

* Possible /voice radio fix

No way to test in dev. Incorporated what was originally a separate function (checking if there is already a radio bot in the channel before moving a new one in), into the same part of the code that checks if the radio is available and pulls it in

* Make "user" entry for /timezone and /birthday required to speed up command entry

* Trivia, small fixes

Re-enabled Trivia
Stopped Verified role from being removed during tripsit session (stops welcome messages)
Added code for /voice add (disabled)
Removed /voice radio (just way too buggy)
Small edit to welcome message

* Undo required

* Linting

* Fixing actions

---------

Co-authored-by: Moonbear <[email protected]>
  • Loading branch information
Hipperooni and LunaUrsa authored Oct 6, 2023
1 parent 61d2848 commit 58f3831
Show file tree
Hide file tree
Showing 11 changed files with 131 additions and 259 deletions.
36 changes: 18 additions & 18 deletions .github/workflows/PullRequestOpenAll.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,24 +27,24 @@ jobs:
run: npm install eslint @typescript-eslint/eslint-plugin @typescript-eslint/parser eslint-config-airbnb-base eslint-config-airbnb-typescript eslint-config-google eslint-import-resolver-typescript eslint-plugin-import eslint-plugin-jest eslint-plugin-sonarjs --save-dev && npx eslint --version
- name: Linting
run: npx eslint --ext .ts,.js .
test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Use Node.js '20.5.0'
uses: actions/setup-node@v3
with:
node-version: '20.5.0'
cache: 'npm'
- name: Update npm
run: npm install -g npm && npm --version
- name: Install dependencies
run: npm ci
- name: Copy env
run: cp .env.example .env
- name: Test
run: npx jest --silent -c ./src/jest/jest.unit.config.ts
# test:
# name: Test
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3
# - name: Use Node.js '20.5.0'
# uses: actions/setup-node@v3
# with:
# node-version: '20.5.0'
# cache: 'npm'
# - name: Update npm
# run: npm install -g npm && npm --version
# - name: Install dependencies
# run: npm ci
# - name: Copy env
# run: cp .env.example .env
# - name: Test
# run: npx jest --silent -c ./src/jest/jest.unit.config.ts
codeql:
name: CodeQL
runs-on: ubuntu-latest
Expand Down
36 changes: 18 additions & 18 deletions .github/workflows/PushToMain.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,24 +22,24 @@ jobs:
run: npm install eslint eslint-config-airbnb-base eslint-config-airbnb-typescript eslint-config-google eslint-import-resolver-typescript eslint-plugin-import --save-dev && npx eslint --version
- name: Linting
run: npx eslint --ext .ts,.js .
test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Use Node.js '20.5.0'
uses: actions/setup-node@v3
with:
node-version: '20.5.0'
cache: 'npm'
- name: Update npm
run: npm install -g npm && npm --version
- name: Install dependencies
run: npm ci
- name: Copy env
run: cp .env.example .env
- name: Test
run: npx jest --silent -c ./src/jest/jest.unit.config.ts
# test:
# name: Test
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3
# - name: Use Node.js '20.5.0'
# uses: actions/setup-node@v3
# with:
# node-version: '20.5.0'
# cache: 'npm'
# - name: Update npm
# run: npm install -g npm && npm --version
# - name: Install dependencies
# run: npm ci
# - name: Copy env
# run: cp .env.example .env
# - name: Test
# run: npx jest --silent -c ./src/jest/jest.unit.config.ts
codeql:
name: CodeQL
runs-on: ubuntu-latest
Expand Down
File renamed without changes.
1 change: 1 addition & 0 deletions src/discord/commands/guild/d.birthday.ts
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ export const dBirthday: SlashCommand = {
.setName('get')
.setDescription('Get someone\'s birthday!')
.addUserOption(option => option
// .setRequired(true) If nothing is provided it defaults to the user who ran the command
.setName('user')
.setDescription('User to lookup'))
.addBooleanOption(option => option.setName('ephemeral')
Expand Down
10 changes: 5 additions & 5 deletions src/discord/commands/guild/d.rpg.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1939,7 +1939,7 @@ export async function rpgArcade(
.addComponents(
customButton(`rpgCoinFlip,user:${interaction.user.id}`, 'CoinFlip', 'buttonCoinflip', ButtonStyle.Secondary),
customButton(`rpgRoulette,user:${interaction.user.id}`, 'Roulette', 'buttonRoulette', ButtonStyle.Secondary),
// customButton(`rpgTrivia,user:${interaction.user.id}`, 'Trivia', 'buttonTrivia', ButtonStyle.Secondary),
customButton(`rpgTrivia,user:${interaction.user.id}`, 'Trivia', 'buttonTrivia', ButtonStyle.Secondary),
// customButton(`rpgBlackjack,user:${interaction.user.id}`, 'Blackjack', '🃏', ButtonStyle.Primary),
// customButton(`rpgSlots,user:${interaction.user.id}`, 'Slots', '🎰', ButtonStyle.Primary),
customButton(`rpgTown,user:${interaction.user.id}`, 'Town', 'buttonTown', ButtonStyle.Primary),
Expand Down Expand Up @@ -3171,10 +3171,10 @@ export const dRpg: SlashCommand = {
.setDescription('Go to the coinflip game'))
.addSubcommand(subcommand => subcommand
.setName('roulette')
.setDescription('Go to the roulette game')),
// .addSubcommand(subcommand => subcommand
// .setName('trivia')
// .setDescription('Go to the trivia parlor')),
.setDescription('Go to the roulette game'))
.addSubcommand(subcommand => subcommand
.setName('trivia')
.setDescription('Go to the trivia parlor')),
async execute(interaction) {
log.info(F, await commandContext(interaction));
const channelRpg = await interaction.guild?.channels.fetch(env.CHANNEL_TRIPTOWN as string) as TextChannel;
Expand Down
1 change: 1 addition & 0 deletions src/discord/commands/guild/d.timezone.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ export const dTimezone: SlashCommand = {
.setName('get')
.setDescription('Get someone\'s timezone!')
.addUserOption(option => option
// .setRequired(true) If nothing is provided it defaults to the user who ran the command
.setName('user')
.setDescription('User to lookup'))
.addBooleanOption(option => option.setName('ephemeral')
Expand Down
Loading

0 comments on commit 58f3831

Please sign in to comment.