messing with built in location chat

This commit is contained in:
Dexter 2013-11-05 03:43:43 +00:00 committed by squeek
parent e50273e024
commit 845ebcae14
2 changed files with 13 additions and 5 deletions

View file

@ -1311,18 +1311,18 @@ const char *CFF_SH_Rules::GetChatFormat( bool bTeamOnly, CBasePlayer *pPlayer )
{
if ( pPlayer->GetTeamNumber() == TEAM_SPECTATOR )
{
pszFormat = "HL2MP_Chat_Spec";
pszFormat = "FF_Chat_Spec";
}
else
{
const char *chatLocation = GetChatLocation( bTeamOnly, pPlayer );
if ( chatLocation && *chatLocation )
{
pszFormat = "HL2MP_Chat_Team_Loc";
pszFormat = "FF_Chat_Team_Loc";
}
else
{
pszFormat = "HL2MP_Chat_Team";
pszFormat = "FF_Chat_Team";
}
}
}
@ -1331,17 +1331,23 @@ const char *CFF_SH_Rules::GetChatFormat( bool bTeamOnly, CBasePlayer *pPlayer )
{
if ( pPlayer->GetTeamNumber() != TEAM_SPECTATOR )
{
pszFormat = "HL2MP_Chat_All";
pszFormat = "FF_Chat_All";
}
else
{
pszFormat = "HL2MP_Chat_AllSpec";
pszFormat = "FF_Chat_AllSpec";
}
}
return pszFormat;
}
const char *CFF_SH_Rules::GetChatLocation( bool bTeamOnly, CBasePlayer *pPlayer )
{
// TODO:
return "FF LUA LOCATION HERE";
}
bool CFF_SH_Rules::IsSpawnPointValid( CBaseEntity *pSpot, CBasePlayer *pPlayer )
{
if ( !pSpot || pSpot->GetLocalOrigin() == vec3_origin )

View file

@ -136,6 +136,8 @@ public:
void ManageObjectRelocation( void );
void CheckChatForReadySignal( CFF_SH_Player *pPlayer, const char *chatmsg );
const char *GetChatFormat( bool bTeamOnly, CBasePlayer *pPlayer );
virtual const char *GetChatLocation( bool bTeamOnly, CBasePlayer *pPlayer );
bool IsSpawnPointValid( CBaseEntity *pSpot, CBasePlayer *pPlayer );
void AddTeam( const char *pTeamName, const int iNum );