Jw8. Posted June 19, 2019 Share Posted June 19, 2019 سلآم عليكم يعيال ابغى اسئلكم كيف اسوي للصوره ذي حركة ؟ dxDrawImage(screenW * 0.0000, screenH * -0.0117, screenW * 1.0000, screenH * 0.9950, "img/bb.png", 0, 0, 0, tocolor(136, 22, 232, 255), false) جربت اسويلها ما عرفت :] وحاولت بذي interpolateBetween ابغى اعملها لما تفتح الوحة يجي من هنا <-- Link to comment
SycroX Posted June 19, 2019 Share Posted June 19, 2019 On 19/06/2019 at 16:49, DmAr511 said: سلآم عليكم يعيال ابغى اسئلكم كيف اسوي للصوره ذي حركة ؟ dxDrawImage(screenW * 0.0000, screenH * -0.0117, screenW * 1.0000, screenH * 0.9950, "img/bb.png", 0, 0, 0, tocolor(136, 22, 232, 255), false) جربت اسويلها ما عرفت :] وحاولت بذي interpolateBetween ابغى اعملها لما تفتح الوحة يجي من هنا <-- Expand ورينا محاولتك Link to comment
Jw8. Posted June 19, 2019 Author Share Posted June 19, 2019 On 19/06/2019 at 17:36, #x1AhMeD-09 said: ورينا محاولتك Expand يهوو صلني ساعه وانا احاول :] Link to comment
SycroX Posted June 19, 2019 Share Posted June 19, 2019 (edited) On 19/06/2019 at 17:36, DmAr511 said: يهوو صلني ساعه وانا احاول :] Expand تمام ورينا المحاوله عشان نصلحها لك Edited June 19, 2019 by #x1AhMeD-09 Link to comment
Jw8. Posted June 19, 2019 Author Share Posted June 19, 2019 On 19/06/2019 at 17:36, #x1AhMeD-09 said: ورينا محاولتك Expand ثواني لاني مسحتها اول شي حاولت بذي ماظبطت خخ اكيد تخبيص local now = getTickCount() local endTime = start + 2000 local elapsedTime = now - start local duration = endTime - start local progress = elapsedTime / duration local px, py, pz = getElementPosition(localPlayer) local x, y, z = interpolateBetween ( dx, dy, dz, dx+4, dy+4, dz, progress, "OutQuad") dxDrawImage(dx, dy, dz, dx+4, "img/bb.png", 0, 0, 0, tocolor(136, 22, 232, 255), false) Link to comment
#BrosS Posted June 19, 2019 Share Posted June 19, 2019 (edited) tick = getTickCount() function Draw() local x, y, z = interpolateBetween ( dx, dy, dz, dx+4, dy+4, dz, (getTickCount()-tick)/1400, "OutQuad") dxDrawImage(x, y, z, dx+4, "img/bb.png", 0, 0, 0, tocolor(136, 22, 232, 255), false) end addCommandHandler( "show", function() --... tick = getTickCount() addEventHandler("onClientRender",root,Draw) --... end ); Edited June 19, 2019 by #BrosS Link to comment
Jw8. Posted June 19, 2019 Author Share Posted June 19, 2019 On 19/06/2019 at 18:51, #BrosS said: tick = getTickCount() function Draw() local x, y, z = interpolateBetween ( dx, dy, dz, dx+4, dy+4, dz, (getTickCount()-tick)/1400, "OutQuad") dxDrawImage(x, y, z, dx+4, "img/bb.png", 0, 0, 0, tocolor(136, 22, 232, 255), false) end addCommandHandler( "show", function() --... tick = getTickCount() --... end ); Expand ماظبط Link to comment
#BrosS Posted June 19, 2019 Share Posted June 19, 2019 نسيت أضيف الحدث لول عدلتها + هذا مثال فقط انت وين استخدمتها Link to comment
Jw8. Posted June 19, 2019 Author Share Posted June 19, 2019 On 19/06/2019 at 18:59, #BrosS said: نسيت أضيف الحدث لول عدلتها + هذا مثال فقط انت وين استخدمتها Expand local x, y, z = interpolateBetween ( dx, dy, dz, dx+4, dy+4, dz, (getTickCount()-tick)/1400, "OutQuad") dxDrawImage(screenW * 0.0000, screenH * -0.0117, screenW * 1.0000, dx+4, "img/bb.png", 0, 0, 0, tocolor(136, 22, 232, 255), false) Link to comment
#BrosS Posted June 19, 2019 Share Posted June 19, 2019 On 19/06/2019 at 19:00, DmAr511 said: x, y, z Expand وظفهم يا اخي Link to comment
Jw8. Posted June 19, 2019 Author Share Posted June 19, 2019 local x, y, z = interpolateBetween ( dx, dy, dz, dx+4, dy+4, dz, (getTickCount()-tick)/1400, "OutQuad") dxDrawImage(x, y, z, dx+4, "img/bb.png", 0, 0, 0, tocolor(136, 22, 232, 255), false) Link to comment
Jw8. Posted June 19, 2019 Author Share Posted June 19, 2019 On 19/06/2019 at 19:04, #BrosS said: هيه جربه Expand يقلي المشكله بذه السطر : local x, y, z = interpolateBetween ( dx, dy, dz, dx+4, dy+4, dz, (getTickCount()-tick)/1400, "OutQuad") Link to comment
Jw8. Posted June 19, 2019 Author Share Posted June 19, 2019 On 19/06/2019 at 19:07, #BrosS said: dx, dy, dz تأكد أنك معرف Expand On 19/06/2019 at 19:07, #BrosS said: dx, dy, dz تأكد أنك معرف Expand بوش اعرفهم بـ setElementPosition ؟ Link to comment
#BrosS Posted June 19, 2019 Share Posted June 19, 2019 local aX, aY = interpolateBetween ( screenW * 0.0000, screenH * -0.0117, 0, screenW * 0.0000, screenH * 0.5117, 0, (getTickCount()-tick)/1400, "OutQuad") dxDrawImage(aX, aY, screenW * 1.0000, dx+4, "img/bb.png", 0, 0, 0, tocolor(136, 22, 232, 255), false) dx+4 اذا جاك خطأ ب هذي انت حطيتها وغيرها بالإحداثية الاصلية هيك اتوقع الصورة تجي من فوق وتنزل Link to comment
N3xT Posted June 19, 2019 Share Posted June 19, 2019 (edited) local sX, sY = guiGetScreenSize ( ) function Draw ( ) local animation = interpolateBetween ( sX + 50, 0, 0, ( sX / 2 ) - ( 50 / 2 ), 0, 0, ( getTickCount() - ( tick or 0 ) ) / 1000, "Linear" ) dxDrawImage ( animation, ( sY / 2 ) - ( 50 / 2 ), 50, 50, "img/bb.png", 0, 0, 0, tocolor ( 136, 22, 232, 255 ), false ) end addCommandHandler ( "show", function ( ) tick = getTickCount() addEventHandler ( "onClientRender", root, Draw ) end ) راح يجيب لك الصورة من اليمين الى نص الشاشة, الكود ناقص تحققات لكن المهم ايصال الفكرة Edited June 19, 2019 by N3xT 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