# MBGameRegistry

## Definitions

  `#include <nitro/mb.h>`

      typedef	struct
      {
      const char    *romFilePathp;
      u16           *gameNamep;
      u16           *gameIntroductionp;
      const char    *iconCharPathp;
      const char    *iconPalettePathp;
      u32 ggid;
      u8            maxPlayerNum;
      u8            pad[3];
      u8            userParam[MB_DOWNLOAD_PARAMETER_SIZE];
      } MBGameRegistry;

## Description

This file defines the structure used when specifying the download file with the `MB_RegistryFile` function. The meaning of each member is shown in the following table:

Member | Description
romFilePathp | Pointer to the file path string of the program binary. The current implementation of the MB function requests the pointer to the `FSFile` structure that does not reference this member. Note: `romFilePathp` is provided for future enhancements.
gameNamep | Pointer to the game name string. The string must be less than `MB_GAME_NAME_LENGTH`.
gameIntroductionp | Pointer to the introduction string of the game content. The string must be less than `MB_GAME_INTRO_LENGTH`.
iconCharPathp | Pointer that indicates path character string to icon character data file.
iconPalettePathp | Pointer that indicates path character string to icon palette data file.

ggid

GGID value that is passed to a child when this game is downloaded. This value is stored in little-endian format in `ssid[0]`, `ssid[1]`, `ssid[2]`, and `ssid[3]` of the `MBParentBssDesc` structure which the multiboot child obtained with the `MB_GetMultiBootParentBssDesc` function. The `MB_ReadMultiBootParentBssDesc` function uses this value to create the `WMBssDesc` information that is used to connect to the parent.
When not used for another purpose, GGID can be used as a random u32 value.

maxPlayerNum | The maximum number of simultaneous players for this game, including the parent. The maximum is 16 machines. The maximum number of children that can be connected via multiboot is set with `MB_SetParentCommParam`, which does not include the parent. So `MB_SetParentCommParam` is 1 less than the `MBGameRegistry` value.
userParam | These are the user-defined extended parameters, which can be provided to the child program that started up this game. Up to `MB_DOWNLOAD_PARAMETER_SIZE` (=32) bytes of data can be freely configured. The child program that was started up can reference this data by calling the `MB_GetMultiBootDownloadParameter` function.

## See Also

`MB_GAME_* MBIconInfo MBParentBssDesc WMBssDesc
MB_GetMultiBootParentBssDesc MB_GetMultiBootDownloadParameter MB_ReadMultiBootParentBssDesc MB_RegisterFile`

## Revision History

08/17/2005 Added link to MB_GetMultiBootDownloadParameter function.
05/20/2005 Added member userParam.
11/02/2004 Corrected member names.
10/18/2004 Corrected the description of `ggid`.
10/05/2004 Corrected description of `ggid`.
09/27/2004 Added links.
09/10/2004 Revised the description of `iconCharp` and `iconPalettep`.
08/09/2004 Initial version.