Jump to content

Nickelz

Members
  • Posts

    239
  • Joined

  • Last visited

Everything posted by Nickelz

  1. نسيت احط التحقق حق الصوت , بس الكود حقي يخليك تحط السرعة اللي تبيها , مو شرط 0 أو 50 أو 100
  2. -- #Client function soundSpeed( ) local Scroll = guiScrollBarGetScrollPosition(Scroll) local Speed = Scroll / 100 setSoundSpeed(SoundURL, Speed) end addEventHandler("onClientGUIScroll", getRootElement(), soundSpeed)
  3. طيب بـ أخلاق ... guiSetAlpha(getControl(wndMain, 'kill'), 0.7)
  4. الالفا من صفر الى واحد مو واحد او صفر guiSetAlpha(btn, 0) -- مخفي guiSetAlpha(btn, 1) -- ظاهر
  5. عندك أخطاء في الكود, عدلتها كلها GUIEditor = { button = {}, window = {} } addEventHandler("onClientResourceStart", resourceRoot, function() GUIEditor.window[1] = guiCreateWindow(441, 128, 622, 484, "BY IIwantedII", false) guiWindowSetSizable(GUIEditor.window[1], false) guiSetVisible(GUIEditor.window[1], false) GUIEditor.button[1] = guiCreateButton(20, 43, 592, 80, "RAIN", false, GUIEditor.window[1]) guiSetFont(GUIEditor.button[1], "clear-normal") guiSetProperty(GUIEditor.button[1], "NormalTextColour", "FF0929F0") GUIEditor.button[2] = guiCreateButton(9, 161, 603, 92, "FOG", false, GUIEditor.window[1]) guiSetProperty(GUIEditor.button[2], "NormalTextColour", "FF0633F5") GUIEditor.button[3] = guiCreateButton(10, 269, 602, 92, "SUNNY", false, GUIEditor.window[1]) guiSetProperty(GUIEditor.button[3], "NormalTextColour", "FFF2F505") GUIEditor.button[4] = guiCreateButton(22, 384, 590, 90, "DUST", false, GUIEditor.window[1]) guiSetProperty(GUIEditor.button[4], "NormalTextColour", "FF0929F0") end ) function OpenWin() if guiGetVisible(GUIEditor.window[1]) then guiSetVisible(GUIEditor.window[1], false) showCursor(false) else guiSetVisible(GUIEditor.window[1], true) showCursor(true) end end bindKey("F2", "down", OpenWin) addEventHandler ("onClientGUIClick", getRootElement(), function () if ( source == GUIEditor.button[2] ) then setWeather ( 9 ) outputChatBox("WEATHER CHANGED TO FOGGY !!!") end end )
  6. guiSetAlpha(guiElement, alpha) -- guiElement = اسم الزر أو اللوحة -- alpha = 0 OR 1
  7. Nickelz

    dx زر

    Use this function : function isMouseInPosition(x, y, width, height) if ( not isCursorShowing( ) ) then return false end local sx, sy = guiGetScreenSize( ) local cx, cy = getCursorPosition( ) local cx, cy = ( cx * sx ), ( cy * sy ) if ( cx >= x and cx <= x + width ) and ( cy >= y and cy <= y + height ) then return true else return false end end local x, y, w, h = 1021, 21, 27, 24 dxDrawRectangle(x, y, w, h, tocolor(0, 0, 0, 200), true) -- Create DX button dxDrawText("X", 1021, 21, 1048, 45, tocolor(255, 255, 255, 255), 1.00, "pricedown", "center", "center", false, false, true, false, false) -- Create DX text addEventHandler ( "onClientClick", root, -- Event function (_, state ) -- Function if ( state == "down" ) then -- If ( the state of the button was down ) then if ( isMouseInPosition(x, y, w, h) ) then -- If ( your mouse is in the correct postion ) then -- Functions end -- End if end -- End if end -- End function )
  8. addEventHandler("onClientResourceStart",root ,function() local x,y = guiGetScreenSize() img = guiCreateStaticImage(x/2-300, y/2-300,650,600, "img.png", false) setTimer (guiSetVisible,100000,1,img,false) end)
  9. setCameraTarget( getLocalPlayer() ) --Client
  10. DX اذا تبي للـ استخدم طريقتي, مجربة
  11. الطريقة اللي دايم استخدمها, احسن طريقة بـ النسبة لي sX, sY = guiGetScreenSize() function() wnd = guiCreateWindow( (sX/1366)*483, (sY/768)*330, (sX/1366)*423, (sY/768)*117, "", false ) end --1366, 768 = مقاس شاشتك -- 1366x768
  12. حاول تقرا اكواد كثيير وتفهم منها طريقة استخدام الفنكشنات وترتيب الكود Client Functions Client Events Server Functions Server Events
  13. https://wiki.multitheftauto.com/wiki/AR/ ... 8%AC%D9%87
  14. addEventHandler('onPlayerQuit',root, function() local vAcc = getPlayerAccount(source) if not vAcc or isGuestAccount(vAcc) then return end setAccountData( vAcc,'WeaponID0',getPedWeapon( source, 0) ) -- 0 = Weapon ID setAccountData (account, "TotalAmmo0", getPedTotalAmmo ( source, 0 ) ) -- 0 = Weapon ID end ) addEventHandler('onPlayerLogin',root, function(_,acc) local Weapon = getAccountData(acc,'WeaponID0') local Ammo = getAccountData(acc,'TotalAmmo0') if ( Weapon ) then giveWeapon(source, Weapon, Ammo) end end )
  15. لانك تروح عالم 5 ولا ترجع 0 ..
  16. --#Server addEvent ( "warp", true ) addEventHandler ( "warp", root, function ( ) if not ( getElementInterior( source ) == 5 ) then setElementInterior ( source, 5, 1302.2878417969, -789.06280517578, 1083.9079589844 ) else setElementInterior( source, 0 ) end end )
  17. متأكد من الاحداثيات؟
  18. --#Client addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == okbu ) then if ( guiGetText ( PassEdit ) == "00" ) then triggerServerEvent ( "warp", localPlayer ) outputChatBox ("#0082D7Welcome My Love",255,255,255, true) guiSetVisible(PassWin, false ) showCursor( false ) else outputChatBox ( "#0082D7Worng Password Bitch", 255, 0, 0, true ) end end end ) --#Server addEvent ( "warp", true ) addEventHandler ( "warp", root, function ( ) setElementInterior ( source, 5, 1302.2878417969, -789.06280517578, 1083.9079589844 ) end )
  19. صراحة انا تعلمت البرمجة بدون انجليزي, لانك ما تحتاجها كثير واعرف مبرمجين محترفين الانجليزي عندهم معدوم
  20. https://wiki.multitheftauto.com/wiki/IsSoundFinished
  21. ورربي انكك شنب لبى قلبك , تم حل المشكلة يغلق
  22. هذا اخر شي حطيته, ومايشتغل function sets() gText = guiGetText(GUIEditor.edit[1]) if gText ~= "" then for i, player in ipairs (getElementsByType ("player")) do local Name = string.gsub(getPlayerName(player),"#%x%x%x%x%x%x","") local Row = guiGridListAddRow (GUIEditor.gridlist[1]) guiGridListSetItemText(GUIEditor.gridlist[1],Row,1,Name,false,false) guiGridListSetItemText(GUIEditor.gridlist[1],Row,2,tostring(gText),false,false) end end end addEventHandler( "onClientGUIClick", root, sets)
×
×
  • Create New...