Skip to content

Dev (#274)#278

Merged
Nandi0813 merged 33 commits intomasterfrom
dev
Mar 9, 2026
Merged

Dev (#274)#278
Nandi0813 merged 33 commits intomasterfrom
dev

Conversation

@Nandi0813
Copy link
Collaborator

No description provided.

Copilot AI review requested due to automatic review settings March 7, 2026 10:52
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR makes two small changes: it updates the firework rocket cooldown logic to handle both gliding (elytra boost) and ground/block firework usage scenarios, and adds %weight_class% placeholder replacement support in queue selector GUI items.

Changes:

  • Replaced the elytra-equipped check in FireworkRocketCooldownListener with a gliding-state and action-type check, so cooldowns apply for elytra boosts and block-placed fireworks, but not for right-clicking air without gliding.
  • Added %weight_class% placeholder replacement in QueueSelectorGui for both the raw template (used by the real-time ticker) and after LB-format lore processing in updateIconWithQueueData.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
spigot_modern/.../FireworkRocketCooldownListener.java Replaced elytra-equipment guard with a gliding + action-type guard for firework rocket cooldowns
core/.../QueueSelectorGui.java Added %weight_class% placeholder replacement in raw template setup and after leaderboard lore replacement

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

// - Player gliding with elytra (boost attempt) OR
// - Any non-air click (ground/block usage)
// Ignore empty RIGHT_CLICK_AIR without gliding
if (!player.isGliding() && e.getAction() == Action.RIGHT_CLICK_AIR) {
Copy link

Copilot AI Mar 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new guard condition only filters out RIGHT_CLICK_AIR when the player is not gliding, but it does not filter out left-click actions (LEFT_CLICK_AIR, LEFT_CLICK_BLOCK) or PHYSICAL. This means if a player holds a firework rocket and left-clicks (e.g., to attack), the cooldown handler will still fire and set a material cooldown on FIREWORK_ROCKET, preventing the player from actually using the rocket for boosting until the cooldown expires.

Consider also filtering out non-right-click actions by adding a check like action != Action.RIGHT_CLICK_AIR && action != Action.RIGHT_CLICK_BLOCK early return, or alternatively only proceeding on right-click actions.

Copilot uses AI. Check for mistakes.
lokspel and others added 26 commits March 7, 2026 12:17
* fix(firework-cooldown): add right-click filter

* fix(firework): prevent cooldown spam/hang on held clicks

* Improve pre-login kick message with better wording
* fix: prevent false firework cooldown and optimize by using EntitySpawnEvent

* chore: remove unused imports

* fix: include FFA arenas in enabled arena count

* fix: update CopyGui synchronously to prevent duplicate icons
@Nandi0813 Nandi0813 merged commit f7e09c9 into master Mar 9, 2026
2 checks passed
@Nandi0813 Nandi0813 deleted the dev branch March 9, 2026 12:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants