BonSay~^ Posted January 29, 2016 Share Posted January 29, 2016 Pessoal estou criando uma radio online e quero fazer uma imagem roda e fazer o efeito de batida eu tentei uma coisa mas ficou esquesito nao ficou parado fica saindo do lugar Client girar = 0 function renderDisplay () local ls,rs = getSoundLevelData(musica) if(ls ~= false) then dxDrawImage(530, 718, 42*(ls/25000), 42*(ls/25000), "som.png", girar, 0, 0, tocolor(255, 255, 255, 255), true) dxDrawImage(810, 718, 42*(ls/25000), 42*(ls/25000), "som.png", girar, 0, 0, tocolor(255, 255, 255, 255), true) girar = girar + 7 end end Link to comment
MrDante Posted February 2, 2016 Share Posted February 2, 2016 tente isso: function renderDisplay () local ls,rs = getSoundLevelData(musica) if(ls ~= false) then dxDrawImage(530, 718, 42*(ls/25000), 42*(ls/25000), "som.png", getTickCount() / 30% 360) -- 30% Valor do tempo girando e 360 girando em 360 graus dxDrawImage(810, 718, 42*(ls/25000), 42*(ls/25000), "som.png", getTickCount() / 30% 360) end end Link to comment
#RooTs Posted February 2, 2016 Share Posted February 2, 2016 girar = getTickCount() / 30% 360 function renderDisplay () local ls,rs = getSoundLevelData(musica) if(ls ~= false) then dxDrawImage(530, 718, 42*(ls/25000), 42*(ls/25000), "som.png", girar, 0, 0, tocolor(255, 255, 255, 255), true) dxDrawImage(810, 718, 42*(ls/25000), 42*(ls/25000), "som.png", girar, 0, 0, tocolor(255, 255, 255, 255), true) end end assim também deve funcionar 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