1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-09-27 21:58:13 +00:00

fixed a crash when setting new variations

This commit is contained in:
Zeno Rogue 2020-08-01 16:43:21 +02:00
parent 79a02a0c2e
commit c1554ce0f2

View File

@ -698,15 +698,13 @@ EX namespace gp {
config = human_representation(xy); config = human_representation(xy);
auto g = screens; auto g = screens;
if(xy.first == 0 && xy.second == 0) xy.first = 1; if(xy.first == 0 && xy.second == 0) xy.first = 1;
stop_game();
param = xy;
if(xy.first == 1 && xy.second == 0) { if(xy.first == 1 && xy.second == 0) {
stop_game(); set_variation(eVariation::pure); set_variation(eVariation::pure);
} }
else if(xy.first == 1 && xy.second == 1 && S3 == 3) { else if(xy.first == 1 && xy.second == 1 && S3 == 3) {
stop_game(); set_variation(eVariation::bitruncated); set_variation(eVariation::bitruncated);
}
else {
param = xy;
stop_game(); set_variation(eVariation::goldberg);
} }
start_game(); start_game();
screens = g; screens = g;