Merge remote-tracking branch 'origin/master'
All checks were successful
Maven Build / build (push) Successful in 11m37s
All checks were successful
Maven Build / build (push) Successful in 11m37s
This commit is contained in:
@@ -87,7 +87,7 @@ class Leaper : JavaPlugin(), Listener {
|
||||
// Load particle settings
|
||||
val particleTypeName = config.getString("effects.particle-type", "CLOUD")
|
||||
try {
|
||||
// Use Enum.values() instead of Enum.entries for backward compatibility ( Won't work in the future if that function gets removed )
|
||||
// Future wont work ; cyka
|
||||
particleType = Particle.values().find { it.toString() == particleTypeName } ?: Particle.CLOUD
|
||||
} catch (e: Exception) {
|
||||
logger.warning("Invalid particle type in config: $particleTypeName. Using default: CLOUD")
|
||||
@@ -98,7 +98,7 @@ class Leaper : JavaPlugin(), Listener {
|
||||
// Load sound settings
|
||||
val soundEffectName = config.getString("effects.sound", "ENTITY_RABBIT_JUMP")
|
||||
try {
|
||||
// Use Enum.values() instead of Enum.entries for backward compatibility
|
||||
// Use values function => In the future this might not work anymore!
|
||||
soundEffect = Sound.values().find { it.toString() == soundEffectName } ?: Sound.ENTITY_RABBIT_JUMP
|
||||
} catch (e: Exception) {
|
||||
logger.warning("Invalid sound effect in config: $soundEffectName. Using default: ENTITY_RABBIT_JUMP")
|
||||
|
||||
Reference in New Issue
Block a user