mirror of
https://github.com/TES3MP/TES3MP.git
synced 2025-09-28 15:41:13 -04:00
Enchanting: fix inverted self-enchant success chance (Fixes #1701)
This commit is contained in:
parent
b370c0f7b5
commit
09607f992e
@ -62,7 +62,7 @@ namespace MWMechanics
|
||||
|
||||
if(mSelfEnchanting)
|
||||
{
|
||||
if(getEnchantChance()<std::rand()/static_cast<double> (RAND_MAX)*100)
|
||||
if(std::rand()/static_cast<double> (RAND_MAX)*100 < getEnchantChance())
|
||||
return false;
|
||||
|
||||
mEnchanter.getClass().skillUsageSucceeded (mEnchanter, ESM::Skill::Enchant, 2);
|
||||
|
Loading…
x
Reference in New Issue
Block a user