diff --git a/crystal.cpp b/crystal.cpp index c1575ece..21b78de1 100644 --- a/crystal.cpp +++ b/crystal.cpp @@ -858,6 +858,12 @@ void show() { dialog::addBreak(50); dialog::addBoolItem("view coordinates in the cheat mode", view_coordinates, 'v'); dialog::add_action([]() { view_coordinates = !view_coordinates; }); + if(geometry == gCrystal) { + dialog::addBoolItem("3D display", rug::rugged, 'r'); + dialog::add_action([]() { pushScreen(rug::show); }); + } + else + dialog::addBreak(100); dialog::addBack(); dialog::display(); } diff --git a/hyper.h b/hyper.h index 13f0da4d..1483fea4 100644 --- a/hyper.h +++ b/hyper.h @@ -4154,6 +4154,7 @@ namespace crystal { int dist_alt(cell *c); int dist_relative(cell *c); void show(); + void init_rotation(); } hyperpoint get_warp_corner(cell *c, int cid); diff --git a/rug.cpp b/rug.cpp index 05e0f12c..ff69af1a 100644 --- a/rug.cpp +++ b/rug.cpp @@ -1396,6 +1396,13 @@ void init_model() { qvalid = 0; dt = 0; queueiter = 0; err_zero_current = err_zero; + if(geometry == gCrystal && surface::sh == surface::dsNone) { + surface::sh = surface::dsCrystal; + crystal::init_rotation(); + good_shape = true; + return; + } + try { buildRug(); while(good_shape && subdivide_further()) subdivide();