mirror of
https://github.com/fortressforever/fortressforever-2013.git
synced 2024-11-25 05:41:13 +00:00
Deleting old junk!
This commit is contained in:
parent
93dba7191b
commit
7c724636f4
6 changed files with 0 additions and 168 deletions
|
@ -1,27 +0,0 @@
|
|||
#include "cbase.h"
|
||||
#include "ff_sv_base_ff_goal.h"
|
||||
|
||||
|
||||
// Don't link this class to an entity. This class is only to be for inheritance.
|
||||
//LINK_ENTITY_TO_CLASS( base_ff_goal, CFF_SV_BaseFFGoal );
|
||||
|
||||
BEGIN_DATADESC( CFF_SV_BaseFFGoal )
|
||||
END_DATADESC()
|
||||
|
||||
|
||||
bool CanActivateGoal(CBasePlayer *pActivator)
|
||||
{
|
||||
// TODO: Check to see if this player needs to be on a certain team to activate this goal.
|
||||
// -->
|
||||
|
||||
// TODO: Check to see if this player needs to be a certain class to activate this goal.
|
||||
// -->
|
||||
|
||||
// TODO: Check to see if this player needs to own a certain item_ff_goal.
|
||||
// -->
|
||||
|
||||
// TODO: Check to see if this player needs to NOT own a certain item_ff_goal.
|
||||
// -->
|
||||
|
||||
return true;
|
||||
}
|
|
@ -1,23 +0,0 @@
|
|||
#pragma once
|
||||
|
||||
#ifndef FF_SV_BASE_FF_GOAL_H
|
||||
#define FF_SV_BASE_FF_GOAL_H
|
||||
|
||||
#include "ff_sv_teamcheck_target.h"
|
||||
|
||||
|
||||
class CFF_SV_BaseFFGoal : public CFF_SV_TeamcheckTarget
|
||||
{
|
||||
public:
|
||||
DECLARE_CLASS( CFF_SV_BaseFFGoal, CFF_SV_TeamcheckTarget );
|
||||
DECLARE_DATADESC();
|
||||
|
||||
CFF_SV_BaseFFGoal()
|
||||
{
|
||||
}
|
||||
|
||||
private:
|
||||
bool CanActivateGoal(CBasePlayer *pActivator);
|
||||
};
|
||||
|
||||
#endif // FF_SV_BASE_FF_GOAL_H
|
|
@ -1,37 +0,0 @@
|
|||
#include "cbase.h"
|
||||
#include "ff_sh_util.h"
|
||||
#include "ff_sv_info_ff_teamcheck.h"
|
||||
|
||||
|
||||
LINK_ENTITY_TO_CLASS( info_ff_teamcheck, CFF_SV_InfoFFTeamCheck );
|
||||
|
||||
BEGIN_DATADESC( CFF_SV_InfoFFTeamCheck )
|
||||
// Keyfields.
|
||||
DEFINE_KEYFIELD_NOT_SAVED( m_iTeamsAllowed, FIELD_INTEGER, "teams_allowed" ),
|
||||
|
||||
// Inputs.
|
||||
DEFINE_INPUTFUNC( FIELD_INTEGER, "SetTeamsAllowed", InputSetTeamsAllowed ),
|
||||
DEFINE_INPUTFUNC( FIELD_VOID, "SwapTeams", InputSwapTeams ),
|
||||
END_DATADESC()
|
||||
|
||||
|
||||
void CFF_SV_InfoFFTeamCheck::InputSetTeamsAllowed( inputdata_t &inputdata )
|
||||
{
|
||||
m_iTeamsAllowed = inputdata.value.Int();
|
||||
}
|
||||
|
||||
void CFF_SV_InfoFFTeamCheck::InputSwapTeams( inputdata_t &inputdata )
|
||||
{
|
||||
m_iTeamsAllowed = ~m_iTeamsAllowed;
|
||||
}
|
||||
|
||||
bool CFF_SV_InfoFFTeamCheck::IsTeamAllowed(int iTeamNum)
|
||||
{
|
||||
if(!m_iTeamsAllowed)
|
||||
return true;
|
||||
|
||||
if(m_iTeamsAllowed & FF_UTIL_GetTeamBit(iTeamNum))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
|
@ -1,27 +0,0 @@
|
|||
#pragma once
|
||||
|
||||
#ifndef FF_SV_INFO_FF_TEAMCHECK_H
|
||||
#define FF_SV_INFO_FF_TEAMCHECK_H
|
||||
|
||||
|
||||
class CFF_SV_InfoFFTeamCheck : public CBaseEntity
|
||||
{
|
||||
public:
|
||||
DECLARE_CLASS( CFF_SV_InfoFFTeamCheck, CBaseEntity );
|
||||
DECLARE_DATADESC();
|
||||
|
||||
CFF_SV_InfoFFTeamCheck()
|
||||
{
|
||||
}
|
||||
|
||||
bool IsTeamAllowed(int iTeamNum);
|
||||
|
||||
private:
|
||||
void InputSetTeamsAllowed( inputdata_t &inputdata );
|
||||
void InputSwapTeams( inputdata_t &inputdata );
|
||||
|
||||
int m_iTeamsAllowed;
|
||||
};
|
||||
|
||||
|
||||
#endif // FF_SV_INFO_FF_TEAMCHECK_H
|
|
@ -1,28 +0,0 @@
|
|||
#include "cbase.h"
|
||||
#include "ff_sv_info_ff_teamcheck.h"
|
||||
#include "ff_sv_teamcheck_target.h"
|
||||
|
||||
|
||||
// Don't link this class to an entity. This class is only to be for inheritance.
|
||||
//LINK_ENTITY_TO_CLASS( teamcheck_target, CFF_SV_TeamcheckTarget );
|
||||
|
||||
BEGIN_DATADESC( CFF_SV_TeamcheckTarget )
|
||||
// Keyfields.
|
||||
DEFINE_KEYFIELD_NOT_SAVED( m_iszTeamTarget, FIELD_STRING, "teamcheck_target" ),
|
||||
END_DATADESC()
|
||||
|
||||
|
||||
bool CFF_SV_TeamcheckTarget::IsTeamAllowed( int iTeamNum )
|
||||
{
|
||||
if( !m_iszTeamTarget )
|
||||
return true;
|
||||
|
||||
CFF_SV_InfoFFTeamCheck *pEnt = dynamic_cast<CFF_SV_InfoFFTeamCheck *>( gEntList.FindEntityByName( NULL, m_iszTeamTarget ) );
|
||||
if( !pEnt )
|
||||
return true;
|
||||
|
||||
if( pEnt->IsTeamAllowed( iTeamNum ) )
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
|
@ -1,26 +0,0 @@
|
|||
#pragma once
|
||||
|
||||
#ifndef FF_SV_TEAMCHECK_TARGET_H
|
||||
#define FF_SV_TEAMCHECK_TARGET_H
|
||||
|
||||
#include "ff_sv_env_ff_message.h"
|
||||
|
||||
|
||||
class CFF_SV_TeamcheckTarget : public CFF_SV_EnvFFMessage
|
||||
{
|
||||
public:
|
||||
DECLARE_CLASS( CFF_SV_TeamcheckTarget, CFF_SV_EnvFFMessage );
|
||||
DECLARE_DATADESC();
|
||||
|
||||
CFF_SV_TeamcheckTarget()
|
||||
{
|
||||
}
|
||||
|
||||
bool IsTeamAllowed(int iTeamNum);
|
||||
|
||||
private:
|
||||
string_t m_iszTeamTarget;
|
||||
};
|
||||
|
||||
|
||||
#endif // FF_SV_TEAMCHECK_TARGET_H
|
Loading…
Reference in a new issue