World of Might and Magic
0.2.0
Open reimplementation of Might and Magic 6 7 8 game engine
|
См. документацию.
54 if (file_name.empty()) {
58 String str =
"saves\\" + file_name;
60 if (_access(str.c_str(), 0) || _access(str.c_str(), 6)) {
71 String test = newname.substr(0, newname.size() - 4);
105 pBtnLoadSlot =
CreateButton(241, 302, 105, 40, 1, 0,
UIMSG_SaveLoadBtn, 0, 0,
"", { {
saveload_ui_ls_saved } });
106 pBtnCancel =
CreateButton(350, 302, 105, 40, 1, 0,
UIMSG_Cancel, 0, 0,
"", { {
saveload_ui_x_d } });
107 pBtnArrowUp =
CreateButton(215, 199, 17, 17, 1, 0,
UIMSG_ArrowUp, 0, 0,
"", { {
ui_ar_up_dn } });
108 pBtnDownArrow =
CreateButton(215, 323, 17, 17, 1, 0,
UIMSG_DownArrow,
MAX_SAVE_SLOTS, 0,
"", { {
ui_ar_dn_dn } });
162 if (_access(str.c_str(), 6)) {
178 String test = newname.substr(0, newname.size() - 4);
212 pBtnLoadSlot =
CreateButton(241, 302, 105, 40, 1, 0,
UIMSG_SaveLoadBtn, 0, 0,
"", { {
saveload_ui_ls_saved } });
213 pBtnCancel =
CreateButton(350, 302, 105, 40, 1, 0,
UIMSG_Cancel, 0, 0,
"", { {
saveload_ui_x_d } });
214 pBtnArrowUp =
CreateButton(215, 199, 17, 17, 1, 0,
UIMSG_ArrowUp, 0, 0,
"", { {
ui_ar_up_dn } });
215 pBtnDownArrow =
CreateButton(215, 323, 17, 17, 1, 0,
UIMSG_DownArrow,
uNumSavegameFiles, 0,
"", { {
ui_ar_dn_dn } });
233 unsigned int pSaveFiles;
236 memset(&save_load_window, 0, 0x54);
254 if (savegame_hour >= 12) {
256 if (!savegame_hour) {
265 "%s %d:%02d %s\n%d %s %d",
404 window->PeekMessageLoop();
unsigned int uLoadGameUI_SelectedSlot
void DrawText(GUIFont *font, int x, int y, unsigned short uFontColor, const char *str, bool present_time_transparency=false, int max_text_height=0, int uFontShadowColor=0)
void EnterText(int a2, int max_string_len, GUIWindow *pWindow)
const char * GetString(unsigned int index) const
Image * saveload_ui_loadu
GUIWindow * pGUIWindow_CurrentMenu
GUIButton * CreateButton(int x, int y, int width, int height, int a6, int a7, UIMessageType msg, unsigned int msg_param, uint8_t hotkey, const String &label, const std::vector< Image * > &textures=std::vector< Image * >())
void SetCurrentMenuID(MENU_STATE uMenu)
Image * saveload_ui_loadsave
MAP_TYPE GetMapInfo(const String &Str2)
int GetDaysOfWeek() const
int GetDaysOfMonth() const
std::array< unsigned int, 2 > saveload_dlg_ys
Localization * localization
Image * saveload_ui_saveu
std::array< unsigned int, MAX_SAVE_SLOTS > pSavegameUsedSlots
unsigned int uNumSavegameFiles
void DrawTitleText(GUIFont *font, int horizontal_margin, int vertical_margin, unsigned __int16 uDefaultColor, const char *pInString, int line_spacing)
Texture * GetImage_PCXFromIconsLOD(const String &name)
unsigned int GetHeight() const
Image * saveload_ui_save_up
int receives_keyboard_input_2
enum CURRENT_SCREEN current_screen_type
struct MapStats * pMapStats
int GetMinutesFraction() const
MENU_STATE GetCurrentMenuID()
int DrawTextInRect(GUIFont *font, unsigned int x, unsigned int y, unsigned int color, const char *text, int rect_width, int reverse_text)
Image * saveload_ui_load_up
static void UI_DrawSaveLoad(bool save)
unsigned int AlignText_Center(unsigned int width, const String &str)
struct ViewingParams * viewparams
GUIWindow_Load(bool ingame)
Texture * GetImage_ColorKey(const String &name, uint16_t colorkey)
unsigned int uFrameHeight
char pPressedKeysBuffer[257]
LODFile_IconsBitmaps * pIcons_LOD
Image * main_menu_background
std::array< Image *, MAX_SAVE_SLOTS > pSavegameThumbnails
void MainMenuLoad_EventLoop()
EGLSurface EGLNativeWindowType * window
int GetHoursOfDay() const
std::array< unsigned int, 2 > saveload_dlg_zs
std::array< unsigned int, 2 > saveload_dlg_xs
void PopMessage(UIMessageType *pMsg, int *pParam, int *a4)
void SetWindowInputStatus(int a2)
const char * GetAmPm(unsigned int index) const
Image * saveload_ui_loadsave
Image * saveload_ui_ls_saved
void DrawFlashingInputCursor(int uX, int uY, GUIFont *a2)
constexpr unsigned int MAX_SAVE_SLOTS
int GetMonthsOfYear() const
@ MENU_LoadingProcInMainMenu
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
const char * GetMonthName(unsigned int index) const
struct KeyboardActionMapping * pKeyActionMap
std::string MakeDataPath(const char *file_rel_path)
static Image * Create(unsigned int width, unsigned int height, IMAGE_FORMAT format, const void *pixels=nullptr)
void __cdecl __debugbreak(void)
bool Open(const String &pFilename)
int dword_6BE364_game_settings_1
Texture * GetImage_Alpha(const String &name)
const char * GetDayName(unsigned int index) const
struct GUIMessageQueue * pMessageQueue_50CBD0
uint16_t Color16(uint32_t r, uint32_t g, uint32_t b)
String StringPrintf(const char *fmt,...)
std::array< String, 45 > pFileList
void * LoadRaw(const String &pContainer, size_t *data_size=nullptr)
std::array< unsigned int, 2 > saveload_dlg_ws
struct SavegameList * pSavegameList
std::shared_ptr< IRender > render
std::array< SavegameHeader, MAX_SAVE_SLOTS > pSavegameHeader