nitlanguage
/
nit.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b1f9a01
)
shoot: move only on pressed, not depressed
author
Jean Privat
<jean@pryen.org>
Fri, 13 Jun 2014 20:01:37 +0000
(16:01 -0400)
committer
Jean Privat
<jean@pryen.org>
Mon, 16 Jun 2014 15:48:43 +0000
(11:48 -0400)
Signed-off-by: Jean Privat <jean@pryen.org>
examples/shoot/src/shoot.nit
patch
|
blob
|
history
diff --git
a/examples/shoot/src/shoot.nit
b/examples/shoot/src/shoot.nit
index
48cadaa
..
f897ae0
100644
(file)
--- a/
examples/shoot/src/shoot.nit
+++ b/
examples/shoot/src/shoot.nit
@@
-222,7
+222,7
@@
redef class PlayScene
end
end
return true
- else if input_event isa PointerEvent then
+ else if input_event isa PointerEvent and input_event.pressed then
var x = (input_event.x * app.scale).to_i
var y = (input_event.y * app.scale).to_i
player.goes_to(x, y, speed)