PostUnresolvedrainbow text

Posts 1–4 of 4 · Page 1 of 1
rainbow text
i want to know how to make rainbow text in lua for my client, kinda like SkidSchorcher. If anyone has code, or knows how to do this, please make a reply. Thanks!
its under ok.Visuals
Code:
ok.er = math.sin(CurTime() * 4) * 127 + 128
ok.eg = math.sin(CurTime() * 4 + 2) * 127 + 128
ok.eb = math.sin(CurTime() * 4 + 4) * 127 + 128

draw.SimpleText("SkidScorcher Public", "wireless gamer", 4, 40, Color(ok.er, ok.eg, ok.eb), TEXT_ALIGN_LEFT, TEXT_ALIGN_BOTTOM)
or this:
Code:
hook.Add("CreateMove","randomcolor", function()
randomcolor = Color(math.random(255), math.random(255), math.random(255))
end)

draw.SimpleText("Whatever", "BudgetLabel", 4, 40, randomcolor, TEXT_ALIGN_LEFT, TEXT_ALIGN_BOTTOM)
Code:
local function RainbowChat(mult, text)
    local tab = {}
    
    for i = 1, #tag do
        local col = HSVToColor(i * mult % 360, 1, 1)
        table.insert(tab, col)
        local letter = string.sub(text, i, i)
        table.insert(tab, letter)
    end
    
    chat.AddText(unpack(tab))
end


Usage:
 RainbowChat(5, "I'm a fag!")
Credits to MPan1
Been over a week since last update/bump after answers.

/Closed.
Posts 1–4 of 4 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Talk with us