Skip to content
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

Bug fixes & CustomBlock type for mob spawning #358

Merged
merged 3 commits into from
Nov 24, 2023
Merged

Bug fixes & CustomBlock type for mob spawning #358

merged 3 commits into from
Nov 24, 2023

Conversation

Baterka
Copy link
Contributor

@Baterka Baterka commented Nov 24, 2023

Fixes:

  • Everytime new phase was set, plugin sent the first block of the phase 2 times.
  • CustomBlocks in fixedBlocks were causing issues where it was pushing the CustomBlock multiple times into queue.
  • Phase config was not refreshed when doing /isa reload. I tested it and I do not see any issues.

Refactors:

  • Variable naming refactors, because having name obPhase for phase instance + name phase for the ConfigurationSection was not really understandable (I changed it to phaseConfig)

Added features:

  • New CustomBlock for mobs in format:
  • type: mob mob: ZOMBIE underlying-block: GRASS_BLOCK It will spawn a mob on top of underlying block. I know that mob spawns are not exactly counted as "destroyed block", but in this case it is needed. It would not make sense setting it in fixedBlocks if not.
  • New Requirement - cooldown (seconds) that blocks new phase until time elapses.

 - Everytime new phase was set, plugin sent the first block of the phase 2 times.
 - CustomBlocks in fixedBlocks were causing issues where it was pushing the CustomBlock multiple times into queue.
 - Phase config was not refreshed when doing /isa reload. I tested it and I do not see any issues.

Refactors:
 - Variable naming refactors, because having name `obPhase` for `phase` instance + name `phase` for the `ConfigurationSection` was not really understandable (I changed it to `phaseConfig`)

Added features:
 - New `CustomBlock` for mobs in format:
 ```
 - type: mob
   mob: ZOMBIE
   underlying-block: GRASS_BLOCK
 ```
 It will spawn a mob on top of underlying block. I know that mob spawns are not exactly counted as "destroyed block", but in this case it is needed. It would not make sense setting it in fixedBlocks if not.
 - New `Requirement - cooldown` (seconds) that blocks new phase until time elapses.
@tastybento tastybento self-assigned this Nov 24, 2023
Copy link
Member

@tastybento tastybento left a comment

Choose a reason for hiding this comment

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

This looks good and adds a nice cooldown feature. The units for the cooldown should be noted as they are seconds, but that's a minor issue.

@tastybento tastybento merged commit ee4f519 into BentoBoxWorld:develop Nov 24, 2023
1 check failed
@tastybento
Copy link
Member

Thanks @Baterka !

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