ff_i_player

Player functions.

Helpers that operate on the player connection rather than the PC creature: camera, UI, client data, and boot utilities.

int GetPlayerCount()

Return the number of players.

Source code

// @code


// -----------------------------------------------------------------------------

//! @brief Return the number of players
int GetPlayerCount();
int GetPlayerCount()
{
  int nCount = 0;

  object oPC = GetFirstPC();
  while (GetIsObjectValid(oPC))
  {
    nCount += 1;
    oPC = GetNextPC();
  }
  return nCount;
}