Browse Source

Use egon as railgun.

coldice
Night Owl 8 years ago
parent
commit
2ef65ad280
  1. 6
      cl_dll/CMakeLists.txt
  2. 12
      cl_dll/hl/hl_weapons.cpp
  3. 4
      dlls/CMakeLists.txt
  4. 13
      dlls/egon.cpp
  5. 3
      dlls/skill.h
  6. 4
      dlls/weapons.cpp
  7. 4
      dlls/weapons.h

6
cl_dll/CMakeLists.txt

@ -31,14 +31,14 @@ set(CMAKE_CXX_FLAGS "${CMAKE_C_FLAGS}")
set (CLDLL_SOURCES set (CLDLL_SOURCES
# ../dlls/crossbow.cpp # ../dlls/crossbow.cpp
../dlls/crowbar.cpp ../dlls/crowbar.cpp
# ../dlls/egon.cpp ../dlls/egon.cpp
# ../dlls/gauss.cpp # ../dlls/gauss.cpp
# ../dlls/handgrenade.cpp ../dlls/handgrenade.cpp
# ../dlls/hornetgun.cpp # ../dlls/hornetgun.cpp
# ../dlls/mp5.cpp # ../dlls/mp5.cpp
# ../dlls/python.cpp # ../dlls/python.cpp
# ../dlls/rpg.cpp # ../dlls/rpg.cpp
# ../dlls/satchel.cpp ../dlls/satchel.cpp
# ../dlls/shotgun.cpp # ../dlls/shotgun.cpp
# ../dlls/squeakgrenade.cpp # ../dlls/squeakgrenade.cpp
../dlls/tripmine.cpp ../dlls/tripmine.cpp

12
cl_dll/hl/hl_weapons.cpp

@ -61,9 +61,9 @@ CMP5 g_Mp5;
CCrossbow g_Crossbow; CCrossbow g_Crossbow;
CShotgun g_Shotgun; CShotgun g_Shotgun;
CRpg g_Rpg; CRpg g_Rpg;
CGauss g_Gauss; CGauss g_Gauss;*/
CEgon g_Egon; CEgon g_Egon;
CHgun g_HGun;*/ //CHgun g_HGun;
CHandGrenade g_HandGren; CHandGrenade g_HandGren;
CSatchel g_Satchel; CSatchel g_Satchel;
CTripmine g_Tripmine; CTripmine g_Tripmine;
@ -631,9 +631,9 @@ void HUD_InitClientWeapons( void )
HUD_PrepEntity( &g_Crossbow, &player ); HUD_PrepEntity( &g_Crossbow, &player );
HUD_PrepEntity( &g_Shotgun, &player ); HUD_PrepEntity( &g_Shotgun, &player );
HUD_PrepEntity( &g_Rpg, &player ); HUD_PrepEntity( &g_Rpg, &player );
HUD_PrepEntity( &g_Gauss, &player ); HUD_PrepEntity( &g_Gauss, &player );*/
HUD_PrepEntity( &g_Egon, &player ); HUD_PrepEntity( &g_Egon, &player );
HUD_PrepEntity( &g_HGun, &player );*/ //HUD_PrepEntity( &g_HGun, &player );
HUD_PrepEntity( &g_HandGren, &player ); HUD_PrepEntity( &g_HandGren, &player );
HUD_PrepEntity( &g_Satchel, &player ); HUD_PrepEntity( &g_Satchel, &player );
HUD_PrepEntity( &g_Tripmine, &player ); HUD_PrepEntity( &g_Tripmine, &player );
@ -724,11 +724,11 @@ void HUD_WeaponsPostThink( local_state_s *from, local_state_s *to, usercmd_t *cm
break; break;
case WEAPON_GAUSS: case WEAPON_GAUSS:
pWeapon = &g_Gauss; pWeapon = &g_Gauss;
break; break;*/
case WEAPON_EGON: case WEAPON_EGON:
pWeapon = &g_Egon; pWeapon = &g_Egon;
break; break;
case WEAPON_HORNETGUN: /*case WEAPON_HORNETGUN:
pWeapon = &g_HGun; pWeapon = &g_HGun;
break;*/ break;*/
case WEAPON_HANDGRENADE: case WEAPON_HANDGRENADE:

4
dlls/CMakeLists.txt

@ -51,7 +51,7 @@ set (SVDLL_SOURCES
defaultai.cpp defaultai.cpp
doors.cpp doors.cpp
effects.cpp effects.cpp
# egon.cpp egon.cpp
explode.cpp explode.cpp
flyingmonster.cpp flyingmonster.cpp
func_break.cpp func_break.cpp
@ -137,7 +137,7 @@ set (SVDLL_SOURCES
coldice/ashotgun.cpp coldice/ashotgun.cpp
coldice/cluster_grenade.cpp coldice/cluster_grenade.cpp
coldice/mac_10.cpp coldice/mac_10.cpp
coldice/railgun.cpp # coldice/railgun.cpp
coldice/sword.cpp coldice/sword.cpp
coldice/boltgun.cpp coldice/boltgun.cpp
coldice/double_uzi.cpp coldice/double_uzi.cpp

13
dlls/egon.cpp

@ -49,7 +49,8 @@ enum egon_e {
EGON_HOLSTER EGON_HOLSTER
}; };
LINK_ENTITY_TO_CLASS( weapon_egon, CEgon ) LINK_ENTITY_TO_CLASS( weapon_railgun, CEgon )
LINK_ENTITY_TO_CLASS( weapon_gauss, CEgon )
void CEgon::Spawn() void CEgon::Spawn()
{ {
@ -57,7 +58,7 @@ void CEgon::Spawn()
m_iId = WEAPON_EGON; m_iId = WEAPON_EGON;
SET_MODEL( ENT( pev ), "models/w_egon.mdl" ); SET_MODEL( ENT( pev ), "models/w_egon.mdl" );
m_iDefaultAmmo = EGON_DEFAULT_GIVE; m_iDefaultAmmo = RAILGUN_DEFAULT_GIVE;
FallInit();// get ready to fall down. FallInit();// get ready to fall down.
} }
@ -114,16 +115,16 @@ void CEgon::Holster( int skiplocal /* = 0 */ )
int CEgon::GetItemInfo( ItemInfo *p ) int CEgon::GetItemInfo( ItemInfo *p )
{ {
p->pszName = STRING( pev->classname ); p->pszName = STRING( pev->classname );
p->pszAmmo1 = "uranium"; p->pszAmmo1 = "slug";
p->iMaxAmmo1 = URANIUM_MAX_CARRY; p->iMaxAmmo1 = RAILGUN_MAX_CARRY;
p->pszAmmo2 = NULL; p->pszAmmo2 = NULL;
p->iMaxAmmo2 = -1; p->iMaxAmmo2 = -1;
p->iMaxClip = WEAPON_NOCLIP; p->iMaxClip = WEAPON_NOCLIP;
p->iSlot = 3; p->iSlot = 3;
p->iPosition = 2; p->iPosition = 2;
p->iId = m_iId = WEAPON_EGON; p->iId = m_iId = WEAPON_RAILGUN;
p->iFlags = 0; p->iFlags = 0;
p->iWeight = EGON_WEIGHT; p->iWeight = RAILGUN_WEIGHT;
return 1; return 1;
} }

3
dlls/skill.h

@ -102,7 +102,8 @@ struct skilldata_t
float plrDmgClusterGrenade; float plrDmgClusterGrenade;
float plrDmgRocket; float plrDmgRocket;
float plrDmgRailgun; float plrDmgRailgun;
float plrDmgPulse; float plrDmgEgonNarrow;
float plrDmgEgonWide;
float plrDmgHandGrenade; float plrDmgHandGrenade;
float plrDmgSatchel; float plrDmgSatchel;
float plrDmgTripmine; float plrDmgTripmine;

4
dlls/weapons.cpp

@ -1665,7 +1665,7 @@ TYPEDESCRIPTION CGauss::m_SaveData[] =
}; };
IMPLEMENT_SAVERESTORE( CGauss, CBasePlayerWeapon ) IMPLEMENT_SAVERESTORE( CGauss, CBasePlayerWeapon )
*/
TYPEDESCRIPTION CEgon::m_SaveData[] = TYPEDESCRIPTION CEgon::m_SaveData[] =
{ {
//DEFINE_FIELD( CEgon, m_pBeam, FIELD_CLASSPTR ), //DEFINE_FIELD( CEgon, m_pBeam, FIELD_CLASSPTR ),
@ -1679,7 +1679,7 @@ TYPEDESCRIPTION CEgon::m_SaveData[] =
}; };
IMPLEMENT_SAVERESTORE( CEgon, CBasePlayerWeapon ) IMPLEMENT_SAVERESTORE( CEgon, CBasePlayerWeapon )
*/
TYPEDESCRIPTION CSatchel::m_SaveData[] = TYPEDESCRIPTION CSatchel::m_SaveData[] =
{ {
DEFINE_FIELD( CSatchel, m_chargeReady, FIELD_INTEGER ), DEFINE_FIELD( CSatchel, m_chargeReady, FIELD_INTEGER ),

4
dlls/weapons.h

@ -824,7 +824,7 @@ private:
unsigned short m_usGaussFire; unsigned short m_usGaussFire;
unsigned short m_usGaussSpin; unsigned short m_usGaussSpin;
}; };
*/
class CEgon : public CBasePlayerWeapon class CEgon : public CBasePlayerWeapon
{ {
public: public:
@ -888,7 +888,7 @@ private:
unsigned short m_usEgonFire; unsigned short m_usEgonFire;
}; };
/*
class CHgun : public CBasePlayerWeapon class CHgun : public CBasePlayerWeapon
{ {
public: public:

Loading…
Cancel
Save