function rainbowOutfit(cid, looktype, index)
local colors = {94, 77, 79, 82, 87, 90}
local creature = Creature(cid)
if not creature then
return
end
creature:setOutfit({
lookType = looktype,
lookHead = colors[((index) % 6) + 1],
lookBody = colors[((index + 1) % 6) + 1],
lookLegs = colors[((index + 2) % 6) + 1],
lookFeet = colors[((index + 3) % 6) + 1]
})
if index > 6 then
index = 0
end
addEvent(rainbowOutfit, 100, creature:getId(), looktype, index + 1)
end