The "vngen_file_save_map" Function

Syntax

vngen_file_save_map();
ArgumentTypeDescription
N/AN/ANo arguments

Description

Returns a ds_map containing basic VNgen progress and engine data, which can then be written to save files along with other custom game data.

If no VNgen data could be found in the current room, undefined will be returned instead.

Also note that data structures are volatile and may become inaccessible if the variables referencing them are redefined. As such, it is highly recommended to always destroy the data structure when it no longer needed.

See the vngen_file_load_map function for a list of values included in the generated ds_map.

Example

var save_data = vngen_file_save_map();
var file = file_text_open_write(working_directory + "save.dat");
file_text_write_string(file, ds_map_write(save_data));
file_text_close(file);
ds_map_destroy(save_data);