(da0d388a0) Fixed medical item usage occasionally failing even if the character has adequate skills to use it

This commit is contained in:
Joonas Rikkonen
2019-05-20 20:36:18 +03:00
parent 51c7c3c5e7
commit 42cf9d3368

View File

@@ -1641,7 +1641,7 @@ namespace Barotrauma
{
if (!ic.HasRequiredContainedItems(user == Character.Controlled)) continue;
bool success = Rand.Range(0.0f, 1.0f) < ic.DegreeOfSuccess(user);
bool success = Rand.Range(0.0f, 0.5f) < ic.DegreeOfSuccess(user);
ActionType actionType = success ? ActionType.OnUse : ActionType.OnFailure;
#if CLIENT