sourcemod/core/CPlayer.cpp
David Anderson 21fb4856e0 added license headers
--HG--
extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%40375
2007-01-25 22:36:38 +00:00

58 lines
1.2 KiB
C++

/**
* ===============================================================
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
* ===============================================================
*
* This file is not open source and may not be copied without explicit
* written permission of AlliedModders LLC. This file may not be redistributed
* in whole or significant part.
* For information, see LICENSE.txt or http://www.sourcemod.net/license.php
*
* Version: $Id$
*/
#include "CPlayer.h"
CPlayer::CPlayer()
{
m_IsConnected = false;
m_IsInGame = false;
m_IsAuthorized = false;
m_PlayerEdict = NULL;
}
void CPlayer::Initialize(const char *name, const char *ip, edict_t *pEntity)
{
m_IsConnected = true;
m_Name.assign(name);
m_Ip.assign(ip);
m_PlayerEdict = pEntity;
}
void CPlayer::Connect()
{
m_IsInGame = true;
}
void CPlayer::Authorize(const char *steamid)
{
m_IsAuthorized = true;
m_AuthID.assign(steamid);
}
void CPlayer::Disconnect()
{
m_IsConnected = false;
m_IsInGame = false;
m_IsAuthorized = false;
m_Name.clear();
m_Ip.clear();
m_AuthID.clear();
m_PlayerEdict = NULL;
}
void CPlayer::SetName(const char *name)
{
m_Name.assign(name);
}