Skip to content

Commit

Permalink
Merge pull request #34198 from BevapDin/bpl
Browse files Browse the repository at this point in the history
Don't access the main game map from mapgen code.
  • Loading branch information
ZhilkinSerg authored Sep 23, 2019
2 parents e3f41b4 + 3832563 commit be19091
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 3 additions & 0 deletions src/debug_menu.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1498,6 +1498,9 @@ void debug()
tinymap mx_map;
mx_map.load( where_sm, false );
MapExtras::apply_function( mx_str[mx_choice], mx_map, where_sm );
g->load_npcs();
g->m.invalidate_map_cache( g->get_levz() );
g->refresh_all();
}
}
break;
Expand Down
4 changes: 0 additions & 4 deletions src/mapgen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7940,10 +7940,6 @@ bool update_mapgen_function_json::update_map( const tripoint &omt_pos, const poi
md.m.save();
}

g->load_npcs();
g->m.invalidate_map_cache( md.zlevel() );
g->refresh_all();

return applied;
}

Expand Down

0 comments on commit be19091

Please sign in to comment.