Introduced a new `/ctf skipphase` command allowing admins to skip the current game phase. Updated relevant classes to handle phase-skipping logic and ensure proper game state transitions. Added corresponding message configuration and subcommand registration.
Simplified phase transition logic by removing unnecessary parameters and added proper executor shutdown at the end of the game. Enhanced visuals by introducing particle effects around flags when a team wins. Also implemented a method to skip the current game phase.
Extracted the flag capture notification logic into a dedicated method for better readability and reusability. Added team-specific title messages to notify players of the flag capture, improving clarity and game immersion.
The method for setting armor colors was incorrect and used `Color.fromBGR` instead of `Color.fromRGB`. This ensures proper color rendering and aligns with expected behavior.
Introduced a new TURN_IN_RADIUS configuration parameter to manage flag turn-in distance. Refactored particle spawning logic to use configurable radii and adjusted related methods accordingly for better flexibility and maintainability.
Players now receive a formatted message indicating their death and the respawn time remaining. This enhances feedback and improves the overall player experience.
Rename OnPlayerJoin to OnPlayerOnlineStatus, adding logic for player disconnects. Enhance OnPlayerDeath and Flag classes to handle flag reset and notifications when a flag carrier dies or disconnects.
Updated variable and configuration references to reflect the renaming of WINNING_SCORE to CAPTURE_SCORE for clarity and consistency. Adjusted related usage in Flag class to align with the new naming convention.
Replaced the hardcoded 10-block radius with a configurable value from GameConfig.FLAG.CAPTURE_RADIUS. This ensures the capture radius can be easily adjusted without code changes and improves flexibility.
Updated the particle trail to spawn three particles instead of one, enhancing visual clarity. Also removed an outdated TODO comment that is no longer relevant to the functionality.
Made items unbreakable for Engineer, Tank, and Fighter classes to improve durability and gameplay consistency. This change ensures tools and equipment don't wear out during use, aligning with game design goals.
Introduced a check to disable snowball damage if the target is blocking and the impact angle is within 80 degrees. Extended `SnowballHitConsumer` to include the `Snowball` object for more accurate handling of hits. This improves gameplay by allowing players to block snowball attacks with proper positioning.
Made DEFAULT_SIZE in GameConfig mutable and ensured it updates dynamically from the configuration. Corrected phase transition logic in RunningGame to prevent potential out-of-bounds errors. Updated capture radius and build version.
Ensure active potion effects are removed when resetting a player's class. This prevents lingering effects from other classes, maintaining consistent game behavior.
Renamed method for clarity and improved team player checks. Added debug logs for unsupported scenarios and ensured no actions occur when players hit teammates. These changes enhance code maintainability and prevent unintended behavior.
This update enhances the item lore display by including the throw speed attribute alongside health and damage. It improves clarity for players by providing more comprehensive item stats directly on the display.
Removed world border size from `GamePhase` and centralized configuration in `GameConfig`. Updated logic to use `WorldBorderSettings` dynamically, ensuring all phases define valid world border behavior. Adjusted related methods to improve maintainability and clarity.
Introduced a new RESPAWN section in GameConfig for managing respawn time settings. Updated OnPlayerDeath to use the configurable value instead of a hardcoded duration. This allows greater flexibility for game configuration.
Moved FLAG settings from Config to GameConfig for better modularity. Introduced world border configuration with types and sizes for different game phases. Updated related classes to utilize new configuration structure and added error handling to prevent runtime failures.
Simplified game class retrieval by removing redundant data structures and combining logic. Updated GUI inventory to ensure tasks are run on the main thread using Bukkit's scheduler. Improved code organization by centralizing class selection logic in `TeamPlayer`.
Removed a debug log statement in the resetWorldBorder method as it was redundant. This improves code cleanliness and avoids excessive log clutter during game phase transitions.
Introduced a new `flagTurnInLocation` property to the `Team` class, used to determine where players return flags. Updated relevant logic in `Flag` and `CreateTeam` to utilize this new property, including reducing the required distance for flag turn-in.
Deleted an unused `IWorldBorder` variable in the `resetWorldBorder` method to clean up the code. This change helps improve readability and eliminates unnecessary declarations.
Added WorldBorderAPI dependency to manage player boundaries dynamically during game phases. Updated game phases, respawn mechanics, and class selection to utilize the WorldBorderAPI. Reworked related components to improve boundary handling, ensuring consistent gameplay flow and preparation for future enhancements.
Integrated the Engineer class into the game by utilizing the EngineerCreator. This ensures teams now have access to the Engineer role during class selection, enhancing gameplay diversity.
Introduced the Engineer class with unique tools, functionality, and creation logic. Updated the Tank class to make its constructor public and adjusted its creator to use the appropriate class. Enhanced GameClass to append health and damage details to display item lore dynamically.
Added @Contract, @NotNull, and @Unmodifiable annotations for better code safety and clarity. Refactored utility methods in `TankCreator` and `FighterCreator` to enhance readability and reuse, including extracting item creation logic for tools and display items.
Updated class selection to restrict changes during non-selection phases and adjusted spawn radius. Added flag particle trails and square border effects, improving visual feedback. Enhanced flag handling, clearing trails when the carrier is lost or offline.
Introduced a new Tank game class with specialized attributes and equipment, and added it to the class selection setup. Enhanced the Fighter class by introducing a healing potion tool to improve gameplay utility. These changes enhance gameplay diversity and team strategies.
Introduced a new event handler for player respawn to set custom spawn locations and apply game class attributes. This ensures players rejoin the game with the correct state after death.
Renamed OnSnowballHit to SnowballEvent and expanded functionality to handle projectile launches. Added InventoryItemInteractionEvent to manage item pickup and drop behavior. Updated player join logic to clear inventory, assign players to teams, and teleport them appropriately based on game state.
Ensure players have full health when the game ends by resetting their max health attribute and current health to default values. Logged an error if the max health attribute is unavailable.
Introduced a GUI system to facilitate class selection in the CTF game. This includes an abstract GUIInventory, GUIListener for event handling, and a ClassSelectionGUI for selecting classes. Also, added the "selectclass" command and integrated the GUI with game mechanics for improved player interaction.
Introduced new flag-related mechanics and game phases including `CombatPhase`, `EndedPhase`, and relevant event handling for better gameplay management. Enhanced team and player functionalities while making incremental adjustments to improve overall code structure.
Introduced a `clearTeams` method in `GameManager` to reset the teams list. Updated `Main.java` to call this method, ensuring teams are cleared before processing.
Abstracted default class creation logic into dedicated FighterCreator class for better modularity. Updated GameManager and ClassSelectionPhase to utilize this new structure, enabling dynamic class creation based on team color. Adjusted TODO.md to mark completed changes.
Introduced JSON-based configuration handling for teams using Jackson and validation utilities. Added commands for reloading configurations and creating teams with support for saving and loading team data. Refactored related classes to integrate with the new system.
Implemented the core structure for a Capture the Flag (CTF) plugin. This includes team management, game phases, player classes, command handling, and configuration support. The project is set up with Gradle for dependency management and provides placeholders for future feature expansion.