-
Notifications
You must be signed in to change notification settings - Fork 1
builtin buff
boyism80 edited this page Jun 19, 2025
·
3 revisions
This document describes functions available to buff type objects.
-
Description:
Returns the spell model (fb.model.spell) object that this buff object references. -
Parameters:
- None
-
Return Value:
-
fb.model.spell: Spell model object
-
-
Example:
-- This is a real usage example from game scripts for _, buff in pairs(you:buffs()) do local spell_model = buff:model() me:message("Removing buff: " .. spell_model:name()) you:unbuff(buff) end
Provides two functionalities to get or set the remaining duration of the buff.
-
Description:
Returns the remaining duration of the buff in seconds. -
Parameters:
- None
-
Return Value:
-
number: Remaining duration in seconds
-
-
Example:
-- This is a real usage example from game scripts local remaining = buff:time() me:message("Buff remaining: " .. remaining .. " seconds")
-
Description:
Sets the buff's remaining duration to the specified number of seconds. -
Parameters:
-
value:number: Duration in seconds to set
-
-
Return Value:
- None
-
Example:
-- This is a real usage example from game scripts buff:time(300) -- Set to 5 minutes me:message("Buff duration extended")