From 2d5e68a86d3fdc966f036c910417c74768ca4da7 Mon Sep 17 00:00:00 2001 From: Wanne Date: Sun, 31 May 2015 18:16:06 +0000 Subject: [PATCH] - Commented out restricted Scroll ID/viewport as viewport for A10_B1 map shifts around in non-640x480 resolutions. As such 'Restricted Scroll ID' textbox becomes irrelevant in mapeditor (by Buggler) git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7882 3b4a5df2-a311-0410-b5c6-a8a6f20db521 --- TileEngine/renderworld.cpp | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/TileEngine/renderworld.cpp b/TileEngine/renderworld.cpp index 17dc3fab..b7cd5b3e 100644 --- a/TileEngine/renderworld.cpp +++ b/TileEngine/renderworld.cpp @@ -3882,7 +3882,10 @@ void InitRenderParams( UINT8 ubRestrictionID ) gBottomRightWorldLimitY = ( ( WORLD_ROWS / 2 ) * CELL_X_SIZE ); break; - case 1: // BAEMENT LEVEL 1 + /* // Buggler: Commented out restricted Scroll ID/viewport as viewport for A10_B1 map shifts around in non-640x480 resolutions + // no issue on having the usual scrollable viewport both during gameplay and in mapeditor + // code may served as reference for fixing viewport issues larger than standard-sized maps on very high resolutions, e.g. UHD. + case 1: // BASEMENT LEVEL 1 gTopLeftWorldLimitX = ( 3 * WORLD_ROWS / 10 ) * CELL_X_SIZE; gTopLeftWorldLimitY = ( WORLD_ROWS / 2 ) * CELL_X_SIZE; @@ -3896,6 +3899,22 @@ void InitRenderParams( UINT8 ubRestrictionID ) gBottomRightWorldLimitX = ( 7 * WORLD_ROWS / 10 ) * CELL_X_SIZE; gBottomRightWorldLimitY = ( WORLD_ROWS / 2 ) * CELL_X_SIZE; break; + */ + + default: //Default! + + gTopLeftWorldLimitX = CELL_X_SIZE; + gTopLeftWorldLimitY = ( WORLD_ROWS / 2 ) * CELL_X_SIZE; + + gTopRightWorldLimitX = ( WORLD_COLS / 2 ) * CELL_Y_SIZE; + gTopRightWorldLimitY = CELL_X_SIZE; + + gBottomLeftWorldLimitX = ( ( WORLD_COLS / 2 ) * CELL_Y_SIZE ); + gBottomLeftWorldLimitY = ( WORLD_ROWS * CELL_Y_SIZE ); + + gBottomRightWorldLimitX = ( WORLD_COLS * CELL_Y_SIZE ); + gBottomRightWorldLimitY = ( ( WORLD_ROWS / 2 ) * CELL_X_SIZE ); + break; }