add: option to disable autosaving (set yb_graph_auto_save_count to 0).

This commit is contained in:
dmitry 2022-01-16 02:00:49 +03:00
commit 0f53ab207c
No known key found for this signature in database
GPG key ID: 8297CE728B7A7E37

View file

@ -673,7 +673,7 @@ void BotGraph::add (int type, const Vector &pos) {
}
// autosave nodes here and there
if (++m_autoSaveCount > cv_graph_auto_save_count.int_ ()) {
if (cv_graph_auto_save_count.bool_ () && ++m_autoSaveCount > cv_graph_auto_save_count.int_ ()) {
if (saveGraphData ()) {
ctrl.msg ("Nodes has been autosaved...");
}