diff --git a/src/include/stratagus.h b/src/include/stratagus.h index 5949cc604..710ca71ae 100644 --- a/src/include/stratagus.h +++ b/src/include/stratagus.h @@ -330,7 +330,6 @@ typedef struct _title_screen_ { extern TitleScreen** TitleScreens; ///< File for title screen extern char* GameName; ///< Name of the game -extern char* MenuBackground; ///< File for menu background extern char* MenuMusic; ///< File for menu music extern char* ClickMissile; ///< Missile to show when you click extern char* DamageMissile; ///< Missile to show damage caused diff --git a/src/stratagus/stratagus.cpp b/src/stratagus/stratagus.cpp index ea0c73647..c373d29be 100644 --- a/src/stratagus/stratagus.cpp +++ b/src/stratagus/stratagus.cpp @@ -231,7 +231,6 @@ extern int CclUnits(lua_State* l); ----------------------------------------------------------------------------*/ global TitleScreen** TitleScreens; /// Title screens to show at startup -global char* MenuBackground; /// File for menu background global char* MenuMusic; /// File for menu music global char* StratagusLibPath; /// Path for data directory global char LocalPlayerName[16]; /// Name of local player diff --git a/src/ui/menu_proc.cpp b/src/ui/menu_proc.cpp index f5afa9436..b69270607 100644 --- a/src/ui/menu_proc.cpp +++ b/src/ui/menu_proc.cpp @@ -161,21 +161,6 @@ global Menu* FindMenu(const char* menu_id) } } -/** -** Set menu backgound and draw it. -*/ -global void MenusSetBackground(void) -{ - if (!Menusbgnd) { - Menusbgnd = LoadGraphic(MenuBackground); - ResizeGraphic(Menusbgnd, VideoWidth, VideoHeight); - } - - VideoDrawSubClip(Menusbgnd, 0, 0, - Menusbgnd->Width, Menusbgnd->Height, - (VideoWidth - Menusbgnd->Width) / 2, (VideoHeight - Menusbgnd->Height) / 2); -} - /** ** Draw menu button 'button' on x,y ** diff --git a/src/ui/script_ui.cpp b/src/ui/script_ui.cpp index 8d20cb629..2391b1519 100644 --- a/src/ui/script_ui.cpp +++ b/src/ui/script_ui.cpp @@ -358,35 +358,6 @@ local int CclSetTitleScreens(lua_State* l) return 0; } -/** -** Default menu background. -** -** @param l Lua state. -** -** @return Old menu background. -*/ -local int CclSetMenuBackground(lua_State* l) -{ - char* old; - - old = NULL; - if (MenuBackground) { - old = strdup(MenuBackground); - } - if (lua_gettop(l) != 1) { - LuaError(l, "incorrect argument"); - } - if (MenuBackground) { - free(MenuBackground); - MenuBackground = NULL; - } - MenuBackground = strdup(LuaToString(l, 1)); - - lua_pushstring(l, old); - free(old); - return 1; -} - /** ** Default menu music. ** @@ -4146,7 +4117,6 @@ global void UserInterfaceCclRegister(void) lua_register(Lua, "SetVideoFullScreen", CclSetVideoFullScreen); lua_register(Lua, "SetTitleScreens", CclSetTitleScreens); - lua_register(Lua, "SetMenuBackground", CclSetMenuBackground); lua_register(Lua, "SetMenuMusic", CclSetMenuMusic); lua_register(Lua, "DisplayPicture", CclDisplayPicture);