This site works best with JavaScript enabled. Please enable JavaScript to get the best experience from this site.
For the Issues with SetAlpha in the indicators.lua:
delete line 247 from indicators.lua, it reads "self.ready:SetAlpha(self.timeLeft / self.startTime)"
insert this instead at its position:
-- Fix for DF not liking values > 1 / < 0 local fadeAlpha = (self.timeLeft / self.startTime) if fadeAlpha < 0 then fadeAlpha = 0 elseif fadeAlpha > 1 then fadeAlpha = 1 end self.ready:SetAlpha(fadeAlpha)
----------------------------------------------
Delete original line 276 (should be at roughly line 286 after the change above), it reads "fadeFrame:SetAlpha(f.fadeList[fadeFrame] / FADEOUT_TIME)"
-- Fix for DF not liking values > 1 / < 0 local fadeAlpha = (f.fadeList[fadeFrame] / FADEOUT_TIME) if fadeAlpha < 0 then fadeAlpha = 0 elseif fadeAlpha > 1 then fadeAlpha = 1 end fadeFrame:SetAlpha(fadeAlpha)
This should help with the problems. Maybe just a bandaid for now but at least it assures same functionality as before.
You can fix this using min(max())
247:
self.ready:SetAlpha(min(max((self.timeLeft / self.startTime),0),1))
276:
fadeFrame:SetAlpha(min(max((f.fadeList[fadeFrame] / FADEOUT_TIME),0),1))
*edit: forgot a )
To post a comment, please login or register a new account.