projects
/
rocksndiamonds.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8f8fae7
)
added waiting for press/release events when waiting for events to continue
author
Holger Schemel
<info@artsoft.org>
Sun, 4 Oct 2020 23:10:05 +0000
(
01:10
+0200)
committer
Holger Schemel
<info@artsoft.org>
Sun, 4 Oct 2020 23:10:05 +0000
(
01:10
+0200)
src/tools.c
patch
|
blob
|
history
diff --git
a/src/tools.c
b/src/tools.c
index a6a08d72aaaccce1b8dcc035c76d287af54d81d8..50f6775bbaa2c6fc08129c04ebadcbd9efd4ad5e 100644
(file)
--- a/
src/tools.c
+++ b/
src/tools.c
@@
-4196,6
+4196,7
@@
void DrawPlayerField(int x, int y)
void WaitForEventToContinue(void)
{
+ boolean first_wait = TRUE;
boolean still_wait = TRUE;
if (program.headless)
@@
-4218,7
+4219,16
@@
void WaitForEventToContinue(void)
{
switch (event.type)
{
- case EVENT_BUTTONRELEASE:
+ case EVENT_BUTTONPRESS:
+ case EVENT_FINGERPRESS:
+ first_wait = FALSE;
+ break;
+
+ case EVENT_BUTTONRELEASE:
+ case EVENT_FINGERRELEASE:
+ still_wait = first_wait;
+ break;
+
case EVENT_KEYPRESS:
case SDL_CONTROLLERBUTTONDOWN:
case SDL_JOYBUTTONDOWN: