summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2016-03-31 23:02:27 +0200
committerJérémy Zurcher <jeremy@asynk.ch>2016-03-31 23:02:27 +0200
commitc08c66b2ba227aa2f6d630abbad70f8860a66159 (patch)
tree2062c455992c975fb6bc22665d5cb18fc8382831
parent822296ff918a34acc4505a49207db302aa3fc96a (diff)
downloadRustAndDust-c08c66b2ba227aa2f6d630abbad70f8860a66159.zip
RustAndDust-c08c66b2ba227aa2f6d630abbad70f8860a66159.tar.gz
Ctrl: add postEvent(EventType, Object)
-rw-r--r--core/src/ch/asynk/rustanddust/game/Ctrl.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/core/src/ch/asynk/rustanddust/game/Ctrl.java b/core/src/ch/asynk/rustanddust/game/Ctrl.java
index 6079594..ff33e7f 100644
--- a/core/src/ch/asynk/rustanddust/game/Ctrl.java
+++ b/core/src/ch/asynk/rustanddust/game/Ctrl.java
@@ -196,8 +196,14 @@ public abstract class Ctrl implements Disposable
public void postEvent(EventType type)
{
+ postEvent(type, null);
+ }
+
+ public void postEvent(EventType type, Object data)
+ {
Event evt = getEvent();
evt.type = type;
+ evt.data = data;
events.enqueue(evt);
}