summaryrefslogtreecommitdiff
path: root/src/main/kotlin/de/romjaki/pluggabledino/events
diff options
context:
space:
mode:
authorromangraef <roman.graef@gmail.com>2018-06-22 13:50:37 +0200
committerromangraef <roman.graef@gmail.com>2018-06-22 13:50:37 +0200
commit7b1f56d5d381ec75e757e7df4714c7acdc3c4803 (patch)
tree5699ef744084cd987571b31a949732a56b0ef24c /src/main/kotlin/de/romjaki/pluggabledino/events
parentdd0f1c149db0df7c583c4f7bea4b5dd98f60250b (diff)
downloadpluggabledino-7b1f56d5d381ec75e757e7df4714c7acdc3c4803.tar.gz
pluggabledino-7b1f56d5d381ec75e757e7df4714c7acdc3c4803.tar.bz2
pluggabledino-7b1f56d5d381ec75e757e7df4714c7acdc3c4803.zip
plugin api upgrade
- run the main code with the args `dev classname` to load this class. - more events in the actual playing - some more API methods
Diffstat (limited to 'src/main/kotlin/de/romjaki/pluggabledino/events')
-rw-r--r--src/main/kotlin/de/romjaki/pluggabledino/events/GameLostEvent.kt5
-rw-r--r--src/main/kotlin/de/romjaki/pluggabledino/events/GameRenderEvent.kt9
-rw-r--r--src/main/kotlin/de/romjaki/pluggabledino/events/GameUpdateEvent.kt8
3 files changed, 22 insertions, 0 deletions
diff --git a/src/main/kotlin/de/romjaki/pluggabledino/events/GameLostEvent.kt b/src/main/kotlin/de/romjaki/pluggabledino/events/GameLostEvent.kt
new file mode 100644
index 0000000..cb0ddb9
--- /dev/null
+++ b/src/main/kotlin/de/romjaki/pluggabledino/events/GameLostEvent.kt
@@ -0,0 +1,5 @@
+package de.romjaki.pluggabledino.events
+
+import de.romjaki.pluggabledino.api.Event
+
+data class GameLostEvent(val score: Int) : Event \ No newline at end of file
diff --git a/src/main/kotlin/de/romjaki/pluggabledino/events/GameRenderEvent.kt b/src/main/kotlin/de/romjaki/pluggabledino/events/GameRenderEvent.kt
new file mode 100644
index 0000000..b2925e7
--- /dev/null
+++ b/src/main/kotlin/de/romjaki/pluggabledino/events/GameRenderEvent.kt
@@ -0,0 +1,9 @@
+package de.romjaki.pluggabledino.events
+
+import de.romjaki.pluggabledino.api.Event
+import org.newdawn.slick.GameContainer
+import org.newdawn.slick.Graphics
+import org.newdawn.slick.state.StateBasedGame
+
+
+data class GameRenderEvent(val graphics: Graphics, val game: StateBasedGame, val container: GameContainer) : Event \ No newline at end of file
diff --git a/src/main/kotlin/de/romjaki/pluggabledino/events/GameUpdateEvent.kt b/src/main/kotlin/de/romjaki/pluggabledino/events/GameUpdateEvent.kt
new file mode 100644
index 0000000..550c853
--- /dev/null
+++ b/src/main/kotlin/de/romjaki/pluggabledino/events/GameUpdateEvent.kt
@@ -0,0 +1,8 @@
+package de.romjaki.pluggabledino.events
+
+import de.romjaki.pluggabledino.api.Event
+import de.romjaki.pluggabledino.game.GameWorld
+import org.newdawn.slick.Game
+import org.newdawn.slick.GameContainer
+
+data class GameUpdateEvent(val game: Game, val delta: Int, val container: GameContainer, val world: GameWorld) : Event \ No newline at end of file