diff options
author | Michael Pavone <pavone@retrodev.com> | 2020-11-04 22:55:26 -0800 |
---|---|---|
committer | Michael Pavone <pavone@retrodev.com> | 2020-11-04 22:55:26 -0800 |
commit | 37fa7d1e0f029dd95cc204a6145de6e58f992c5e (patch) | |
tree | e71f72632ebc783b40088e57c886becdcb0c9ddf /controller_info.c | |
parent | 5b18d431a4a42e518f11cfc2c30c9c9ef230aaec (diff) |
Use different variants for Genesis controllers to better represent what types are out there
Diffstat (limited to 'controller_info.c')
-rw-r--r-- | controller_info.c | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/controller_info.c b/controller_info.c index f92b9dd..9fef8dd 100644 --- a/controller_info.c +++ b/controller_info.c @@ -62,7 +62,10 @@ static const char *subtype_human_names[] = { static const char *variant_names[] = { "normal", "6b bumpers", - "6b right" + "6b right", + "3button", + "6button", + "8button" }; static void load_ctype_config(void) @@ -242,6 +245,12 @@ static char const *labels_nintendo[] = { static char const *labels_genesis[] = { "A", "B", "X", "Y", NULL, NULL, "Start", NULL, NULL, "Z", "C", NULL, "Mode" }; +static char const *labels_genesis_3button[] = { + "A", "B", NULL, NULL, NULL, NULL, "Start", NULL, NULL, NULL, "C", NULL, "Mode" +}; +static char const *labels_genesis_8button[] = { + "A", "B", "X", "Y", "Mode", NULL, "Start", NULL, NULL, "Z", "C", "L", "R" +}; static char const *labels_saturn[] = { "A", "B", "X", "Y", NULL, NULL, "Start", NULL, NULL, "Z", "C", "LT", "RT" }; @@ -266,7 +275,13 @@ static const char** label_source(controller_info *info) } } else { if (info->subtype == SUBTYPE_GENESIS) { - return labels_genesis; + if (info->variant == VARIANT_8BUTTON) { + return labels_genesis_8button; + } else if (info->variant == VARIANT_3BUTTON) { + return labels_genesis_3button; + } else { + return labels_genesis; + } } else { return labels_saturn; } |