Commit Graph

21 Commits (5fcb021fe00fa8ece78e45c5c25b5957dad1a30f)

Author SHA1 Message Date
Joey Hines 5fcb021fe0
Tweak discord formatting
ci/woodpecker/push/woodpecker Pipeline was successful Details
+ Created Formatter to handle geoffrey formatting
+ using Serenity's discord message builder to help with formatting
+ Added message sanitation
+ Clippy + Fmt
2022-01-08 15:20:42 -07:00
Joey Hines a8f5f5d87b
Added global settings
ci/woodpecker/push/woodpecker Pipeline was successful Details
+ Usedful for the impls to retrieve settings without having to redefine them in each project
+ Start of models api
+ Bunch of small tweaks
+ clippy + fmt
2022-01-08 12:35:55 -07:00
Joey Hines 51d6ffb7be
Added report_out_of_stock command to bot
ci/woodpecker/push/woodpecker Pipeline was successful Details
+ Added params to the build_response function
+ Updated some commands with more helpful responses
+ Fixed issue with v4 migration
+ clippy + fmt
2022-01-06 18:49:49 -07:00
Joey Hines c6ec8467c1
report_out_of_stock command + new query system
continuous-integration/woodpecker the build was successful Details
+ report_out_of_stock can be used by a when an item is not in stock in a shop
+ Added new query system
  + Impl for both LocationDB and Player for now
  + Goal is to increase code re-use without a million functions for different queries
  + Should be expanded to more models
  + I Should really just rip out the DB and make it a generic thing
+ Clippy + fmt
2021-12-30 21:48:33 -06:00
Joey Hines 928e59a700
Added restock command
continuous-integration/woodpecker the build was successful Details
+ Discord command has not been tested
+ Clippy + Fmt
2021-12-26 21:36:32 -06:00
Joey Hines caf7212cca
Added string length validation (#4)
continuous-integration/woodpecker the build failed Details
+ Added a length check to string fields on add_item and add_location
+ Only doing length validation for now
+ Clippy + Fmt
2021-12-22 19:00:40 -07:00
Joey Hines 99a78599c7
Small fixes
continuous-integration/woodpecker the build was successful Details
+ Improved location format
+ Added an error message for invalid link codes
+ Clippy + fmt
2021-12-20 20:34:56 -07:00
Joey Hines 6bc80af865
Added info command
continuous-integration/woodpecker the build was successful Details
+ Clippy + Fmt
2021-12-19 15:16:22 -07:00
Joey Hines d9a3a05067
Added 'remove_item' command
continuous-integration/woodpecker the build was successful Details
+ Allows a user to remove an item from a shop
+ Clippy + fmt
2021-12-19 14:55:59 -07:00
Joey Hines 18a4373313
Added 'edit' commands
continuous-integration/woodpecker the build was successful Details
+ Allows a location's name or position to be updated
+ Added a bots commands for it, two for now as subcommands are not working right
+ Logging fix
+ Updated return messages for some bot commands
2021-12-19 14:06:56 -07:00
Joey Hines 48be50dd67
Added link command
continuous-integration/woodpecker the build was successful Details
+ Link provides a link code that a user can use to link other accounts
+ This places the main auth source into MC and the plugin
+ Refactored register to accept a link code
+ Clippy + fmt
2021-12-18 11:13:18 -07:00
Joey Hines 37117ce5a9
Added delete command to bot
continuous-integration/woodpecker the build was successful Details
+ Added more error messages
+ Added lang.rs to store common messages
+ clippy + fmt
2021-12-18 09:43:59 -07:00
Joey Hines 3711e7011c
Refactored parameter handling + added delete command
+ CommandRequest is now a struct that contains a generic parameter for the type
+ This streamlines adding new command parameters and reduces duplicate code
+ Added delete commands
2021-12-17 20:03:15 -07:00
Joey Hines 3aaaf39913
Improved bot command handling
+ Created CommandRunner struct to house all the bot commands
+ Streamlines registering app commands and dispatching commands
+ Bit of hecky rust that may need to be cleaned up
+ Clippy + Fmt
2021-12-12 19:30:38 -07:00
Joey Hines 2ff4d14e3f
Added `set_portal` command to bot
+ Added display_portal formatter
2021-12-12 12:41:09 -07:00
Joey Hines c45bb592db
Added logging to bot
+ Cleaned up error handling to make it easier to handle multiple error levels
2021-12-12 11:55:09 -07:00
Joey Hines 3b8c7fc60f
Various Fixes
+ Fixed output of find command
+ Fixed order of add_location params
+ Minor typo fixes
2021-12-05 18:08:35 -07:00
Joey Hines 12218d0b62
Updated models + migration infra
+ Model migration is handled in the DB modules
+ It involves writing an up and a down case
  + Both load and interact with the JSON directly
  + Done so it can be decoupled from models
2021-12-05 16:51:13 -07:00
Joey Hines a655146c81
Bot code cleanup
+ Added functions for parsing Application Command options into different types
+ Added formatters for common message formats
+ Clippy + Fmt
2021-12-03 20:42:57 -07:00
Joey Hines 8d858bdfd3
Refactored GeoffreyBot module layout 2021-12-03 19:33:29 -07:00
Joey Hines 7fb4054cdb
Rough first pass of a bot
+ Uses application commands from discord
+ Tried to follow a similar structure to how the API handles commands
+ Implements add_location, add_item, selling, and find
+ Needs a lot of work lol
+ clippy + fmt
2021-11-30 21:13:56 -07:00