#pragma once /// \file /// \brief Header file that describes the handicap system. /// \author Lyberta /// \copyright GNU GPLv2 or any later version. // Handicap is used to make the game harder for strong players and easier for // weak players. Values greater than 1 make the game harder and values less than // 1 make the game easier. Right now handicap only affects damage. There are 2 // types of handicap: voluntary and forced. Voluntary handicap can be set via // cl_handicap cvar. For obvious reasons, it can't be less than 1. Forced // handicap can be set by server mutators. The total handicap is the product of // voluntary and forced handicap. /// \brief Initializes handicap to its default value. /// \param[in,out] player Player to initialize. /// \return No return. void Handicap_Initialize(entity player); /// \brief Returns the voluntary handicap of the player. /// \param[in] player Player to check. /// \return Voluntary handicap of the player. float Handicap_GetVoluntaryHandicap(entity player); /// \brief Returns the forced handicap of the player. /// \param[in] player Player to check. /// \return Forced handicap of the player. float Handicap_GetForcedHandicap(entity player); /// \brief Sets the forced handicap of the player. /// \param[in] player Player to alter. /// \param[in] value Handicap value to set. /// \return No return. void Handicap_SetForcedHandicap(entity player, float value); /// \brief Returns the total handicap of the player. /// \param[in] player Player to check. /// \return Total handicap of the player. float Handicap_GetTotalHandicap(entity player);