UIS.InputBegan:Connect(function(input) if input.KeyCode == Enum.KeyCode.Z then while wait(1) do Backdrop1.BackgroundColor3 = Color3.new(1, 0, 0) Backdrop1.BackgroundColor3 = Color3.new(0, 1, 0) Backdrop1.BackgroundColor3 = Color3.new(0, 0, 1) end end end)
You don't have a wait between the changing of color, so it just jumps directly to the last color you set the backgroundcolor to be, in this case Color3.new(0,0,1). Simply add a wait() between each line where you change the backgroundcolor.