MCPcopy Create free account
hub / github.com/diasurgical/devilution / mainmenu_Load

Function mainmenu_Load

SourceX/DiabloUI/mainmenu.cpp:44–56  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

42}
43
44void mainmenu_Load(char *name, void (*fnSound)(char *file))
45{
46 gfnSoundFunction = fnSound;
47 MAINMENU_DIALOG[size(MAINMENU_DIALOG) - 1].art_text.text = name;
48
49 if (!gbSpawned) {
50 LoadBackgroundArt("ui_art\\mainmenu.pcx");
51 } else {
52 LoadBackgroundArt("ui_art\\swmmenu.pcx");
53 }
54
55 UiInitList(MAINMENU_SINGLE_PLAYER, MAINMENU_EXIT_DIABLO, NULL, UiMainMenuSelect, mainmenu_Esc, MAINMENU_DIALOG, size(MAINMENU_DIALOG), true);
56}
57
58void mainmenu_Free()
59{

Callers 1

UiMainMenuDialogFunction · 0.85

Calls 3

sizeFunction · 0.85
LoadBackgroundArtFunction · 0.85
UiInitListFunction · 0.85

Tested by

no test coverage detected