Fix personality check for backgrounds during IMP creation (#208)

This commit is contained in:
rftrdev
2023-08-23 00:34:54 -07:00
committed by GitHub
parent 28a5c76775
commit 6bae48658e
+3 -2
View File
@@ -15,6 +15,7 @@
#include "CharProfile.h" #include "CharProfile.h"
#include "soldier profile type.h" #include "soldier profile type.h"
#include "IMP Compile Character.h" #include "IMP Compile Character.h"
#include "IMP Disability Trait.h"
#include "GameSettings.h" #include "GameSettings.h"
#include "Interface.h" #include "Interface.h"
@@ -671,7 +672,7 @@ BOOLEAN IsBackGroundAllowed( UINT16 ubNumber )
return FALSE; return FALSE;
} }
switch ( iPersonality ) switch ( iChosenDisabilityTrait() )
{ {
case HEAT_INTOLERANT: case HEAT_INTOLERANT:
if ( zBackground[ ubNumber ].value[BG_DESERT] > 0 ) if ( zBackground[ ubNumber ].value[BG_DESERT] > 0 )
@@ -807,4 +808,4 @@ void BtnIMPBackgroundPreviousCallback(GUI_BUTTON *btn,INT32 reason)
usBackground = 0; usBackground = 0;
} }
} }
} }