Fixes
This commit is contained in:
parent
39b273ad1c
commit
e17370a89f
4 changed files with 23 additions and 10 deletions
13
Roll.lua
13
Roll.lua
|
|
@ -31,6 +31,19 @@ end)
|
|||
|
||||
-- Calculate the final result based on the roll type and selected modifiers
|
||||
function AltSystem:CalculateAndDisplayResult(rollType, rollValue)
|
||||
-- Critical rolls bypass normal calculation
|
||||
if rollValue == 1 then
|
||||
if AltSystem.ResultText then
|
||||
AltSystem.ResultText:SetText("|cffff0000Critical Failure|r")
|
||||
end
|
||||
return
|
||||
elseif rollValue == 20 then
|
||||
if AltSystem.ResultText then
|
||||
AltSystem.ResultText:SetText("|cff00ff00Critical Success|r")
|
||||
end
|
||||
return
|
||||
end
|
||||
|
||||
local state = AltSystem.State
|
||||
local skill = AltSystem.Data.Skills[state.selectedSkillIndex]
|
||||
local item = AltSystem.Data.Items[state.selectedItemIndex]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue