Giter VIP home page Giter VIP logo

Comments (7)

christopher-kleine avatar christopher-kleine commented on May 22, 2024 1

X, Z + Arrows is selected as generics layout (all emulators use this binding).

Just because "everyone is doing the same" doesn't mean it's the best way.
In fact, I complained a few times in the TIC-80 discord about this.

in addition to Y to Z for German keyboards

That's pretty much why I mentioned this in the small text under my game. Maybe this should be mentioned below the playable games. Currently it only states "Arrow keys" and "Z/X".
Something like

Arrows keys = D-Pad
X = Button 1
Z/C/Y = Button 2

might make it more obvious.

from wasm4.

ubunatic avatar ubunatic commented on May 22, 2024 1

I did not realize that C was bound too automatically πŸ™ˆ. This already solves half of the issue.

I also checked some more keyboard layouts (PT, ES, CN, Arabic, etc.) and most seem to have Z in the "right" place next to X, it is only DE, FR, and some others that have them "misplaced". By having C/Y/Z bound to Button 2, you already cover most of the planet I guess.

Then the issue is more in the hint below the demo games on the website as @christopher-kleine said.

I still think, Watris should get the D-Pad down bound to "drop" as it the original GB game had it.
Then the Buttons 1 and 2 could be used left/right rotation (I also think the GB game had it like that).

I will check the code and try do PRs for Watris and the website (after getting the project to run on my machine).

from wasm4.

eXponenta avatar eXponenta commented on May 22, 2024

Accessibility is not a main option.

X, Z + Arrows is selected as generics layout (all emulators use this binding).

If you want change this, you should provide a PR for site, docs and runtime , because not all has a FR layout and non-EU keyboard.
I can said more - generic layout is EU :)

And you CANNOT change layout a game specific, because it limited specially.
Looks to docs about this:
https://wasm4.org/docs/guides/user-input#gamepad

If a devs select a ArrowDown as input - him think that this is good.

from wasm4.

FaberVitale avatar FaberVitale commented on May 22, 2024

Hi @ubunatic,

This is more an a11y issue of the console:
cartridge developers do not have access to raw keyboard keypresses and current layout, as @eXponenta said, it is rather common.

Generally emulators resolve the issue you raised using a window that allow to customize keys.

We should probably add a similar feature and persist the custom key mapping.

from wasm4.

aduros avatar aduros commented on May 22, 2024

Add C as more universal "hard drop" key (Z is always a bad choice as an action button, e.g., for DE and FR layouts, where it is not next to X).

This should actually already be the case, we alias C to Z, in addition to Y to Z for German keyboards. We even include Dvorak-friendly mappings for Z/X. This is not at all obvious though, so let's add some documentation about it.

Here is where the Z/X keys are handled:

case 88: case 32: case 81:

If there are missing Z/X aliases for other keyboard types, let's add them. In the future having customizable keybinding as @FaberVitale suggests will also be fantastic.

from wasm4.

ubunatic avatar ubunatic commented on May 22, 2024

PR #87 for improved Watris keys is open.
PR #88 for hint to alternative keys is also open.

Btw. the "60 second" dev setup was super smooth, npm install wasm4 (without the -g)
And then a simple make && ~/node_modules/wasm4/cli.js run build/cart.wasm to test it. πŸ‘

from wasm4.

aduros avatar aduros commented on May 22, 2024

Btw. the "60 second" dev setup was super smooth

Good to know πŸ˜„

from wasm4.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.