summaryrefslogtreecommitdiffstats
path: root/src/Items/ItemHandler.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/Items/ItemHandler.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/Items/ItemHandler.cpp b/src/Items/ItemHandler.cpp
index d037092b1..8e3d79506 100644
--- a/src/Items/ItemHandler.cpp
+++ b/src/Items/ItemHandler.cpp
@@ -861,8 +861,7 @@ bool cItemHandler::EatItem(cPlayer * a_Player, cItem * a_Item)
float Chance;
if (Success && GetEatEffect(EffectType, EffectDurationTicks, EffectIntensity, Chance))
{
- cFastRandom r1;
- if (r1.NextFloat() < Chance)
+ if (GetRandomProvider().RandBool(Chance))
{
a_Player->AddEntityEffect(EffectType, EffectDurationTicks, EffectIntensity, Chance);
}