I've been trying to test a little patch to get rid of the selection of non-activatable upgrades. However when I try to run this it doesn't work. Also when I introduce a null pointer dereference in that function Trem doesn't segfault.
When I compare the stuff in the build dir with the 1.1.0 distribution I see a lot of files in a client dir, one of which contains the function in assembler form.
To run the game however I need to copy some paks from the distribution. My hunch is that one of those paks overrides the new stuff.
Could anyone tell me what I'm doing wrong?
For the record, this is what I'm trying to do:
static qboolean CG_UpgradeSelectable( upgrade_t upgrade )
{
if( !BG_InventoryContainsUpgrade( upgrade, cg.snap->ps.stats ) )
return qfalse;
// START ADDITION
if( upgrade == UP_LIGHTARMOUR || upgrade == UP_HELMET ||
upgrade == UP_BATTPACK || upgrade == UP_BATTLESUIT )
return qfalse;
// END ADDITION
return qtrue;
}