MA[S]RIY Posted February 4, 2017 Share Posted February 4, 2017 السلام عليكم ابي كود انشاء صوره بصيغه gif علي الشاشه ؟؟ Link to comment
Abu-Solo Posted February 4, 2017 Share Posted February 4, 2017 (edited) 14 minutes ago, MARIY said: السلام عليكم ابي كود انشاء صوره بصيغه gif علي الشاشه ؟؟ شاشة اللعبة تقصد؟ Edited February 4, 2017 by Abu-Solo Link to comment
Jw8. Posted February 5, 2017 Share Posted February 5, 2017 gif = dxDrawGifImage ( 769, 175, 193, 145, "pns.gif", 0, "gif", 120 ) addCommandHandler ( "dg", function ( ) destroyElement ( gif ) end ) خذ جاهز Link to comment
Abu-Solo Posted February 5, 2017 Share Posted February 5, 2017 27 minutes ago, DmAr511 said: gif = dxDrawGifImage ( 769, 175, 193, 145, "pns.gif", 0, "gif", 120 )addCommandHandler ( "dg", function ( ) destroyElement ( gif ) end) خذ جاهز إرسله الرابط حق الويكي افضل لأن المثال هذا حق الويكي لو انك عطيته جاهز وشرحت كان افضل, Link to comment
N3xT Posted February 5, 2017 Share Posted February 5, 2017 46 minutes ago, DmAr511 said: gif = dxDrawGifImage ( 769, 175, 193, 145, "pns.gif", 0, "gif", 120 )addCommandHandler ( "dg", function ( ) destroyElement ( gif ) end) خذ جاهز وين اليوزفل فنكشن ؟ Link to comment
#BrosS Posted February 5, 2017 Share Posted February 5, 2017 ^ function dxDrawGifImage ( x, y, w, h, path, iStart, iType, effectSpeed ) local gifElement = createElement ( "dx-gif" ) if ( gifElement ) then setElementData ( gifElement, "gifData", { x = x, y = y, w = w, h = h, imgPath = path, startID = iStart, imgID = iStart, imgType = iType, speed = effectSpeed, tick = getTickCount ( ) }, false ) return gifElement else return false end end addEventHandler ( "onClientRender", root, function ( ) local currentTick = getTickCount ( ) for index, gif in ipairs ( getElementsByType ( "dx-gif" ) ) do local gifData = getElementData ( gif, "gifData" ) if ( gifData ) then if ( currentTick - gifData.tick >= gifData.speed ) then gifData.tick = currentTick gifData.imgID = ( gifData.imgID + 1 ) if ( fileExists ( gifData.imgPath .."".. gifData.imgID ..".".. gifData.imgType ) ) then gifData.imgID = gifData.imgID setElementData ( gif, "gifData", gifData, false ) else gifData.imgID = gifData.startID setElementData ( gif, "gifData", gifData, false ) end end dxDrawImage ( gifData.x, gifData.y, gifData.w, gifData.h, gifData.imgPath .."".. gifData.imgID ..".".. gifData.imgType ) end end end ) ذذ 1 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