diff --git a/Strategic/Map Screen Interface Bottom.cpp b/Strategic/Map Screen Interface Bottom.cpp index 410b5b65..7811a474 100644 --- a/Strategic/Map Screen Interface Bottom.cpp +++ b/Strategic/Map Screen Interface Bottom.cpp @@ -295,7 +295,8 @@ void RenderMapScreenInterfaceBottom( BOOLEAN fForceMapscreenFullRender ) // render whole panel // HEADROCK Changed this line to accept outside influence through the new boolean: - if ( fForceMapscreenFullRender == TRUE || fMapScreenBottomDirty == TRUE) + //if ( fForceMapscreenFullRender == TRUE || fMapScreenBottomDirty == TRUE) + if ( fMapScreenBottomDirty ) { // get and blt panel GetVideoObject(&hHandle, guiMAPBOTTOMPANEL ); diff --git a/Strategic/Map Screen Interface Map.cpp b/Strategic/Map Screen Interface Map.cpp index 5bd64897..8b5702d2 100644 --- a/Strategic/Map Screen Interface Map.cpp +++ b/Strategic/Map Screen Interface Map.cpp @@ -424,7 +424,10 @@ INT16 gpSamSectorY[ MAX_NUMBER_OF_SAMS ]; extern BOOLEAN fSamSiteFoundOrig[ MAX_NUMBER_OF_SAMS ]; // map region -SGPRect MapScreenRect={ (MAP_VIEW_START_X+MAP_GRID_X - 2), ( MAP_VIEW_START_Y+MAP_GRID_Y - 1), MAP_VIEW_START_X + MAP_VIEW_WIDTH - 1 + MAP_GRID_X , MAP_VIEW_START_Y+MAP_VIEW_HEIGHT-10+MAP_GRID_Y}; +SGPRect MapScreenRect={ (MAP_VIEW_START_X+MAP_GRID_X - 2), + ( MAP_VIEW_START_Y+MAP_GRID_Y - 1), + MAP_VIEW_START_X + MAP_VIEW_WIDTH - 1 + MAP_GRID_X , + MAP_VIEW_START_Y+MAP_VIEW_HEIGHT-10+MAP_GRID_Y}; extern SGPRect gOldClipRect; // symbol already declared globally in renderworld.cpp (jonathanl) @@ -1328,6 +1331,7 @@ BOOLEAN ShadeMapElem( INT16 sMapX, INT16 sMapY, INT32 iColor ) if( iColor != MAP_SHADE_BLACK ) { + //sScreenX +=1; // airspace /* if( sMapX == 1 ) @@ -3943,7 +3947,10 @@ void RestoreBackgroundForMapGrid( INT16 sMapX, INT16 sMapY ) void ClipBlitsToMapViewRegion( void ) { // the standard mapscreen rectangle doesn't work for clipping while zoomed... - SGPRect ZoomedMapScreenClipRect={ MAP_VIEW_START_X + MAP_GRID_X, MAP_VIEW_START_Y + MAP_GRID_Y - 1, MAP_VIEW_START_X + MAP_VIEW_WIDTH + MAP_GRID_X, MAP_VIEW_START_Y + MAP_VIEW_HEIGHT + MAP_GRID_Y - 10 }; + SGPRect ZoomedMapScreenClipRect={ MAP_VIEW_START_X + MAP_GRID_X, + MAP_VIEW_START_Y + MAP_GRID_Y - 1, + MAP_VIEW_START_X + MAP_VIEW_WIDTH + MAP_GRID_X, + MAP_VIEW_START_Y + MAP_VIEW_HEIGHT + MAP_GRID_Y - 10 }; SGPRect *pRectToUse; if (fZoomFlag) diff --git a/Strategic/mapscreen.cpp b/Strategic/mapscreen.cpp index 3688e8e2..e0465e3b 100644 --- a/Strategic/mapscreen.cpp +++ b/Strategic/mapscreen.cpp @@ -5257,9 +5257,9 @@ UINT32 MapScreenHandle(void) { fShowInventoryFlag = FALSE; // CHRISL: Added call to re-render the bottom panel - RenderMapScreenInterfaceBottom ( TRUE ); +// RenderMapScreenInterfaceBottom ( TRUE ); // set help text for item glow region - SetRegionFastHelpText( &gCharInfoHandRegion, pMiscMapScreenMouseRegionHelpText[ 0 ] ); +//XXXj? SetRegionFastHelpText( &gCharInfoHandRegion, pMiscMapScreenMouseRegionHelpText[ 0 ] ); } @@ -15377,7 +15377,8 @@ void RequestToggleMercInventoryPanel( void ) else { // Headrock. New line forces InvBottom rerender when the inventory is opened and closed. - RenderMapScreenInterfaceBottom ( TRUE ); + //RenderMapScreenInterfaceBottom ( TRUE ); + fMapScreenBottomDirty = TRUE; SetRegionFastHelpText( &gCharInfoHandRegion, pMiscMapScreenMouseRegionHelpText[ 0 ] ); } } diff --git a/Tactical/Interface Control.cpp b/Tactical/Interface Control.cpp index 923b55ac..fe7b34a2 100644 --- a/Tactical/Interface Control.cpp +++ b/Tactical/Interface Control.cpp @@ -930,7 +930,8 @@ void StartViewportOverlays( ) memcpy( &gOldClippingRect, &ClippingRect, sizeof( gOldClippingRect ) ); // Save old dirty clipping rect - memcpy( &gOldDirtyClippingRect, &ClippingRect, sizeof( gOldDirtyClippingRect ) ); +// memcpy( &gOldDirtyClippingRect, &ClippingRect, sizeof( gOldDirtyClippingRect ) ); + memcpy( &gOldDirtyClippingRect, &gDirtyClipRect, sizeof( gOldDirtyClippingRect ) ); // Set bottom clipping value for blitter clipping rect ClippingRect.iLeft = INTERFACE_START_X; @@ -954,6 +955,10 @@ void EndViewportOverlays( ) // Reset clipping rect memcpy( &ClippingRect, &gOldClippingRect, sizeof( gOldClippingRect ) ); memcpy( &gDirtyClipRect, &gOldDirtyClippingRect, sizeof( gOldDirtyClippingRect ) ); + +if(gDirtyClipRect.iBottom < SCREEN_HEIGHT) + gDirtyClipRect.iBottom = SCREEN_HEIGHT; + RestoreFontSettings( ); } diff --git a/TileEngine/Render Dirty.cpp b/TileEngine/Render Dirty.cpp index 1f2ec9f2..15afd759 100644 --- a/TileEngine/Render Dirty.cpp +++ b/TileEngine/Render Dirty.cpp @@ -208,6 +208,11 @@ INT32 iTempX, iTempY; //{ // return(-1 ); //} +//only time this shoudl be true is tactical..fix for games saved in broken state +extern UINT32 guiTacticalInterfaceFlags; +if (guiTacticalInterfaceFlags & 0x00000001) + if(gDirtyClipRect.iBottom < SCREEN_HEIGHT) + gDirtyClipRect.iBottom = SCREEN_HEIGHT; ClipX1= gDirtyClipRect.iLeft; ClipY1= gDirtyClipRect.iTop;