Minz
0af9038b6e
DB: Add and migrate columns in preparation for patreon perks
...
Renaming nextDrop/Pull required a bit of a hack resulting in
it no longer having a default value.
2023-03-09 23:29:46 +01:00
Minz
4c4a581a03
Collection: Fix username not showing as the title
...
FIXME: Find a better way to pass usernames.
2023-03-09 13:24:48 +01:00
Minz
a12c0a8211
Profile: (Amend) Fix replace/encode order of custom status
...
Replacement happened before encoding, causing the entire status
string to be encoded, including the SVG tags themselves.
2023-03-09 12:25:48 +01:00
Minz
af017bf125
Profile: encode special XML characters in usernames and descriptions
...
this fixes the problem of profiles not rendering when a user has
special characters such as < or > in their name or status.
We didn't implement proper sanitization considering this method of
profile rendering is going to be obsolete soon.
2023-03-09 12:14:49 +01:00
Minz
c93ffee69c
Drop: Increase timeout to a minute
2023-03-09 10:05:36 +01:00
Minz
bb6f9e7d3f
Badges: Add view/list commands and search util
2023-02-27 01:57:26 +01:00
Minz
06575d280f
DB: Add models and migration for badges
2023-02-27 01:56:44 +01:00
Minz
1a5e7c1b62
View: Move search code into separate Util module
2023-02-26 18:20:50 +01:00
Minz
bb9ffd6b43
View: Allow searching cards by character name
2023-02-26 16:50:39 +01:00
Minz
4e98d744ce
Assets: New card cover
2023-02-26 16:24:42 +01:00
Minz
51f8d03a69
Collection: Fix total count when grouping dupes
...
using array length if group is true. Fixes #47
2023-02-26 14:49:59 +01:00
Minz
1dde3a0a8c
DB: Add auto_increment to Characters and Groups
...
starting at a very high ID because I was too lazy to migrate existing data
as it is referenced in json blobs.
Part of Issue #43
2023-02-25 01:55:27 +01:00
Minz
765e63b90e
Generalize labels and options
2023-02-25 00:26:04 +01:00
Minz
50da918be5
NPM: Update to fix sequelize vulnerabilities
...
Dependabot alerts: 3,4,5,7
2023-02-24 23:51:50 +01:00
Minz
3b67c140af
DB: Generalize table and model names
2023-02-24 23:51:32 +01:00
Minz
9661c65b27
Collection: Add options to filter by name,band and quality
2023-01-19 23:57:04 +01:00
Minz
98d4f5c2ac
Edit: Use unique interaction IDs for each edit action
...
Resolves #30 where follow up edits would fail if previous
modals have been canceled/dismissed
2023-01-16 17:11:16 +01:00
Minz
1548ecf73b
Collection: Only allow the initator to use the components
...
Fixes #40
2023-01-16 12:55:28 +01:00
Minz
f38b6abe19
View: Omit empty components prop for non-elevated users
...
Fixes #39
2023-01-12 15:06:56 +01:00
Minz
692904d462
Trade: Add tradehistories table
...
and create rows at the end of each trade.
Both users traded cards are logged.
2023-01-12 14:43:06 +01:00
Minz
2ef1dfe7a7
Trade: Persist trades in the database
...
using atomic transactions.
If a card happens to not be owned by the trading user, the entire
trade is being rolled back.
Rollback behaviour is a bit weird though, since we have to rollback
manually even in a managed transaction.
2023-01-02 22:49:46 +01:00
Minz
95c3f41fde
Trade: Properly handle trade cancellation and timeouts
...
- Trade finishing states are now handled properly.
- Deferring cancel button press
- A user is on a 2 minute cooldown after a trade finishes or
cancels if he is the one who initiated it.
- Updated emote IDs
2023-01-02 21:04:24 +01:00
Minz
d0535e06ad
Docker: Restart mysql container unless stopped
2023-01-02 19:26:25 +01:00
Minz
c29c018bba
Register: Always defer and update replies
2023-01-02 19:25:36 +01:00
Minz
c866bc08eb
Trade: Add TradeStore and trade flow
...
Adding a TradeStore to keep track of active trades and their states.
Also implements the core trade flow and embed logic.
2022-11-23 17:35:29 +01:00
Minz
78fe0857e8
CardUtils: Add helper to get one-line formatted card info
2022-11-23 17:34:01 +01:00
Minz
42797eb90e
[WIP] Trading and TradingStore implementation 1
2022-11-22 17:15:48 +01:00
Minz
5be326d56a
Added permission levels to all commands
2022-09-29 11:23:15 +02:00
Minz
07b48087b4
Help: Add very basic help command
2022-09-29 11:19:16 +02:00
Minz
cf159c43bc
Docker: Make DB port changeable via .env
2022-09-26 16:21:43 +02:00
Minz
e72b098dab
Docker: Always run migrations on compose up
2022-09-26 16:18:42 +02:00
Minz
b5d2b68294
Stats/View: Add wallet stats and shiny emote to card views
2022-09-26 16:15:20 +02:00
Minz
16bb46403b
Burn: Added card burning for notes and gems
2022-09-26 16:09:23 +02:00
Minz
bbbcaaaf29
User/Debug/Profile: Add primary and secondary currency
2022-09-26 13:15:40 +02:00
Minz
d8905a279a
Drop: Added icons if drop contains FPs or shiny cards as well as the droppers name
2022-09-26 12:22:53 +02:00
Minz
a49a478972
History: Add currency and XP tracking
2022-09-21 17:18:12 +02:00
Minz
dcd05322ca
Merge pull request #31 from JanGross/dependabot/npm_and_yarn/moment-timezone-0.5.37
...
Bump moment-timezone from 0.5.34 to 0.5.37
2022-09-21 14:19:56 +02:00
Minz
c8fb87dc70
View: Handle empty or invalid card IDs. Fixes #24
2022-09-21 13:41:56 +02:00
Minz
dcb7e334e2
History: Add details to drop history and split by type
...
that being 0 for drops and 1 for claims.
Fixes #16
2022-09-21 13:35:43 +02:00
Minz
f021234e45
Profile: Add initial default customStatus and allow empty values
...
Fixes #20
2022-09-21 12:49:21 +02:00
Minz
deee1bf0c4
Collection: Fix empty collection message not showing up
...
Fixes #4
2022-09-21 12:29:12 +02:00
Minz
73fb84c33d
Debug: Defer all debug replies and lock clear_cards in production
2022-09-21 12:22:34 +02:00
Minz
767f5bb761
Stats: Use sourced constants for quality names
2022-09-21 12:13:35 +02:00
Minz
4d97215891
Drop: Fix cooldown formatting ( fixes #15 )
...
Formatted cooldown strings are now properly pluralized
trimmed for zero values and also include seconds.
2022-09-21 11:51:58 +02:00
Minz
f0a0bef7e9
Drop: Always defer drop replies
2022-09-21 11:50:45 +02:00
Minz
73a2df6e74
Drop: Select quality of cards based on drop rates
2022-09-21 11:17:11 +02:00
Minz
fc45908419
Add maintenance mode
2022-09-19 09:02:42 +02:00
Minz
0afedc86e5
View/Edit: Add option to direct edit from character views
2022-09-18 01:21:10 +02:00
Minz
60f4c51353
View: Add mixed view with autocomplete
...
for cards and characters
2022-09-18 00:49:30 +02:00
Minz
f211f4976f
Cleanup some unused debug commands and arguments
2022-09-16 23:08:50 +02:00
Minz
a55ce1b5ff
Edit: Fix path sanitization.
...
Spaces are being replaced with underscores
2022-09-15 22:23:30 +02:00
Minz
820ed99021
Edit: Add command to edit existing records.
...
This currently requires global admin permissions.
Each edit gets persisted in the history table.
2022-09-14 18:25:31 +02:00
Minz
826834ebab
History: Add record history table
2022-09-14 18:24:10 +02:00
Minz
1d4ec09bf8
Collection: Add duplicate grouping
2022-09-14 14:02:39 +02:00
Minz
83947eeafd
Drop: Hightlight first prints and shiny cards in claim messages
2022-09-14 09:27:25 +02:00
Minz
055be119cc
Profile: Show rendering gif placeholder instead of thinking text
...
while the profile is being rendered in the background.
2022-09-13 00:28:14 +02:00
Minz
54aee7624b
Profile: Use sharp to prerender the profile background
...
including the user image. Also introduces axios as a dependency
2022-09-13 00:18:30 +02:00
Minz
494f574048
Profile: Fix call to refactored getLevel function
...
it is now user.level().currentLevel
2022-09-12 23:03:30 +02:00
Minz
d8c18f8b01
User: Fix wrong rounding on level calculation
...
we have to floor it, otherwise we're always one level ahead
2022-09-12 22:22:15 +02:00
Minz
af3f1237c6
Stats: Add stats command to show a users data
...
like cards owned, level progression and date registered
2022-09-12 22:18:53 +02:00
Minz
465f1f3221
Profile: Handle uninitialized customStatus rendering
2022-09-12 20:51:56 +02:00
Minz
7786c84ea7
Profile: Render custom status on profile images
...
A new line is added after each whitespace following each 40th+ character
2022-09-12 14:54:18 +02:00
Minz
c5fddd12cf
Profile: Allow editing of customStatus using the editprofile command
...
Editprofile itself now shows buttons to select different subcommands.
2022-09-12 13:39:06 +02:00
Minz
5ea33b21a0
Profile: Fix discordUser object being of type member if we view our own profile
2022-09-12 10:31:46 +02:00
Minz
dc9502057d
Profile: Add parameter to view some else's profile
2022-09-12 04:12:07 +02:00
Minz
292cd00613
Debug: Add command to alter a users experience
...
Also added the option to pass a user mention instead
of an id as the extUser parameter.
2022-09-12 04:03:04 +02:00
Minz
9106192fd5
User: Fix type mismatch causing xp passed as a string to be appended
...
instead of being added as an increment.
2022-09-12 03:58:51 +02:00
Minz
ed7096fac0
User: Add experience / levels
...
Each drop and claim hands out 10 and 5 xp respectively.
The profile then renders the users current level based on
the formula 0.5 * sqrt(exp)
2022-09-12 03:37:45 +02:00
Minz
fb1f4b346e
Profile: Update profile template
2022-09-12 03:12:24 +02:00
Minz
cd3b50bbe2
Profile: Truncate long usernames
2022-09-12 02:33:41 +02:00
Minz
b34c3e3f09
Git: Exclude cards and imports, add gitkeep for essentiqal cache folders
2022-09-12 00:41:35 +02:00
Minz
d531a3a2d3
Profile: Handle unassigned showcase slots
...
during profile rendering
2022-09-12 00:34:48 +02:00
Minz
2b682fc074
Profile: Composite profile using imagemagick
...
by spawning an external process. Very slow but it works.
2022-09-11 23:50:43 +02:00
Minz
ef19697346
Docker: Add imagemagick dependency
2022-09-11 22:31:25 +02:00
Minz
28dcb62d48
Add missing card and profile template assets
2022-09-11 19:11:47 +02:00
Minz
c537c1c9e6
Debug: Add optional userid parameter
...
Implemented for reset_cd to allow resetting other users cooldowns
2022-09-09 11:36:24 +02:00
Minz
ff879d179d
View: Add view embed
2022-09-08 17:30:27 +02:00
Minz
6ce583c8fb
Drop: Make cards claimable by other users
...
Cards couldn't be claimed by users other than the dropper because we
were using the wrong user and permissionlevel object from the upper scrope
Fixes #12
2022-09-08 13:30:04 +02:00
Minz
d8fb5d0a62
Drop: Show cooldown times in minutes instead of ms
2022-09-08 13:30:01 +02:00
Minz
fd209fbbda
Docker: Fix sharp not installing due to npm cache permissions
...
Moving the npm cache folder into the /app folder solved the permission issues
Fixes #8
2022-09-08 13:29:59 +02:00
Minz
a4e5679d40
Rendering: Save non animated cards as png instead of gif
...
because gif is bloated and most stuff won't be animated
2022-09-07 22:57:19 +02:00
Minz
fb5faf727e
Drop: Use random sorting to pick dropped characters
...
this fixes the problem of choosing disabled cards or IDs which
are not assigned to any character. Fixes #7
2022-09-07 20:01:28 +02:00
Minz
201417c8ba
SetEnabled: Add SetEnabled command for Bands
...
which optionally includes child Characters
2022-09-07 19:42:01 +02:00
Minz
0a7082ac0f
Import: Fix out of order import
...
Characters are only imported after Bands have finished. This fixes
foreigh key contrains failing due to missing bands.
Fixes #6
2022-09-07 19:05:14 +02:00
Minz
307172762a
[WIP] Setactive command
2022-09-07 18:38:01 +02:00
Minz
f68be35fcf
Profile: Add editprofile command with basic showcase modal
...
New values are persisted into the database
2022-09-07 00:25:42 +02:00
Minz
7340837ed7
Events: Fix error messages not coming through
...
if the interaction has already been deferred or replied to
2022-09-06 23:49:56 +02:00
Minz
ee12d26cc6
Seeders: Change test band/character names to avoid conflict
...
with the actual BAND-MAID dataset
2022-09-05 23:29:08 +02:00
Minz
1206251ff6
Profiles: Add user profile model and command
2022-09-05 23:22:36 +02:00
Minz
bba51cea2e
Models/Cards: Fix errroneous data type of field userId
2022-09-05 22:32:17 +02:00
Minz
addd3d9dee
Models/User: Add instance method to get counted cards with chartcers
2022-09-05 22:26:59 +02:00
Minz
7641e12a2b
README Update
2022-09-04 23:41:14 +02:00
Minz
91e038d88e
Collection: Disable prev or next buttons to avoid over/underflow
...
during collection pagination.
2022-09-04 20:45:47 +02:00
Minz
37414bdf7f
Collection: Implement paginated embed
...
Cards are listed in a paginated embed showing 8 cards per page
2022-09-01 02:28:38 +02:00
Minz
e1f1ad79e8
Drop: Update claim messages to show the character name once cards are revealed
2022-08-31 23:57:06 +02:00
Minz
5d24a580d0
Remove GuildMessages gateway intent as it is not required
2022-08-30 23:39:49 +02:00
Minz
f9f7024211
DB/Characters/Bands: Add Vocaloids part 1
2022-08-29 00:45:00 +02:00
Minz
4d0199655c
Remove cards folder from gitignore
2022-08-29 00:44:23 +02:00
Minz
31b2836a45
Render: Remove default BG color from card stacks
2022-08-29 00:40:41 +02:00
Minz
202ab08d6c
Import: Added band and character import
...
Use 'npm run import' to import from assets/import/{bands,characters}.
Existing entries are not overwritten!
2022-08-29 00:33:37 +02:00