Merge branch 'master' into ExtraMercs

This commit is contained in:
Asdow
2023-07-26 13:17:49 +03:00
754 changed files with 9435 additions and 74371 deletions
+16 -22
View File
@@ -1,6 +1,3 @@
#ifdef PRECOMPILEDHEADERS
#include "Tactical All.h"
#else
#include "builddefines.h"
#include <stdio.h>
#include <time.h>
@@ -73,7 +70,6 @@
// HEADROCK HAM 3.6: This is required for Stat Progress Bars
#include "Campaign.h"
#include "Food.h" // added by Flugente
#endif
//legion by Jazz
#include "Interface Utils.h"
@@ -4636,10 +4632,7 @@ void BtnClimbCallback(GUI_BUTTON *btn,INT32 reason)
if ( fNearLowerLevel )
{
if ((UsingNewInventorySystem() == true) && gpSMCurrentMerc->inv[BPACKPOCKPOS].exists() == true
//JMich.BackpackClimb
&& ((gGameExternalOptions.sBackpackWeightToClimb == -1) || (INT16)gpSMCurrentMerc->inv[BPACKPOCKPOS].GetWeightOfObjectInStack() + Item[gpSMCurrentMerc->inv[BPACKPOCKPOS].usItem].sBackpackWeightModifier > gGameExternalOptions.sBackpackWeightToClimb)
&& ((gGameExternalOptions.fUseGlobalBackpackSettings == TRUE) || (Item[gpSMCurrentMerc->inv[BPACKPOCKPOS].usItem].fAllowClimbing == FALSE)))
if (!gpSMCurrentMerc->CanClimbWithCurrentBackpack())
{
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, NewInvMessage[NIV_NO_CLIMB]);
return;
@@ -4650,10 +4643,7 @@ void BtnClimbCallback(GUI_BUTTON *btn,INT32 reason)
if ( fNearHeigherLevel )
{
if ((UsingNewInventorySystem() == true) && gpSMCurrentMerc->inv[BPACKPOCKPOS].exists() == true
//JMich.BackpackClimb
&& ((gGameExternalOptions.sBackpackWeightToClimb == -1) || (INT16)gpSMCurrentMerc->inv[BPACKPOCKPOS].GetWeightOfObjectInStack() + Item[gpSMCurrentMerc->inv[BPACKPOCKPOS].usItem].sBackpackWeightModifier > gGameExternalOptions.sBackpackWeightToClimb)
&& ((gGameExternalOptions.fUseGlobalBackpackSettings == TRUE) || (Item[gpSMCurrentMerc->inv[BPACKPOCKPOS].usItem].fAllowClimbing == FALSE)))
if (!gpSMCurrentMerc->CanClimbWithCurrentBackpack())
{
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, NewInvMessage[NIV_NO_CLIMB]);
return;
@@ -4666,10 +4656,7 @@ void BtnClimbCallback(GUI_BUTTON *btn,INT32 reason)
if (gGameExternalOptions.fCanClimbOnWalls == TRUE)
{
if ((UsingNewInventorySystem() == true) && gpSMCurrentMerc->inv[BPACKPOCKPOS].exists() == true
//JMich.BackpackClimb
&& ((gGameExternalOptions.sBackpackWeightToClimb == -1) || (INT16)gpSMCurrentMerc->inv[BPACKPOCKPOS].GetWeightOfObjectInStack() + Item[gpSMCurrentMerc->inv[BPACKPOCKPOS].usItem].sBackpackWeightModifier > gGameExternalOptions.sBackpackWeightToClimb)
&& ((gGameExternalOptions.fUseGlobalBackpackSettings == TRUE) || (Item[gpSMCurrentMerc->inv[BPACKPOCKPOS].usItem].fAllowClimbing == FALSE)))
if (!gpSMCurrentMerc->CanClimbWithCurrentBackpack())
{
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, NewInvMessage[NIV_NO_CLIMB]);
return;
@@ -4685,10 +4672,7 @@ void BtnClimbCallback(GUI_BUTTON *btn,INT32 reason)
if ( FindFenceJumpDirection( gpSMCurrentMerc, gpSMCurrentMerc->sGridNo, gpSMCurrentMerc->ubDirection, &bDirection ) )
{
if ((UsingNewInventorySystem() == true) && gpSMCurrentMerc->inv[BPACKPOCKPOS].exists() == true
//JMich.BackpackClimb
&& ((gGameExternalOptions.sBackpackWeightToClimb == -1) || (INT16)gpSMCurrentMerc->inv[BPACKPOCKPOS].GetWeightOfObjectInStack() + Item[gpSMCurrentMerc->inv[BPACKPOCKPOS].usItem].sBackpackWeightModifier > gGameExternalOptions.sBackpackWeightToClimb)
&& ((gGameExternalOptions.fUseGlobalBackpackSettings == TRUE) || (Item[gpSMCurrentMerc->inv[BPACKPOCKPOS].usItem].fAllowClimbing == FALSE)))
if (!gpSMCurrentMerc->CanClimbWithCurrentBackpack())
{
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, NewInvMessage[NIV_NO_CLIMB]);
return;
@@ -5215,7 +5199,7 @@ BOOLEAN InitializeTEAMPanel( )
if (iResolution >= _640x480 && iResolution < _800x600)
FilenameForBPP("INTERFACE\\bottom_bar.sti", VObjectDesc.ImageFile);
else if (iResolution < _1024x768)
else if (iResolution < _1280x720)
{
if (gGameOptions.ubSquadSize > 6)
{
@@ -5256,6 +5240,16 @@ BOOLEAN InitializeTEAMPanel( )
memset( gfTEAM_HandInvDispText, 0, sizeof( gfTEAM_HandInvDispText ) );
// Offset button coordinates to correct positions if squadsize is 10
if (iResolution == _1280x720)
{
UINT16 offset = 223;
TM_ENDTURN_X = xResOffset + (xResSize - 131) + offset;
TM_ROSTERMODE_X = xResOffset + (xResSize - 131) + offset;
TM_DISK_X = xResOffset + (xResSize - 131) + offset;
INTERFACE_CLOCK_TM_X = xResOffset + (xResSize - 86) + offset;
LOCATION_NAME_TM_X = xResOffset + (xResSize - 92) + offset;
}
// Create buttons
CHECKF( CreateTEAMPanelButtons( ) );
@@ -5374,7 +5368,7 @@ BOOLEAN ShutdownTEAMPanel( )
if( fRenderRadarScreen == FALSE )
{
// start rendering radar region again,
fRenderRadarScreen = TRUE;
fRenderRadarScreen = TRUE;
// remove squad panel
CreateDestroyMouseRegionsForSquadList( );