Fixes dice being unable to roll their max value (#13845)

This commit is contained in:
adamsong
2023-02-01 12:27:05 -05:00
committed by GitHub
parent d2f2f48d7e
commit 8584cf5d95

View File

@@ -17,7 +17,7 @@ public sealed class DiceSystem : SharedDiceSystem
if (!Resolve(uid, ref die))
return;
var roll = _random.Next(1, die.Sides);
var roll = _random.Next(1, die.Sides + 1);
SetCurrentSide(uid, roll, die);
_popup.PopupEntity(Loc.GetString("dice-component-on-roll-land", ("die", uid), ("currentSide", die.CurrentValue)), uid);