mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-11-23 21:07:17 +00:00
rogueviz:: slide_error used
This commit is contained in:
parent
367ff6f035
commit
4af75fe611
@ -354,13 +354,18 @@ auto fifteen_hook =
|
||||
fifteen_slides.emplace_back(
|
||||
tour::slide{s, 100, LEGAL::NONE | QUICKGEO, text,
|
||||
[=] (presmode mode) {
|
||||
string fname = "fifteen/" + lev + ".lev";
|
||||
if(!file_exists(fname)) {
|
||||
slide_error(mode, "file " + fname + " not found");
|
||||
return;
|
||||
}
|
||||
setCanvas(mode, '0');
|
||||
if(mode == pmStart) {
|
||||
slide_backup(mapeditor::drawplayer, mapeditor::drawplayer);
|
||||
slide_backup(vid.wallmode, 2);
|
||||
slide_backup(pconf.scale, .6);
|
||||
stop_game();
|
||||
mapstream::loadMap("fifteen/" + lev + ".lev");
|
||||
mapstream::loadMap(fname);
|
||||
fullcenter();
|
||||
if(lev == "coiled" || lev == "mobiusband")
|
||||
View = spin(90*degree) * View;
|
||||
|
@ -373,13 +373,7 @@ void brick_slide(int i, presmode mode, eGeometry geom, eModel md, int anim) {
|
||||
void ply_slide(tour::presmode mode, eGeometry geom, eModel md, bool anim) {
|
||||
using namespace tour;
|
||||
if(!ply::staircase.available()) {
|
||||
empty_screen(mode, 0x400000);
|
||||
add_stat(mode, [] {
|
||||
dialog::init();
|
||||
dialog::addTitle("(model not available)", 0xFF0000, 150);
|
||||
dialog::display();
|
||||
return true;
|
||||
});
|
||||
slide_error(mode, "(model not available)");
|
||||
return;
|
||||
}
|
||||
if(mode == pmStartAll) {
|
||||
|
Loading…
Reference in New Issue
Block a user