mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-05-23 17:44:07 +00:00
'special' geometry change
This commit is contained in:
parent
99e2d95e82
commit
39f82e55ba
10
tour.cpp
10
tour.cpp
@ -29,7 +29,8 @@ enum presmode {
|
|||||||
pmStartAll = 0,
|
pmStartAll = 0,
|
||||||
pmStart = 1, pmFrame = 2, pmStop = 3, pmKey = 4, pmRestart = 5,
|
pmStart = 1, pmFrame = 2, pmStop = 3, pmKey = 4, pmRestart = 5,
|
||||||
pmAfterFrame = 6,
|
pmAfterFrame = 6,
|
||||||
pmGeometry = 11, pmGeometryReset = 13, pmGeometryStart = 15
|
pmGeometry = 11, pmGeometryReset = 13, pmGeometryStart = 15,
|
||||||
|
pmGeometrySpecial = 16
|
||||||
};
|
};
|
||||||
|
|
||||||
/** \brief slide definition */
|
/** \brief slide definition */
|
||||||
@ -48,7 +49,7 @@ struct slide {
|
|||||||
|
|
||||||
/** \brief in which geometries does this slide work */
|
/** \brief in which geometries does this slide work */
|
||||||
namespace LEGAL {
|
namespace LEGAL {
|
||||||
enum flagtype { NONE, UNLIMITED, HYPERBOLIC, ANY, NONEUC };
|
enum flagtype { NONE, UNLIMITED, HYPERBOLIC, ANY, NONEUC, SPECIAL };
|
||||||
}
|
}
|
||||||
|
|
||||||
/** \brief when Enter pressed while showing the text, skip to the next slide immediately */
|
/** \brief when Enter pressed while showing the text, skip to the next slide immediately */
|
||||||
@ -214,6 +215,11 @@ bool handleKeyTour(int sym, int uni) {
|
|||||||
if(NUMBERKEY == '1' || NUMBERKEY == '2') {
|
if(NUMBERKEY == '1' || NUMBERKEY == '2') {
|
||||||
int legal = slides[currentslide].flags & 7;
|
int legal = slides[currentslide].flags & 7;
|
||||||
|
|
||||||
|
if(legal == LEGAL::SPECIAL) {
|
||||||
|
presentation(pmGeometrySpecial);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
if(legal == LEGAL::NONE || legal == LEGAL::HYPERBOLIC) {
|
if(legal == LEGAL::NONE || legal == LEGAL::HYPERBOLIC) {
|
||||||
addMessage(XLAT("You cannot change geometry in this slide."));
|
addMessage(XLAT("You cannot change geometry in this slide."));
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user