diff --git a/changelog.txt b/changelog.txt index 6ecb84ed..ee086eec 100644 --- a/changelog.txt +++ b/changelog.txt @@ -2219,3 +2219,11 @@ Gameplay bugfixes - you can now use '1' and arrows to move points in the Hypersian Rug mode, and '2' and '3' to rotate by 180 and 90 degrees ('4' to enable the ODS projection used in https://www.youtube.com/watch?v=tT80boNjP_A is compiled out) - fixed fieldpattern-based lands (Blizzard, Volcanic, Ruined City) on the torus - improved Ocean and Volcanic tides when sight range is set to more than 7 + +2018.02.03 21:45 version 10.3g +- fixed the sorting of local scores +- high quality screenshots can now be saved with OpenGL (this works faster and works with Hypersian Rug) +- rewritten the stereo vision -- it has more options now +- Hypersian Rug now works on Android, and it is controllable by rotating the device (combined with "stereo version" Cardboard VR should be supported) +- fixed a crash bug in the iOS version + diff --git a/init.cpp b/init.cpp index 29e45b7a..27195245 100644 --- a/init.cpp +++ b/init.cpp @@ -15,9 +15,9 @@ #define NOLICENSE #endif -#define VER "10.3f" -#define VERNUM 10306 -#define VERNUM_HEX 0xA0A6 +#define VER "10.3g" +#define VERNUM 10307 +#define VERNUM_HEX 0xA0A7 #define GEN_M 0 #define GEN_F 1 @@ -758,8 +758,10 @@ void mobile_draw(MOBPAR_FORMAL) { static int lticks_rug; +#if CAP_RUG if(andmode == 1 && !inmenu && rug::rugged && clicked) - rug::move_forward((ticks - lticks_rug) / 2500); + rug::move_forward((ticks - lticks_rug) / 2500.); +#endif lticks_rug = ticks; diff --git a/renderbuffer.cpp b/renderbuffer.cpp index 4b840424..bcd3388c 100644 --- a/renderbuffer.cpp +++ b/renderbuffer.cpp @@ -79,6 +79,7 @@ renderbuffer::renderbuffer(int x, int y, bool gl) : x(x), y(y) { FramebufferName = renderedTexture = 0; else valid = true; + GLERR("initialization"); } #endif diff --git a/rug.cpp b/rug.cpp index dd44e9b1..eec60ec6 100644 --- a/rug.cpp +++ b/rug.cpp @@ -86,7 +86,7 @@ struct triangle { vector points; vector triangles; -bool rug_perspective = false; +bool rug_perspective = ISANDROID; // extra geometry functions //-------------------------- @@ -1138,7 +1138,11 @@ void drawRugScene() { glClearColor(0.05,0.05,0.05,1); else glcolorClear(backcolor << 8 | 0xFF); +#ifdef GLES_ONLY glClearDepthf(1.0f); +#else + glClearDepth(1.0f); +#endif glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); glDisable(GL_BLEND); @@ -1316,7 +1320,7 @@ void apply_rotation(const transmatrix& t) { } void move_forward(ld distance) { - if(rug_perspective) push_all_points(2, -distance); + if(rug_perspective) push_all_points(2, distance); else model_distance /= exp(distance); } @@ -1349,8 +1353,14 @@ bool handlekeys(int sym, int uni) { return true; } #if !CAP_SDL - else if(uni == SDLK_PAGEUP || uni == '[') move_forward(.1); - else if(uni == SDLK_PAGEDOWN || uni == ']') move_forward(-.1); + else if(uni == SDLK_PAGEUP || uni == '[') { + move_forward(.1); + return true; + } + else if(uni == SDLK_PAGEDOWN || uni == ']') { + move_forward(-.1); + return true; + } #endif else return false; }