mirror of
https://github.com/redphx/better-xcloud.git
synced 2025-06-06 23:57:19 +02:00
Updated How to create custom touch control layout (markdown)
parent
91430b6515
commit
93fadc1b12
@ -134,3 +134,42 @@ BX_EXPOSED.test_touch_control(
|
|||||||
)
|
)
|
||||||
```
|
```
|
||||||
6. Use the [Touch Adaptation Kit documentation](https://learn.microsoft.com/en-us/gaming/gdk/_content/gc/system/overviews/game-streaming/game-streaming-touch-touch-adaptation-kit-overview) to design your own layout. You can also look at [other custom layouts](https://github.com/redphx/better-xcloud/tree/gh-pages/touch-layouts/layouts) for references.
|
6. Use the [Touch Adaptation Kit documentation](https://learn.microsoft.com/en-us/gaming/gdk/_content/gc/system/overviews/game-streaming/game-streaming-touch-touch-adaptation-kit-overview) to design your own layout. You can also look at [other custom layouts](https://github.com/redphx/better-xcloud/tree/gh-pages/touch-layouts/layouts) for references.
|
||||||
|
7. Pass your modified layout to the `BX_EXPOSED.test_touch_control()` function to update it. Do this step again and again until you satisfy with the result.
|
||||||
|
|
||||||
|
## Submit layout
|
||||||
|
1. Fork the [`gh-pages`](https://github.com/redphx/better-xcloud/tree/gh-pages) branch:
|
||||||
|
|
||||||
|
2. Create two files: `<XBOX_TITLE_ID>.json` and `layouts/<LAYOUT_FILE_NAME>.json`
|
||||||
|
- ⚠️ Use [DuckDuckGo's JSON Beautifier tool](https://duckduckgo.com/?t=ffab&q=format+json&ia=answer) (indent with 2 spaces) to beautify & validate the JSON contents first.
|
||||||
|
- `<XBOX_TITLE_ID>.json`:
|
||||||
|
- To find the value of `XBOX_TITLE_ID`:
|
||||||
|
1. Find the game on [dbox.tools](https://dbox.tools). [Here](https://dbox.tools/store/products/9PLZPHBNHTMF/) is the page for DOOM 1993.
|
||||||
|
2. Copy the value in `Title ID` row (Doom 1993 = `60A2D9F6`).
|
||||||
|
3. [Convert that value into decimal](https://www.rapidtables.com/convert/number/hex-to-decimal.html) and you get your `XBOX_TITLE_ID` value. For DOOM 1993 it's `1621285366`.
|
||||||
|
- File template:
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"name": "GAME NAME",
|
||||||
|
"default_layout": "LAYOUT_ID",
|
||||||
|
"layouts": [
|
||||||
|
"LAYOUT_FILE_NAME"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
```
|
||||||
|
- `layouts/<GAME>.json`:
|
||||||
|
- File template:
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"schema_version": 1,
|
||||||
|
"layouts": {
|
||||||
|
"LAYOUT_ID": {
|
||||||
|
"name": "Layout Name",
|
||||||
|
"content": {...}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
3. Create your pull request including the screenshot of the layout. Chrome/Edge has a built-in screenshot feature:
|
||||||
|
<img width="366" alt="Screenshot 2024-03-10 at 10 39 49" src="https://github.com/redphx/better-xcloud/assets/96280/cb6d0211-9f6b-4a37-ae84-f6df5c14d7bf">
|
||||||
|
|
||||||
|
That's the basic of it. I'll update with more details later.
|
Loading…
x
Reference in New Issue
Block a user