48 lines
1.6 KiB
C++
48 lines
1.6 KiB
C++
/* *******************************************************************
|
|
* Includes
|
|
* ******************************************************************/
|
|
|
|
#include "Player.h"
|
|
#include <string.h>
|
|
|
|
/* *******************************************************************
|
|
* Defines
|
|
* ******************************************************************/
|
|
|
|
/* *******************************************************************
|
|
* Types definition
|
|
* ******************************************************************/
|
|
|
|
/* *******************************************************************
|
|
* Global variables definition
|
|
* ******************************************************************/
|
|
|
|
/* *******************************************************************
|
|
* Local variables definition
|
|
* ******************************************************************/
|
|
|
|
/* *******************************************************************
|
|
* Local prototypes declaration
|
|
* ******************************************************************/
|
|
|
|
/* *******************************************************************
|
|
* Functions definition
|
|
* ******************************************************************/
|
|
|
|
/*****************************************************************//**
|
|
*
|
|
* \brief Constructor for Player class.
|
|
*
|
|
*********************************************************************/
|
|
Player::Player(const char* const strPlayerName)
|
|
{
|
|
if (strPlayerName != NULL)
|
|
{
|
|
strncpy(_name, strPlayerName, MAX_NAME_LENGTH);
|
|
}
|
|
else
|
|
{
|
|
/* Undefined player name. */
|
|
}
|
|
}
|