No description
Find a file
Ethan Lane 730af871a0
All checks were successful
Deploy To Stage / build (push) Successful in 59s
Deploy To Stage / deploy (push) Successful in 17s
Update the drop mechanic to take currency on drop instead of claim (#428)
# Description

- Update the drop mechanic to take currency on drop instead of claim
- Update the time until anyone can claim the card to 2 minutes
- Remove the restriction that the last drop can only be claimed by the user who dropped it
    - Now just controlled by the 2 minutes rule

#415

## Type of change

Please delete options that are not relevant.

- [x] New feature (non-breaking change which adds functionality)

# How Has This Been Tested?

Please describe the tests that you ran to verify the changes. Provide instructions so we can reproduce. Please also list any relevant details to your test configuration.

# Checklist

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that provde my fix is effective or that my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged and published in downstream modules

Reviewed-on: #428
Reviewed-by: VylpesTester <tester@vylpes.com>
Co-authored-by: Ethan Lane <ethan@vylpes.com>
Co-committed-by: Ethan Lane <ethan@vylpes.com>
2025-05-16 17:37:57 +01:00
.forgejo/workflows Fix remote image urls not showing up in image grids (#430) 2025-04-20 10:52:54 +01:00
.gitea Create initial bot framework (#7) 2023-08-19 16:56:22 +01:00
database Create effects concept (#402) 2024-11-09 21:31:11 +00:00
docs Document the google drive sync process (#328) 2024-08-02 18:20:23 +01:00
scripts Migrate to woodpecker (#150) 2024-01-26 21:02:17 +00:00
src Update the drop mechanic to take currency on drop instead of claim (#428) 2025-05-16 17:37:57 +01:00
tests Update the drop mechanic to take currency on drop instead of claim (#428) 2025-05-16 17:37:57 +01:00
.drone.yml Add ESLint and fix issues (#133) 2024-01-05 19:26:44 +00:00
.env.example Merge branch 'main' into develop 2025-04-22 15:40:02 +01:00
.gitignore Merge branch 'hotfix/0.5.2' into develop 2024-05-29 17:40:36 +01:00
.woodpecker.yml Update woodpecker config to use new ip 2024-04-23 19:42:33 +01:00
docker-compose.yml Migrate to forgejo runner 2024-04-28 17:34:42 +01:00
eslint.config.mjs Fix linter 2024-10-28 12:06:27 +00:00
jest.config.json Create initial bot framework (#7) 2023-08-19 16:56:22 +01:00
jest.setup.js Create effects concept (#402) 2024-11-09 21:31:11 +00:00
package.json Merge branch 'main' into develop 2025-04-22 15:40:02 +01:00
README.md Document how to start the bot (#322) 2024-07-26 18:32:12 +01:00
renovate.json Add to renovate config to add label on PRs (#128) 2023-12-29 21:03:15 +00:00
tsconfig.json Create initial bot framework (#7) 2023-08-19 16:56:22 +01:00
yarn.lock Fix linting 2025-04-25 09:17:36 +01:00

Card Drop

Card Drop is a Discord Bot designed to allow users to "drop" random cards into a channel and have the ability to claim them for themselves or let others if they so choose.

The cards are randomly chosen based on weights of their card type (i.e. Bronze is more common than Gold). The user who ran the drop command has 5 minutes to choose if they want the card to themselves before its claimable by anyone, or until the drop command is ran again.

Installation

Downloads of the latest version can be found from the GitHub Releases or Forgejo Releases page.

Copy the config template file and fill in the strings.

Requirements

  • NodeJS
  • Yarn
  • Docker

Usage

Install the dependencies and build the app:

yarn Install
yarn build

Setup the database (Recommended to use the docker-compose file

docker compose up -d

Copy and edit the settings file

cp .env.template .env

NOTE: Make sure you do not check in these files! These contain sensitive information and should be treated as private.

If you're not using DB_SYNC=true in .env, make sure to migrate the database

yarn db:up

Start the bot

yarn start