-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tweak joysticks and add CSS variables #63
base: master
Are you sure you want to change the base?
Commits on Jan 8, 2022
-
Yoke can now read numeric variables from CSS
This commit adds CSS variables and a codebase that for now, is unused. In a future commit, most variables will be read from the CSS instead of hardcoded in the JavaScript. This allows users to both fine-tune Yoke more easily, and also to fix settings per layout and per control (for example, the first button from a given layout might need extra force to be pushed). CSS blocks have also been moved around for the user's convenience. Critical parameters that users should not touch are now at the bottom of the file. Parameters at the top will be overridden by parameters at the bottom, following normal CSS priority rules. No examples are given for this, but parameters bound to any specific control by ID (e.g. "#j1") would be given a higher priority.
Configuration menu - View commit details
-
Copy full SHA for 0e5a4b5 - Browse repository at this point
Copy the full SHA 0e5a4b5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 9123b31 - Browse repository at this point
Copy the full SHA 9123b31View commit details -
Add support for joystick shapes and deadzones
Joysticks can now be elliptical, square, round or rectangular. A central deadzone is also supported, which depends on the joystick shape: rectangular joysticks have axial deadzones (evaluated separately for each component), while round joysticks have a single radial deadzone. Both deadzones are scaled, meaning that output grows gradually from the edge of the deadzone to the edge of the joystick.
Configuration menu - View commit details
-
Copy full SHA for 891ca49 - Browse repository at this point
Copy the full SHA 891ca49View commit details -
Configuration menu - View commit details
-
Copy full SHA for dad3ce7 - Browse repository at this point
Copy the full SHA dad3ce7View commit details -
Regularize shapes across controls
- D-pad and knobs are compatible now with all four shapes - D-pads, knobs, and joysticks use similar CSS and JS - Knobs have now an image (made with Inkscape and manually trimmed down), - D-pads use now CSS filters instead of hardcoded shadows
Configuration menu - View commit details
-
Copy full SHA for 06466ac - Browse repository at this point
Copy the full SHA 06466acView commit details -
Add more options for button labels
Also, remove bg.svg, bm.svg, bs.svg, which have been superseded by button.svg#bg, #bm and #bs.
Configuration menu - View commit details
-
Copy full SHA for 0c691ff - Browse repository at this point
Copy the full SHA 0c691ffView commit details -
CChange sorting method for controls
Several programs on Linux (and all programs in Windows, due to a design decision on Yoke) ignore the semantics of every button and only look at the order in which they are reported. Because of this, the JavaScript side now reorders controls to simplify most configurations (face buttons should go first, then in-game menu buttons, then thumbstick buttons, and then special buttons like the branded key to open the system menu, which is even less used in this scenario).
Configuration menu - View commit details
-
Copy full SHA for 2492aa2 - Browse repository at this point
Copy the full SHA 2492aa2View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1363da5 - Browse repository at this point
Copy the full SHA 1363da5View commit details