MKE CD-ROM: Fix disc change detection, move model selection to CD-ROM type, and properly implement support for the up to 4 drives supported by the controller.

This commit is contained in:
OBattler
2025-07-29 22:40:02 +02:00
parent 12deafbe1d
commit c675da4de7
15 changed files with 521 additions and 300 deletions

View File

@@ -1249,6 +1249,26 @@ cdrom_get_type_count(void)
return count;
}
void
cdrom_generate_name_mke(const int type, char *name)
{
char elements[2][512] = { 0 };
memcpy(elements[0], cdrom_drive_types[type].model,
strlen(cdrom_drive_types[type].model) + 1);
char *s = strstr(elements[0], " ");
if (s != NULL)
s[0] = 0x00;
memcpy(elements[1], cdrom_drive_types[type].revision,
strlen(cdrom_drive_types[type].revision) + 1);
s = strstr(elements[1], " ");
if (s != NULL)
s[0] = 0x00;
sprintf(name, "%s%s", elements[0], elements[1]);
}
void
cdrom_get_identify_model(const int type, char *name, const int id)
{