Overkillz Posted February 28, 2016 Share Posted February 28, 2016 Hey guys, im trying to create a multiple alpha on each message, its the first time that I do this but it doesnt work, when the player type /adda message it will add the message and I want the alpha start too on each message for individual messages local sX, sY = guiGetScreenSize() local sizeX = sX/2 local sizeY = sY/2 local lista = {} local alpha = {} function dxDrawAnimation() for i=1,#lista do alpha[i] = alpha[i] + 30 if alpha[i] >= 255 then alpha[i] = 255 end dxDrawText("Text: "..lista[i],sX/2-sizeX/2,(sY/2-sizeY/2)+10*(i-1),0,0,tocolor(255,255,255,alpha[i]),1,"default-bold","left","top",false,false,false,true) end end addEventHandler("onClientRender",getRootElement(),dxDrawAnimation) function rellenateTable(value) table.insert(lista,value) end addCommandHandler("adda",rellenateTable) Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now