diff options
author | qwx <qwx@sciops.net> | 2021-09-01 22:47:30 +0000 |
---|---|---|
committer | qwx <qwx@sciops.net> | 2021-09-01 22:47:30 +0000 |
commit | 6d4261baabfece44dea8033b9d5a9d90978f8477 (patch) | |
tree | ce7eba781bd58412a39b6abba1658661bee886b9 /sys/src/games | |
parent | 6c9462710539bd35ae5c51de27e7894522683bd7 (diff) |
add joy(1): joystick script for all emulators, and docs
remove old /sys/src/games/nes/joynes in favor of joy(1).
joy(1) has more buttons for the other emulators; there is
no longer a significance in the order of the keys.
document nusb/joy, add information in each emulator manpage.
Diffstat (limited to 'sys/src/games')
-rwxr-xr-x | sys/src/games/nes/joynes | 33 |
1 files changed, 0 insertions, 33 deletions
diff --git a/sys/src/games/nes/joynes b/sys/src/games/nes/joynes deleted file mode 100755 index 2240b88e9..000000000 --- a/sys/src/games/nes/joynes +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/rc -# run as "nusb/joy epX.Y | joynes N", where N=[1,2] - -awk -safe -v 'joy='$1 ' - BEGIN { k[0] = "" } - - /^axis 0 0/ { k[0] = "left " } - /^axis 0 255/ { k[0] = "right " } - /^axis 0 128/ { k[0] = "" } - - /^axis 1 0/ { k[1] = "up " } - /^axis 1 255/ { k[1] = "down " } - /^axis 1 128/ { k[1] = "" } - - /^down 7$/ { k[3] = "b " } - /^down 8$/ { k[2] = "a " } - /^down 1$/ { k[4] = "control " } - /^down 2$/ { k[5] = "start " } - - /^up 7$/ { k[3] = "" } - /^up 8$/ { k[2] = "" } - /^up 1$/ { k[4] = "" } - /^up 2$/ { k[5] = "" } - - { - if(joy != "") - printf "joy%s ", joy - for(i = 0; i <= 5; i++) - printf k[i] - printf "\n" - fflush - } -' |