zrho / afp

Angewandte Funktionale Programmierung
15 stars 2 forks source link

Make playable on mobile? #72

Open jvoigtlaender opened 10 years ago

jvoigtlaender commented 10 years ago

At least on my iOS device, neither the fleet placement nor the actual playing function at all.

fanzier commented 10 years ago

Playing works for me (Firefox on Android). Fleet placement doesn't. But even if it did, wouldn't drag and drop make scrolling impossible? There probably is a jQuery plugin that translates the touch gestures to drag and drop. But is that worth it? And how would you test this feature? (As far as I know, there's no yesod devel for mobile devices ...)

jvoigtlaender commented 10 years ago

Playing works for me now as well. That wasn't the case with the version that was online when I opened this issue.

About fleet placement: Sure, one could abstain from supporting manual placement on touch devices. After all, there's always the random placement button that can be used. Though in the original discussion leading to the current mode of interaction for manual placement, one argument in favour of how it is done now was that it would work particularly nicely with touch. :-)

About "drag and drop" vs. scrolling: I guess that's always an issue for interfaces on mobile, "when are gestures meant for interacting with the app, when are they global gestures meant to scroll or zoom the app view". So I assume that JS/jQuery would have a way to deal with that. Basically something like saying "gestures in this square are to be interpreted as drag and drop by the app, gestures outside are to be interpreted as scrolling or zooming the page as a whole".

About testing for mobile: Chrome has a "simulate mobile/touch" mode that can be used for that, essentially interpreting mouse clicks and moves as touch taps and gestures, I think. See e.g. https://frontify.com/blog/how-to-emulate-touch-events-in-chrome/. In order to ultimately test on a real device rather then in simulation mode, deployment on the production server.

jvoigtlaender commented 10 years ago

In case manual placement on mobile (using touch) does not get implemented, at least add some notice/warning when placement page is loaded on mobile, telling the player that they can only use random assignment?