/*this was an old attempt on making the animation stuff very compact that was left here for archiving i guess
i might come back to this in a distant 2.0.1 update, who knows

local flashColors = {
	skincolors[SKINCOLOR_COOLFLAMEWAVE],
	skincolors[SKINCOLOR_REPURPWAVE],
	skincolors[SKINCOLOR_RINGWAVE],
	skincolors[SKINCOLOR_PENCILWAVE],
	skincolors[SKINCOLOR_EGGWAVE],
	skincolors[SKINCOLOR_XBOXWAVE],
	skincolors[SKINCOLOR_PS2WAVE],
	skincolors[SKINCOLOR_WEEDWAVE],
	skincolors[SKINCOLOR_BRAKWAVE],
	skincolors[SKINCOLOR_SONIC2012WAVE]
}
local flashDelay = 5

local rampPos = 1
local rampDir = true
local ramps = {}

for curcol = 1, table.maxn(flashColors), 1
	ramps[curcol] = {{}}
	for i = 0, 15, 1
		ramps[curcol][1][i+1] = flashColors[curcol].ramp[i]
	end

	for i = 2, 16,1
		ramps[curcol][i] = {{}}

		for pos,val in ipairs(ramps[curcol][i-1]) do
			if not (pos == 16) then
				ramps[curcol][i][pos+1] = val
			else
				ramps[curcol][i][1] = val
			end
		end
	end
end

local function RampWave()
	if not (leveltime % flashDelay) then

		rampPos = $1+1
		
		if not (ramps[1][rampPos])
			rampPos = 1
		end
		
		for i = 1, table.maxn(ramps), 1
			flashColors[i].ramp = ramps[i][rampPos]
		end
	end
end

addHook("ThinkFrame", RampWave)

//alright, HERES the speed stuff

local enablespeedchange = true
local function speedChanger(player)
	for player in players.iterate
		if enablespeedchange == true
			if player.skincolor == SKINCOLOR_COOLFLAMEWAVE
				flashDelay = 1
			elseif player.skincolor == SKINCOLOR_RINGWAVE
				flashDelay = 3
			elseif player.skincolor == SKINCOLOR_REPURPWAVE
				flashDelay = 2
			elseif player.skincolor == SKINCOLOR_PENCILWAVE
				flashDelay = 4
			elseif player.skincolor == SKINCOLOR_EGGWAVE
				flashDelay = 2
			elseif player.skincolor == SKINCOLOR_XBOXWAVE
				flashDelay = 2
			elseif player.skincolor == SKINCOLOR_PS2WAVE
				flashDelay = 1
			elseif player.skincolor == SKINCOLOR_WEEDWAVE
				flashDelay = 3
			elseif player.skincolor == SKINCOLOR_BRAKWAVE
				flashDelay = 3
			elseif player.skincolor == SKINCOLOR_SONIC2012WAVE
				flashDelay = 5
			end
		end
	end
end

addHook("ThinkFrame", speedChanger)*/