mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-04-29 15:47:46 +00:00
style fix, not sure how that happened
This commit is contained in:
parent
9803a59673
commit
ce3473ae6d
2 changed files with 27 additions and 7 deletions
|
@ -191,7 +191,7 @@ uint16_t CalcStats::calculateMpCost( const Sapphire::Entity::Chara& chara, uint1
|
||||||
// each level range is 1-10, 11-20, 21-30, ... therefore:
|
// each level range is 1-10, 11-20, 21-30, ... therefore:
|
||||||
// level 50 should be in the 4th group, not the 5t
|
// level 50 should be in the 4th group, not the 5t
|
||||||
// dividing by 10 on the border will break this unless we subtract 1
|
// dividing by 10 on the border will break this unless we subtract 1
|
||||||
auto levelGroup = std::max< decltype( level ) >( level - 1, 1 ) / 10;
|
auto levelGroup = std::max< uint8_t >( level - 1, 1 ) / 10;
|
||||||
|
|
||||||
float cost = baseCost;
|
float cost = baseCost;
|
||||||
|
|
||||||
|
|
|
@ -16,10 +16,30 @@ namespace Sapphire::Math
|
||||||
|
|
||||||
static uint32_t calculateMaxHp( Sapphire::Entity::PlayerPtr pPlayer, FrameworkPtr pFw );
|
static uint32_t calculateMaxHp( Sapphire::Entity::PlayerPtr pPlayer, FrameworkPtr pFw );
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* @brief Calculates the MP cost of a spell given its base cost
|
||||||
|
* @param chara The Chara that is casting the action
|
||||||
|
* @param baseCost The action cost
|
||||||
|
* @return The total MP to be consumed by a successful cast
|
||||||
|
*/
|
||||||
static uint16_t calculateMpCost( const Sapphire::Entity::Chara& chara, uint16_t baseCost );
|
static uint16_t calculateMpCost( const Sapphire::Entity::Chara& chara, uint16_t baseCost );
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* @brief Calculates the probability of a block happening
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
static float pBlk( const Sapphire::Entity::Chara& );
|
static float pBlk( const Sapphire::Entity::Chara& );
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* @brief Calculates the probability of a direct hit happening
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
static float pDhr( const Sapphire::Entity::Chara& );
|
static float pDhr( const Sapphire::Entity::Chara& );
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* @brief Calculates the probability of a critical hit happening
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
static float pChr( const Sapphire::Entity::Chara& );
|
static float pChr( const Sapphire::Entity::Chara& );
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
Loading…
Add table
Reference in a new issue