Back to Home

ESO Lua File v101041

ingame/restyle/restyle_manager.lua

[◄ back to folders ]
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
local Restyle_Manager = ZO_CallbackObject:Subclass()
function Restyle_Manager:New(...)
    local singleton = ZO_CallbackObject.New(self)
    singleton:Initialize(...)
    return singleton
end
function Restyle_Manager:Initialize()
    local function CreateRestyleSlotData(objectPool)
        return ZO_RestyleSlotData:New()
    end
    local function ResetRestyleSlotData(restyleSlotData)
        restyleSlotData:SetRestyleMode(RESTYLE_MODE_NONE)
        restyleSlotData:SetRestyleSetIndex(ZO_RESTYLE_DEFAULT_SET_INDEX)
        restyleSlotData:SetRestyleSlotType(0)
    end
    self.restyleSlotDataPool = ZO_ObjectPool:New(CreateRestyleSlotData, ResetRestyleSlotData)
end
function Restyle_Manager:GetRestyleSlotDataMetaPool()
    return ZO_MetaPool:New(self.restyleSlotDataPool)
end
ZO_RESTYLE_MANAGER = Restyle_Manager:New()