Logo Search packages:      
Sourcecode: mathwar version File versions  Download package

player_type get_type_of_player ( const player_object player  ) 

Return the type of player for the given player object.

get_type_of_player (const player_object *player)

Parameters:
player The player in question.
Returns:
The type of player for the player object.

Definition at line 126 of file player.c.

References COMPUTER, and HUMAN.

{
   g_return_val_if_fail (player != NULL, HUMAN);
   g_return_val_if_fail (player->name != NULL, HUMAN);
   g_return_val_if_fail 
      (player->type == HUMAN || player->type == COMPUTER, HUMAN);

   return player->type;
} 


Generated by  Doxygen 1.6.0   Back to index