mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-11-27 14:37:16 +00:00
ads-game:: spacetime functions renamed
This commit is contained in:
parent
17e2a56320
commit
c6dad6ee99
@ -131,7 +131,9 @@ void switch_replay();
|
||||
void switch_pause();
|
||||
void replay_animation();
|
||||
|
||||
void switch_underlying();
|
||||
bool in_spacetime();
|
||||
void switch_spacetime();
|
||||
void switch_spacetime_to(bool);
|
||||
bool ads_draw_cell(cell *c, const shiftmatrix& V);
|
||||
extern transmatrix Duality;
|
||||
extern int use_duality;
|
||||
|
@ -27,7 +27,15 @@ int use_duality = 2;
|
||||
|
||||
transmatrix Duality;
|
||||
|
||||
void switch_underlying() {
|
||||
void switch_spacetime_to(bool b) {
|
||||
if(in_spacetime() != b) switch_spacetime();
|
||||
}
|
||||
|
||||
bool in_spacetime() {
|
||||
return main_rock ? hyperbolic : rotspace;
|
||||
}
|
||||
|
||||
void switch_spacetime() {
|
||||
clearMessages();
|
||||
|
||||
if(main_rock) {
|
||||
@ -173,6 +181,7 @@ void switch_replay() {
|
||||
auto view_hooks =
|
||||
+ arg::add3("-ds-recenter", [] { current = Id; })
|
||||
+ arg::add3("-ds-record", switch_replay)
|
||||
+ arg::add3("-ds-switchu", switch_underlying);
|
||||
+ arg::add3("-ads-duality", [] { arg::shift(); use_duality = arg::argi(); })
|
||||
+ arg::add3("-ds-switchu", switch_spacetime);
|
||||
|
||||
}}
|
||||
|
Loading…
Reference in New Issue
Block a user