generated from Liams-Services/PaperMC-Plugin-Boilerplate
-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
6 changed files
with
68 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
src/main/kotlin/com/liamxsage/shaderapi/events/ShaderStatusChangedEvent.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package com.liamxsage.shaderapi.events | ||
|
||
import org.bukkit.entity.Player | ||
import org.bukkit.event.Event | ||
import org.bukkit.event.HandlerList | ||
|
||
class ShaderStatusChangedEvent(val player: Player, val status: String) : Event() { | ||
|
||
override fun getHandlers(): HandlerList { | ||
return HANDLERS | ||
} | ||
|
||
companion object { | ||
val HANDLERS = HandlerList() | ||
|
||
@JvmStatic | ||
fun getHandlerList(): HandlerList { | ||
return HANDLERS | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
src/main/kotlin/com/liamxsage/shaderapi/listeners/ShaderStatusChangeListener.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package com.liamxsage.shaderapi.listeners | ||
|
||
import com.liamxsage.klassicx.extensions.getLogger | ||
import com.liamxsage.shaderapi.events.ShaderStatusChangedEvent | ||
import org.bukkit.event.EventHandler | ||
import org.bukkit.event.Listener | ||
|
||
class ShaderStatusChangeListener : Listener { | ||
|
||
@EventHandler | ||
fun onShaderStatusChangedEvent(event: ShaderStatusChangedEvent): Unit = with(event) { | ||
getLogger().info("Shader Status Response by ${player.name}: $status") | ||
} | ||
|
||
} |