Skip to content

Commit

Permalink
Fix wrong SpawnerBlockProvider on 1.21+
Browse files Browse the repository at this point in the history
1.21 Adds a new org.bukkit.spawner.Spawner class as a superclass of CreatureSpawner which now contains the setMaxSpawnDelay method. Change our test to look for the method on any superclasses too.
  • Loading branch information
JRoy committed Mar 3, 2025
1 parent 5bf158c commit fea596e
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public void setMinSpawnDelay(final CreatureSpawner spawner, final int delay) {
@ProviderTest
public static boolean test() {
try {
CreatureSpawner.class.getDeclaredMethod("setMaxSpawnDelay", int.class);
CreatureSpawner.class.getMethod("setMaxSpawnDelay", int.class);
return true;
} catch (final NoSuchMethodException ignored) {
return false;
Expand Down

0 comments on commit fea596e

Please sign in to comment.