2017-06-20 04:24:15 +00:00
|
|
|
#ifndef OPENMW_SETTINGSAPI_HPP
|
|
|
|
#define OPENMW_SETTINGSAPI_HPP
|
|
|
|
|
2019-01-15 12:26:11 +00:00
|
|
|
#include "../api.h"
|
2019-01-15 11:41:58 +00:00
|
|
|
|
2019-01-15 12:26:11 +00:00
|
|
|
NAMESPACE_BEGIN(SettingFunctions)
|
2017-11-27 05:39:02 +00:00
|
|
|
/**
|
|
|
|
* \brief Set the difficulty for a player.
|
|
|
|
*
|
|
|
|
* This changes the difficulty for that player in the server memory, but does not by itself
|
|
|
|
* send a packet.
|
|
|
|
*
|
|
|
|
* \param pid The player ID.
|
2018-04-09 16:24:24 +00:00
|
|
|
* \param difficulty The difficulty.
|
2017-11-27 05:39:02 +00:00
|
|
|
* \return void
|
|
|
|
*/
|
2019-01-16 15:52:22 +00:00
|
|
|
API_FUNCTION void CDECL SetDifficulty(PlayerId pid, int difficulty);
|
2017-11-27 05:39:02 +00:00
|
|
|
|
2018-03-11 02:50:59 +00:00
|
|
|
/**
|
|
|
|
* \brief Set the client log level enforced for a player.
|
|
|
|
*
|
|
|
|
* This changes the enforced log level for that player in the server memory, but does not by itself
|
|
|
|
* send a packet.
|
|
|
|
*
|
|
|
|
* Enforcing a certain log level is necessary to prevent players from learning information from
|
|
|
|
* their console window that they are otherwise unable to obtain, such as the locations of
|
|
|
|
* other players.
|
|
|
|
*
|
|
|
|
* If you do not wish to enforce a log level, simply set enforcedLogLevel to -1
|
|
|
|
*
|
|
|
|
* \param pid The player ID.
|
2018-04-09 16:24:24 +00:00
|
|
|
* \param enforcedLogLevel The enforced log level.
|
2018-03-11 02:50:59 +00:00
|
|
|
* \return void
|
|
|
|
*/
|
2019-01-16 15:52:22 +00:00
|
|
|
API_FUNCTION void CDECL SetEnforcedLogLevel(PlayerId pid, int enforcedLogLevel);
|
2018-03-11 02:50:59 +00:00
|
|
|
|
2018-02-14 03:53:44 +00:00
|
|
|
/**
|
|
|
|
* \brief Set the physics framerate for a player.
|
|
|
|
*
|
|
|
|
* This changes the physics framerate for that player in the server memory, but does not by itself
|
|
|
|
* send a packet.
|
|
|
|
*
|
|
|
|
* \param pid The player ID.
|
2018-04-09 16:24:24 +00:00
|
|
|
* \param physicsFramerate The physics framerate.
|
2018-02-14 03:53:44 +00:00
|
|
|
* \return void
|
|
|
|
*/
|
2019-01-16 15:52:22 +00:00
|
|
|
API_FUNCTION void CDECL SetPhysicsFramerate(PlayerId pid, double physicsFramerate);
|
2018-02-14 03:53:44 +00:00
|
|
|
|
2017-07-19 17:40:51 +00:00
|
|
|
/**
|
|
|
|
* \brief Set whether the console is allowed for a player.
|
|
|
|
*
|
|
|
|
* This changes the console permission for that player in the server memory, but does not
|
|
|
|
* by itself send a packet.
|
|
|
|
*
|
2017-07-25 15:07:09 +00:00
|
|
|
* \param pid The player ID.
|
2018-04-09 16:24:24 +00:00
|
|
|
* \param state The console permission state.
|
2017-07-19 17:40:51 +00:00
|
|
|
* \return void
|
|
|
|
*/
|
2019-01-16 15:52:22 +00:00
|
|
|
API_FUNCTION void CDECL SetConsoleAllowed(PlayerId pid, bool state);
|
2017-07-19 17:40:51 +00:00
|
|
|
|
|
|
|
/**
|
2017-11-30 10:18:15 +00:00
|
|
|
* \brief Set whether resting in beds is allowed for a player.
|
2017-07-19 17:40:51 +00:00
|
|
|
*
|
2017-11-27 05:39:02 +00:00
|
|
|
* This changes the resting permission for that player in the server memory, but does not
|
|
|
|
* by itself send a packet.
|
2017-07-19 17:40:51 +00:00
|
|
|
*
|
2017-07-25 15:07:09 +00:00
|
|
|
* \param pid The player ID.
|
2018-04-09 16:24:24 +00:00
|
|
|
* \param state The resting permission state.
|
2017-07-19 17:40:51 +00:00
|
|
|
* \return void
|
|
|
|
*/
|
2019-01-16 15:52:22 +00:00
|
|
|
API_FUNCTION void CDECL SetBedRestAllowed(PlayerId pid, bool state);
|
2017-11-30 10:18:15 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* \brief Set whether resting in the wilderness is allowed for a player.
|
|
|
|
*
|
|
|
|
* This changes the resting permission for that player in the server memory, but does not
|
|
|
|
* by itself send a packet.
|
|
|
|
*
|
|
|
|
* \param pid The player ID.
|
2018-04-09 16:24:24 +00:00
|
|
|
* \param state The resting permission state.
|
2017-11-30 10:18:15 +00:00
|
|
|
* \return void
|
|
|
|
*/
|
2019-01-16 15:52:22 +00:00
|
|
|
API_FUNCTION void CDECL SetWildernessRestAllowed(PlayerId pid, bool state);
|
2017-11-27 05:39:02 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* \brief Set whether waiting is allowed for a player.
|
|
|
|
*
|
|
|
|
* This changes the waiting permission for that player in the server memory, but does not
|
|
|
|
* by itself send a packet.
|
|
|
|
*
|
|
|
|
* \param pid The player ID.
|
2018-04-09 16:24:24 +00:00
|
|
|
* \param state The waiting permission state.
|
2017-11-27 05:39:02 +00:00
|
|
|
* \return void
|
|
|
|
*/
|
2019-01-16 15:52:22 +00:00
|
|
|
API_FUNCTION void CDECL SetWaitAllowed(PlayerId pid, bool state);
|
2017-06-20 04:24:15 +00:00
|
|
|
|
2017-07-19 17:40:51 +00:00
|
|
|
/**
|
|
|
|
* \brief Send a PlayerSettings packet to the player affected by it.
|
|
|
|
*
|
|
|
|
* \param pid The player ID to send it to.
|
|
|
|
* \return void
|
|
|
|
*/
|
2019-01-16 15:52:22 +00:00
|
|
|
API_FUNCTION void CDECL SendSettings(PlayerId pid) NOEXCEPT;
|
2019-01-15 12:26:11 +00:00
|
|
|
NAMESPACE_END()
|
2017-06-20 04:24:15 +00:00
|
|
|
|
|
|
|
#endif //OPENMW_SETTINGSAPI_HPP
|