-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Farming Progression #1350
base: master
Are you sure you want to change the base?
Farming Progression #1350
Conversation
|
progression/src/main/resources/progression-migrations/V9__Add_farming_progression_tables.sql
Show resolved
Hide resolved
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.
66ba42f
to
3a8d95d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR Overview
This PR introduces the barebones implementation for the Farming progression system. Key changes include adding a new farming command, menu interface, and multiple event listeners/handlers to account for planting, harvesting, and bonemealing crops, as well as persisting crop interactions in the database.
Reviewed Changes
File | Description |
---|---|
progression/src/main/java/me/mykindos/betterpvp/progression/profession/farming/commands/FarmingCommand.java | Adds the farming command functionality |
progression/src/main/java/me/mykindos/betterpvp/progression/profession/skill/builds/menu/buttons/FarmingProfessionMenu.java | Introduces the farming menu for the profession |
progression/src/main/java/me/mykindos/betterpvp/progression/profession/farming/listener/FarmingListener.java | Implements event listeners for crop interactions |
progression/src/main/java/me/mykindos/betterpvp/progression/profession/farming/listener/FarmingActionType.java | Defines action types for farming interactions |
progression/src/main/java/me/mykindos/betterpvp/progression/profession/farming/FarmingHandler.java | Manages experience granting and crop interaction processing |
progression/src/main/java/me/mykindos/betterpvp/progression/profession/farming/repository/FarmingRepository.java | Persists crop interaction data to the database |
progression/src/main/resources/configs/config.yml | Configures experience values and cooldowns for farming |
progression/src/main/java/me/mykindos/betterpvp/progression/profession/ProfessionHandler.java | Updates common utility methods for profession handlers |
progression/src/main/java/me/mykindos/betterpvp/progression/profession/woodcutting/WoodcuttingHandler.java | Removes duplicate method code |
Copilot reviewed 11 out of 11 changed files in this pull request and generated 2 comments.
Comments suppressed due to low confidence (1)
progression/src/main/java/me/mykindos/betterpvp/progression/profession/farming/listener/FarmingListener.java:88
- [nitpick] Consider rephrasing the comment to remove informal language; for example, use 'Probably unreachable return statement' rather than 'but who knows'.
if (!(clickedBlockData instanceof Ageable blockAsAgeable)) return; // Probably unreachable return stmt but who knows
if (args.length != 0) return; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When extra arguments are provided to the Farming command, there is no feedback to the player. Consider sending a usage message to guide the user.
if (args.length != 0) return; | |
if (args.length != 0) { | |
player.sendMessage("Usage: /farming"); | |
return; | |
} |
Copilot is powered by AI, so mistakes are possible. Review output carefully before use.
if (cropMaterial == null) continue; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unknown material keys in the configuration are silently ignored; consider logging a warning when Material.getMaterial returns null to aid in diagnosing configuration errors.
if (cropMaterial == null) continue; | |
if (cropMaterial == null) { | |
log.warn("Unknown material key in configuration: " + materialAsKey).submit(); | |
continue; | |
} |
Copilot is powered by AI, so mistakes are possible. Review output carefully before use.
|
Describe your changes
Just the barebones system:
Stuff that needs work:
Link to issue (if applicable)
Checklist before requesting a review