ROMCIS Posted September 24, 2020 Share Posted September 24, 2020 ابي كود يحرك صورة دي اكس يمين او يسار م عرفت اسويه 1 1 Link to comment
KhaledX Posted September 24, 2020 Share Posted September 24, 2020 (edited) local screenW, screenH = guiGetScreenSize() addEventHandler("onClientRender", root, function() dxDrawImage(screenW - 185 - 10, (screenH - 187) / 2, 185, 187, "YourLogo.png", math.random (6) , 0 , math.random (5), tocolor(255, 255, 255, 255), false) end ) Edited September 24, 2020 by KhaledX Link to comment
#\_oskar_/# Posted September 27, 2020 Share Posted September 27, 2020 local left = 10 -- تحقق مكان الوقوف بجهة اليسار local right = 400 -- تحقق مكان الوقوف بجهة اليمين local xpos = right -- احداثيات البدايه يسار او يمين انا مخليها تبدء من اليمين -- اليوزفل function DxDrawMove(i) if xpos < left then xpos = left elseif xpos > right then xpos = right end xpos = xpos+tonumber (i == 'left' and -3 or i == 'right' and 3 ) return xpos end -- اللوحه تتحرك يمين عند الضغط علي زر اف 3 function dx1() dxDrawImage(DxDrawMove('right'),250, 354, 270, "image.png", 0, 0, 0, tocolor(255, 255, 255, 255), true) end -- اللوحه تتحرك يسار عند الضغط علي زر اف 3 function dx2() dxDrawImage(DxDrawMove('left'),250, 354, 270, "image.png", 0, 0, 0, tocolor(255, 255, 255, 255), true) end -- فتح اللوحه bindKey("F2","down", function () if v then addEventHandler("onClientRender", root,dx1) removeEventHandler("onClientRender", root,dx2) else addEventHandler("onClientRender", root,dx2) removeEventHandler("onClientRender", root,dx1) end v = not v end ) جرب 1 Link to comment
ROMCIS Posted November 2, 2020 Author Share Posted November 2, 2020 يعطيكم العافية @KhaledX| @#\_oskar_/# 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