| 296 | _ctx.game->state->set_player_pos(loc); |
| 297 | _ctx.game->state->set_player_prev_depth(_ctx.game->state->get_depth()); |
| 298 | _ctx.game->state->set_depth(depth); |
| 299 | _ctx.game->state->set_player_facing(dir); |
| 300 | _set_tile_explored(_ctx.game->state->get_player_pos()); |
| 301 | } |
| 302 | |
| 303 | auto Sorcery::Engine::_start_expedition(const int mode) -> void { |
| 304 | |
| 305 | _ctx.controller->set_last_dir(Enums::Map::Direction::NO_DIRECTION); |
| 306 | _ctx.controller->set_last_event(Enums::Map::Event::NO_EVENT); |
| 307 | _ctx.controller->set_can_undo(false); |
| 308 | _ctx.controller->set_monochrome( |
| 309 | _ctx.get_config(Enums::Config::COLOURED_WIREFRAME)); |
| 310 | _ctx.ui->set_monochrome(_ctx.get_config(Enums::Config::COLOURED_WIREFRAME)); |
| 311 | |
| 312 | //_ctx.controller->set_flag("show_automap"); |
| 313 | _ctx.controller->set_flag("interface_party_panel"); |
| 314 | _ctx.controller->set_flag("interface_ui"); |
| 315 | |
| 316 | if (!_tile_explored(_ctx.game->state->get_player_pos())) |
| 317 | _set_tile_explored(_ctx.game->state->get_player_pos()); |
| 318 | |
| 319 | if (mode & EXPEDITION_GOTO) { |
| 320 | // Check we have an override to go to a specific placein the maze |
| 321 | const auto goto_depth{ |
| 322 | std::stoi(_ctx.get_config("Debug", "quick_start_depth"))}; |
| 323 | const auto goto_loc{ |
| 324 | Coordinate{std::stoi(_ctx.get_config("Debug", "quick_start_x")), |
| 325 | std::stoi(_ctx.get_config("Debug", "quick_start_y"))}}; |
| 326 | const auto goto_dir{static_cast<Enums::Map::Direction>( |
| 327 | std::stoi(_ctx.get_config("Debug", "quick_start_dir")))}; |
| 328 | |
| 329 | _go_to_location(goto_depth, goto_loc, goto_dir); |
| 330 | |
| 331 | _ctx.ui->modal_camp->regenerate(); |
| 332 | _ctx.ui->modal_elevator_bottom->regenerate(); |
| 333 | _ctx.ui->modal_elevator_top->regenerate(); |
| 334 | |
| 335 | _ctx.ui->modal_camp->show = true; |
| 336 | |
| 337 | _ctx.ui->modal_identify->show = false; |
| 338 | _ctx.ui->modal_equip->show = false; |
| 339 | _ctx.ui->modal_remove->show = false; |
| 340 | _ctx.ui->modal_spell->show = false; |
| 341 | _ctx.ui->modal_drop->show = false; |
| 342 | _ctx.ui->modal_use->show = false; |
| 343 | _ctx.ui->modal_invoke->show = false; |
| 344 | _ctx.ui->modal_trade->show = false; |
| 345 | _ctx.ui->modal_give->show = false; |
| 346 | _ctx.ui->modal_elevator_top->show = false; |
| 347 | _ctx.ui->modal_elevator_bottom->show = false; |
| 348 | |
| 349 | } else { |
| 350 | // Start off in Camp |
| 351 | _ctx.ui->modal_camp->regenerate(); |
| 352 | _ctx.ui->modal_elevator_bottom->regenerate(); |
| 353 | _ctx.ui->modal_elevator_top->regenerate(); |
| 354 | |
| 355 | _ctx.ui->modal_camp->show = true; |
nothing calls this directly
no test coverage detected