 local function onmax(self,max) self.inst.fury_max:set(max) end local function oncurrent(self,current) self.inst.fury_current:set(current) end local function onrage(self,rage) self.inst.fury_rage:set(rage) end  local fury = Class(function(self, inst) self.inst = inst self.maxtimepiont = 100 self.currenttimepiont = 0 self.ragepoint = 1 end, nil, { maxtimepiont = onmax, currenttimepiont = oncurrent, ragepoint = onrage, })  function fury:DoDelta(delta)  local val = self.currenttimepiont + delta if val >= self.maxtimepiont then self.currenttimepiont = self.maxtimepiont elseif val <= 0 then self.currenttimepiont = 0 else self.currenttimepiont = val end end  function fury:GetPercent() return self.currenttimepiont/self.maxtimepiont end  function fury:SetRage(val) self.ragepoint = val end   function fury:OnSave() return  { currenttimepiont = self.currenttimepiont, maxtimepiont = self.maxtimepiont, } end function fury:OnLoad(data)     self.currenttimepiont = data.currenttimepiont     self.maxtimepiont = data.maxtimepiont end  return fury