The Controls tab names a PlayStation pad's shoulder, stick and menu buttons L1, R1, L2, R2, L3, R3, Options and Share (#180)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Valiantsin DzerakhandClaude Opus 5.5 committed 2026-11-18 19:12:42 +03:00
1 parent 4a59088f04
commit 74c1cde876
1 file changed
+15 -1
+15 -1
View File
@@ -92,9 +92,23 @@ static const char *key_label(int k, char *buf, size_t n) {
return buf;
}
// A gamepad button: the label the open pad has on a face button, else its place on the pad.
// A gamepad button: the label the open pad has on a face button, else its place on the pad. A PlayStation pad (its
// bottom button labelled Cross, DualSense and DualShock 4 alike) has its shoulder, stick and menu buttons named as
// printed on it, the names the PlayStation prompts draw (tools/button_icons.py playstation_icons: Share for Minus).
static const char *pad_label(int p) {
if (p == PAD_NONE) return "";
if (input_pad_label(PAD_SOUTH) == PAD_LABEL_CROSS) {
switch (p) {
case PAD_L: return "L1";
case PAD_R: return "R1";
case PAD_ZL: return "L2";
case PAD_ZR: return "R2";
case PAD_LSTICK: return "L3";
case PAD_RSTICK: return "R3";
case PAD_START: return "Options";
case PAD_BACK: return "Share";
}
}
switch (input_pad_label(p)) {
case PAD_LABEL_A: return "A";
case PAD_LABEL_B: return "B";