Browse Source

Don't precache CTF related resources (CTF is not implemented properly). Fix #406 (#414)

Remove gearbox_client.cpp and other unused files
opfor
Roman Chistokhodov 11 months ago committed by GitHub
parent
commit
033f23a0a0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      dlls/CMakeLists.txt
  2. 22
      dlls/client.cpp
  3. 4
      dlls/gearbox/ctf_gamerules.cpp
  4. 12
      dlls/gearbox/ctf_powerups.cpp
  5. 2096
      dlls/gearbox/gearbox_client.cpp
  6. 25
      dlls/gearbox/gearbox_explode.h
  7. 21
      dlls/gearbox/gearbox_monsters.h
  8. 79
      dlls/gearbox/gearbox_player.h

1
dlls/CMakeLists.txt

@ -47,7 +47,6 @@ set (SVDLL_SOURCES @@ -47,7 +47,6 @@ set (SVDLL_SOURCES
gearbox/eagle.cpp
gearbox/fgrunt.cpp
gearbox/func_tank_of.cpp
# gearbox/gearbox_client.cpp
gearbox/gearbox_effects.cpp
gearbox/gearbox_triggers.cpp
gearbox/gearbox_utils.cpp

22
dlls/client.cpp

@ -941,28 +941,6 @@ void ClientPrecache( void ) @@ -941,28 +941,6 @@ void ClientPrecache( void )
// Teleport sounds. Used by trigger_xen_return
PRECACHE_SOUND( "debris/beamstart7.wav" );
PRECACHE_MODEL( "models/flag.mdl" );
PRECACHE_MODEL( "models/civ_stand.mdl" );
PRECACHE_MODEL( "models/mil_stand.mdl" );
PRECACHE_MODEL( "models/w_accelerator.mdl" );
PRECACHE_MODEL( "models/w_backpack.mdl" );
PRECACHE_MODEL( "models/w_fgrenade.mdl" );
PRECACHE_MODEL( "models/w_health.mdl" );
PRECACHE_MODEL( "models/w_icon.mdl" );
PRECACHE_MODEL( "models/w_jumppack.mdl" );
PRECACHE_MODEL( "models/w_porthev.mdl" );
PRECACHE_SOUND( "ctf/bm_flagtaken.wav" );
PRECACHE_SOUND( "ctf/civ_flag_capture.wav" );
PRECACHE_SOUND( "ctf/itemthrow.wav" );
PRECACHE_SOUND( "ctf/marine_flag_capture.wav" );
PRECACHE_SOUND( "ctf/pow_armor_charge.wav" );
PRECACHE_SOUND( "ctf/pow_backpack.wav" );
PRECACHE_SOUND( "ctf/pow_big_jump.wav" );
PRECACHE_SOUND( "ctf/pow_health_charge.wav" );
PRECACHE_SOUND( "ctf/soldier_flagtaken.wav" );
}
/*

4
dlls/gearbox/ctf_gamerules.cpp

@ -200,8 +200,8 @@ void CCTFMultiplay::Think(void) @@ -200,8 +200,8 @@ void CCTFMultiplay::Think(void)
frags_remaining = bestfrags;
}
if (!g_bSpawnedRunes)
SpawnRunes();
//if (!g_bSpawnedRunes)
// SpawnRunes();
if (m_flFlagStatusTime && m_flFlagStatusTime <= gpGlobals->time)
GetFlagStatus(NULL);

12
dlls/gearbox/ctf_powerups.cpp

@ -114,12 +114,18 @@ void CPowerupCTFBase::Spawn(void) @@ -114,12 +114,18 @@ void CPowerupCTFBase::Spawn(void)
m_iszPrintName = ALLOC_STRING(printname);
}
SET_MODEL(ENT(pev), SelectRuneRandom(&m_iRuneFlag) );
PRECACHE_MODEL("models/w_accelerator.mdl");
PRECACHE_MODEL("models/w_backpack.mdl");
PRECACHE_MODEL("models/w_health.mdl");
PRECACHE_MODEL("models/w_jumppack.mdl");
PRECACHE_MODEL("models/w_porthev.mdl");
SET_MODEL(ENT(pev), modelname);
}
else
{
SET_MODEL(ENT(pev), GetRuneModel());
const char* modelname = GetRuneModel();
PRECACHE_MODEL(modelname);
SET_MODEL(ENT(pev), modelname);
m_iRuneFlag = GetRuneFlag();
}

2096
dlls/gearbox/gearbox_client.cpp

File diff suppressed because it is too large Load Diff

25
dlls/gearbox/gearbox_explode.h

@ -1,25 +0,0 @@ @@ -1,25 +0,0 @@
/***
*
* Copyright (c) 1996-2001, Valve LLC. All rights reserved.
*
* This product contains software technology licensed from Id
* Software, Inc. ("Id Technology"). Id Technology (c) 1996 Id Software, Inc.
* All Rights Reserved.
*
* Use, distribution, and modification of this source code and/or resulting
* object code is restricted to non-commercial enhancements to products from
* Valve LLC. All other use, distribution, or modification is prohibited
* without written permission from Valve LLC.
*
****/
#ifndef GEARBOX_EXPLODE_H
#define GEARBOX_EXPLODE_H
extern DLL_GLOBAL short g_sModelIndexSpore1;
extern DLL_GLOBAL short g_sModelIndexSpore2;
extern DLL_GLOBAL short g_sModelIndexSpore3;
extern DLL_GLOBAL short g_sModelIndexBigSpit;
extern DLL_GLOBAL short g_sModelIndexTinySpit;
#endif // GEARBOX_EXPLODE_H

21
dlls/gearbox/gearbox_monsters.h

@ -1,21 +0,0 @@ @@ -1,21 +0,0 @@
/***
*
* Copyright (c) 1996-2001, Valve LLC. All rights reserved.
*
* This product contains software technology licensed from Id
* Software, Inc. ("Id Technology"). Id Technology (c) 1996 Id Software, Inc.
* All Rights Reserved.
*
* Use, distribution, and modification of this source code and/or resulting
* object code is restricted to non-commercial enhancements to products from
* Valve LLC. All other use, distribution, or modification is prohibited
* without written permission from Valve LLC.
*
****/
#ifndef GEARBOX_MONSTERS_H
#define GEARBOX_MONSTERS_H
#define EF_GLOWSHELL 2048
#endif // GEARBOX_MONSTERS_H

79
dlls/gearbox/gearbox_player.h

@ -1,79 +0,0 @@ @@ -1,79 +0,0 @@
/***
*
* Copyright (c) 1996-2001, Valve LLC. All rights reserved.
*
* This product contains software technology licensed from Id
* Software, Inc. ("Id Technology"). Id Technology (c) 1996 Id Software, Inc.
* All Rights Reserved.
*
* Use, distribution, and modification of this source code and/or resulting
* object code is restricted to non-commercial enhancements to products from
* Valve LLC. All other use, distribution, or modification is prohibited
* without written permission from Valve LLC.
*
****/
#ifndef GEARBOX_PLAYER_H
#define GEARBOX_PLAYER_H
enum Player_Menu {
Team_Menu,
Team_Menu_IG,
};
#define PFLAG_ONROPE ( 1 << 6 )
class CGearboxPlayer : public CBasePlayer
{
public:
virtual int Save(CSave &save);
virtual int Restore(CRestore &restore);
BOOL FlashlightIsOn(void);
void FlashlightTurnOn(void);
void FlashlightTurnOff(void);
static TYPEDESCRIPTION m_playerSaveData[];
virtual void Spawn(void);
private:
BOOL m_fInXen;
BOOL m_fIsFrozen;
public:
int m_bHasFlag;
void ShowMenu(int bitsValidSlots, int nDisplayTime, BOOL fNeedMore, char *pszText);
int m_iMenu;
float m_flNextTeamChange;
CBasePlayer *pFlagCarrierKiller;
CBasePlayer *pFlagReturner;
CBasePlayer *pCarrierHurter;
float m_flCarrierHurtTime;
float m_flCarrierPickupTime;
float m_flFlagCarrierKillTime;
float m_flFlagReturnTime;
float m_flFlagStatusTime;
float m_flRegenTime;
int m_iRuneStatus;
void W_FireHook(void);
void Throw_Grapple(void);
bool m_bHook_Out;
bool m_bOn_Hook;
CBaseEntity *m_ppHook;
void Service_Grapple(void);
private:
friend class CDisplacer;
friend class CTriggerXenReturn;
friend class CPlayerFreeze;
};
#endif // GEARBOX_PLAYER_H
Loading…
Cancel
Save