Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion config/fxdata/lua/core/serialisation.lua
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ function GetSerializedData()
local prepped = preprocess(Game)
return binser.serialize(prepped)
end)
print("GetSerializedData ok: " .. tostring(ok))
if not ok then
error("binser failed: " .. result)
end
Expand Down
2 changes: 1 addition & 1 deletion src/frontend.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2307,7 +2307,7 @@ MenuNumber create_menu(struct GuiMenu *gmnu)
update_radio_button_data(amnu);
init_slider_bars(amnu);
init_menu_buttons(amnu);
SYNCMSG("Created menu ID %d at slot %d, pos (%d,%d) size (%d,%d)",(int)gmnu->ident,
SYNCDBG(8,"Created menu ID %d at slot %d, pos (%d,%d) size (%d,%d)",(int)gmnu->ident,
(int)mnu_num,(int)amnu->pos_x,(int)amnu->pos_y,(int)amnu->width,(int)amnu->height);
return mnu_num;
}
Expand Down
2 changes: 2 additions & 0 deletions src/game_saves.c
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,8 @@ TbBool save_game(long slot_num)
ERRORLOG("Outranged slot index %d",(int)slot_num);
return false;
}

SYNCMSG("Saving game to slot %d",(int)slot_num);
char* fname = prepare_file_fmtpath(FGrp_Save, saved_game_filename, slot_num);
TbFileHandle handle = LbFileOpen(fname, Lb_FILE_MODE_NEW);
if (!handle)
Expand Down
3 changes: 0 additions & 3 deletions src/lua_base.c
Original file line number Diff line number Diff line change
Expand Up @@ -211,15 +211,12 @@ const char* lua_get_serialised_data(size_t *len)
lua_getglobal(Lvl_script, "GetSerializedData");
if (lua_isfunction(Lvl_script, -1))
{
JUSTLOG("calling GetSerializedData");
int result = lua_pcall(Lvl_script, 0, 1, 0);
JUSTLOG("lua_pcall result: %d", result);
if (!CheckLua(Lvl_script, result, "GetSerializedData")) {
ERRORLOG("Failed to call GetSerializedData");
return NULL;
}

JUSTLOG("called GetSerializedData");
if (!lua_isstring(Lvl_script, -1)) {
ERRORLOG("Expected 'GetSerializedData' to return a string");
lua_pop(Lvl_script, 1);
Expand Down