diff --git a/modules/client_entergame/characterlist.lua b/modules/client_entergame/characterlist.lua index edc533aa..21eb3184 100644 --- a/modules/client_entergame/characterlist.lua +++ b/modules/client_entergame/characterlist.lua @@ -244,7 +244,7 @@ function CharacterList.hide() end function CharacterList.showAgain() - if characterList:hasChildren() then + if characterList and characterList:hasChildren() then CharacterList.show() end end diff --git a/modules/corelib/ui/uiscrollbar.lua b/modules/corelib/ui/uiscrollbar.lua index 88ca6457..519fbc87 100644 --- a/modules/corelib/ui/uiscrollbar.lua +++ b/modules/corelib/ui/uiscrollbar.lua @@ -168,7 +168,7 @@ function UIScrollBar:setValue(value) self.value = value updateSlider(self) if self.setupDone then - signalcall(self.onValueChange, self, value, delta) + signalcall(self.onValueChange, self, math.round(value), delta) end end @@ -203,6 +203,6 @@ end function UIScrollBar:getMaximum() return self.maximum end function UIScrollBar:getMinimum() return self.minimum end -function UIScrollBar:getValue() return self.value end +function UIScrollBar:getValue() return math.round(self.value) end function UIScrollBar:getStep() return self.step end function UIScrollBar:getOrientation() return self.orientation end diff --git a/modules/game_interface/gameinterface.lua b/modules/game_interface/gameinterface.lua index 15fdb375..083d5e12 100644 --- a/modules/game_interface/gameinterface.lua +++ b/modules/game_interface/gameinterface.lua @@ -487,7 +487,7 @@ function moveStackableItem(item, toPos) scrollbar.onValueChange = function(self, value) spinbox.onValueChange = nil - spinbox:setValue(math.round(value)) + spinbox:setValue(value) spinbox.onValueChange = spinBoxValueChange end