MCPcopy Create free account
hub / github.com/EasyRPG/Player / SetupCommon

Method SetupCommon

src/game_map.cpp:372–390  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

370}
371
372void Game_Map::SetupCommon() {
373 screen_width = (Player::screen_width / 16.0) * SCREEN_TILE_SIZE;
374 screen_height = (Player::screen_height / 16.0) * SCREEN_TILE_SIZE;
375
376 if (!Tr::GetCurrentTranslationId().empty()) {
377 TranslateMapMessages(GetMapId(), *map);
378 }
379 SetNeedRefresh(true);
380
381 PrintPathToMap();
382
383 if (translation_changed) {
384 InitCommonEvents();
385 }
386
387 map_cache->Clear();
388
389 CreateMapEvents();
390}
391
392void Game_Map::CreateMapEvents() {
393 events.reserve(map->events.size());

Callers

nothing calls this directly

Calls 2

emptyMethod · 0.45
ClearMethod · 0.45

Tested by

no test coverage detected