#UI Labs with Fusion

8 messages · Page 1 of 1 (latest)

teal dagger
#

try this

#

local Fusion = require(path.to.Fusion)

local New = Fusion.New
local Value = Fusion.Value
local Computed = Fusion.Computed

local story = {
fusion = Fusion,
story = function(props)
local scope = props.scope

    local color = Value(Color3.new(1, 0, 0)) -- Initial color (red)
    
    local component = New "Frame" {
        Parent = props.target,
        Size = UDim2.new(0, 200, 0, 200),
        BackgroundColor3 = Computed(function()
            return color:get() -- Use the reactive color value
        end)
    }

   
    task.delay(2, function()
        color:set(Color3.new(0, 1, 0)) -- Change to green
    end)

    return component
end

}

return story

#

tell me when it be working

#

if I don't try again

languid lava
#

eyyyy it worked

#

the problem was literally me forgetting to set the size of the frame...

#

thanks lol

#

now how do I mount it for every player?