local warmbear_announce = {
    get = {damp = nil, wet = nil, wetter = nil, soaked = nil,},
    weak = {
        damp = "No touch the water, I'm sick with that.",
        wet = "Feel so bad with these wetness.",
        wetter = "Ahhhh!!! I'm driving crazy!!!",
        soaked = "Lame life, I want to die now",
    },
    normal = {
        damp = "Yeah, a damp day.",
        wet = "Maybe latter I'll dry my fur.",
        wetter = "Where is the fire? Where is the shelter?",
        soaked = "So cold... I can't feel my belly.",
    },
    normal_plus = {
        damp = "Cool feeling~",
        wet = "Well, this does not make feel.",
        wetter = "Not that bad, I guess.",
        soaked = "Still under control.",
    },
    strong = {
        damp = "Fresh air!!",
        wet = "Wet? Bears not afraid of that.",
        wetter = "Aha!!! Look at my fur.",
        soaked = "Let's play with water!",
    },
}

local function AnnounceMoisture(self, oldSegs, newSegs)
    if not compatible.isdst or self.inst.components.talker then
        if self.inst.components.fat ~= nil then
            local fat = self.inst.components.fat:GetPercent()
            if fat < 0.15 then warmbear_announce.get = warmbear_announce.weak
            elseif fat < 0.5 then warmbear_announce.get = warmbear_announce.normal
            elseif fat < 0.8 then warmbear_announce.get = warmbear_announce.normal_plus
            else warmbear_announce.get = warmbear_announce.strong end
        end
        if oldSegs < 1 and newSegs >= 1 then
            self.inst.components.talker:Say(warmbear_announce.get.damp or GetString(self.inst, "ANNOUNCE_DAMP"))
        elseif oldSegs < 2 and newSegs >= 2 then
            self.inst.components.talker:Say(warmbear_announce.get.wet or GetString(self.inst, "ANNOUNCE_WET"))
        elseif oldSegs < 3 and newSegs >= 3 then
            self.inst.components.talker:Say(warmbear_announce.get.wetter or GetString(self.inst, "ANNOUNCE_WETTER"))
        elseif oldSegs < 4 and newSegs >= 4 then
            self.inst.components.talker:Say(warmbear_announce.get.soaked or GetString(self.inst, "ANNOUNCE_SOAKED"))
        end
    end
end

function fn(self)
    self.AnnounceMoisture = AnnounceMoisture
end

return fn
