Jump to content

кιηg-αвα∂у

Members
  • Posts

    396
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

кιηg-αвα∂у's Achievements

Thug

Thug (25/54)

0

Reputation

  1. -- server addEvent("fix", true) addEventHandler("fix",root, function () local vehicle = getPedOccupiedVehicle ( source ) if vehicle then fixVehicle ( vehicle ) end end)
  2. local progress = guiCreateProgressBar( 0.8, 0.8, 0.1, 0.1, true) render = function() if guiProgressBarGetProgress(progress) >= 100 then outputChatBox("Welcome To The Server", 255, 0, 0) elseif guiProgressBarGetProgress(progress) < 100 then guiProgressBarSetProgress(progress,guiProgressBarGetProgress(progress)+1) end end addEventHandler('onClientResourceStart',root,function() setTimer( render, 1000, 10 ) end) اذا تبي تغير الحجم ولا المكان كذا element guiCreateProgressBar ( float x, float y, float width, float height, bool relative, [element parent = nil] )
  3. تسلم اخي ذا الانا كنت عايزو local progress = guiCreateProgressBar( 0.8, 0.8, 0.1, 0.1, true) render = function() if guiProgressBarGetProgress(progress) >= 100 then removeEventHandler('onClientRender',root,render) outputChatBox("Welcome To The Server", 255, 0, 0) end guiProgressBarSetProgress(progress,guiProgressBarGetProgress(progress)+1) end addEventHandler('onClientRender',root,render) بس في شغله ما فاهمها ممكن تساعدني طيب انت ماحددت تبي البروجرس يطلع اول مايدخل الاعب ولا متى ؟
  4. انت تبي واحد جاهز ولا تبي تعرف كيف تضبط الأسل ؟؟
  5. شوف هذا الموضوع viewtopic.php?f=160&t=87206
  6. Client Side Timer = setTimer( function() if not isTransferBoxActive() then setElementData(localPlayer,'DownloadFinish',true) if isTimer(Timer) then killTimer(Timer) end end end,1000,0) Server Side exports.scoreboard:addScoreboardColumn('tag') addEventHandler("onPlayerChat",root, function (msg,type) local name = getElementData(source,"tag") or getPlayerName(source) local acc = getAccountName(getPlayerAccount(source)) if ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("Console")) ) then cancelEvent() outputChatBox("[ Server Owner ] " .. name .. " : #ffffff" .. msg,root, math.random(0,255), math.random(0,255), math.random(0,255), true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("Admin")) ) then cancelEvent() outputChatBox("#ff0000* [ Admin ]" .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("Head.Admin")) ) then cancelEvent() outputChatBox("#ff0000* [ Head.Admin ]" .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("Big.Admin")) ) then cancelEvent() outputChatBox("#ff0000* [ Big.Admin ]" .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("SuperModerator")) ) then cancelEvent() outputChatBox("#00ff00* [ SuperModerator ] " .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("lvl 1")) ) then cancelEvent() outputChatBox("#330033* [ʟɛʋɛʟ.1] " .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("lvl 2")) ) then cancelEvent() outputChatBox("#7D1B7E* [ʟɛʋɛʟ.2] " .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("lvl 3")) ) then cancelEvent() outputChatBox("#827B60* [ʟɛʋɛʟ.3] " .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("lvl 4")) ) then cancelEvent() outputChatBox("#E78A61* [ʟɛʋɛʟ.4] " .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("lvl 5")) ) then cancelEvent() outputChatBox("#15317E* [ʟɛʋɛʟ.5] " .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("Moderator")) ) then cancelEvent() outputChatBox("#0069c7* [ Moderator ] " .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 and isObjectInACLGroup("user." .. acc,aclGetGroup("V.I.P")) ) then cancelEvent() outputChatBox("#999999* [ V.I.P ] " .. name .. " : #ffffff" .. msg,root,255,0,0,true) elseif ( type == 0 ) then if ( getElementData(source,'DownloadFinish') ) then cancelEvent() outputChatBox("" .. name .. " : #ffffff" .. msg,root,255,0,0,true) else cancelEvent() outputChatBox("* [ Downloader ] " .. name .. " : #ffffff" .. msg,root,255,0,0,true) end end end )
  7. "onPlayerTarget" -- اذا صوبت getElementHealth -- تجيب دم الاعب وتتحقق setPedAnimation -- يستسلم attachElements -- يلحقك createMarker -- تسوي ماركر setElementVisibleTo -- تخلي الي يشوف الماركر الخاطف والمخطوف "onMarkerHit" -- لما توقف على الماركر getElementAttachedTo -- تجيب المخطوف عن طريق الخاطف الي وقف على الماركر detachElements -- تفصله setElementPosition -- تحطه في مكان المخطوفين setAccountData -- تحط انه صاحب هذا الحساب مخطوف onPlayerJoin -- لما يدخل الاعب getAccountData -- يتحقق اذا كان مخطوف او لا spawnPlayer -- تحطه في مكان المخطوفين -- اذا تببي دفع المبلغ زر onClientGUIClick triggerServerEvent -- اذا تبيه زر من لوحة المفاتيح bindKey -- اذا تبيه كلمة في اف8 addCommandHandler getPlayerMoney -- تجيب فلوس الاعب تتحقق اذا يقدر يدفع ولآ takePlayerMoney -- تسحب الفلوس setAccountData -- تشيل الخطف من حسابه setElementPosition -- تنقله خارج مكان الخطف givePlayerMoney -- لتعطي الخاطف فلوس -- طبعاً تحدد الخاطف بداتا او الي تبي حاول وحنا بنساعدك
  8. "onPlayerTarget" -- اذا صوبت getElementHealth -- تجيب دم الاعب وتتحقق setPedAnimation -- يستسلم attachElements -- يلحقك createMarker -- تسوي ماركر setElementVisibleTo -- تخلي الي يشوف الماركر الخاطف والمخطوف "onMarkerHit" -- لما توقف على الماركر getElementAttachedTo -- تجيب المخطوف عن طريق الخاطف الي وقف على الماركر detachElements -- تفصله setElementPosition -- تحطه في مكان المخطوفين setAccountData -- تحط انه صاحب هذا الحساب مخطوف onPlayerJoin -- لما يدخل الاعب getAccountData -- يتحقق اذا كان مخطوف او لا spawnPlayer -- تحطه في مكان المخطوفين -- اذا تببي دفع المبلغ زر onClientGUIClick triggerServerEvent -- اذا تبيه زر من لوحة المفاتيح bindKey -- اذا تبيه كلمة في اف8 addCommandHandler getPlayerMoney -- تجيب فلوس الاعب تتحقق اذا يقدر يدفع ولآ takePlayerMoney -- تسحب الفلوس setAccountData -- تشيل الخطف من حسابه setElementPosition -- تنقله خارج مكان الخطف givePlayerMoney -- لتعطي الخاطف فلوس -- طبعاً تحدد الخاطف بداتا او الي تبي حاول وحنا بنساعدك
  9. local lights = { "High Quality", "Blue Doom", "Blue Estrellas", "Blue Flecha", "Blue Neon HQ", "Blue Oblique", "Blue X", "Colored", "Green FFS", "Green Mustang", "Green Onda", "Green Paradise", "Grey Audi I", "MEME Derp HQ", "MEME Me Gusta HQ", "MEME Troll HQ", "Orange Cupido", "Orange Led", "Orange Lines", "Pink Dots", "Purple I", "Purple II", "Red Alfa Romeo", "Red Alien", "Red Angry Mouth", "Red Angry Shape", "Red Audi I", "Red Audi II", "Red Audi III", "Red BMW I", "Red BMW II", "Red BMW M5", "Red Canibus", "Red Chevrolet Malibu", "Red Citroen Survolt", "Red Cupido", "Red Curve", "Red Curves HQ", "Red Dino", "Red Double Oval", "Red Double Ring", "Red Double Ring Led", "Red Double Rounded Restangles HQ", "Red Double Stripes", "Red Fast Line", "Red FFS", "Red Infiniti Electric", "Red KIA", "Red Lamborghini", "Red Lexus", "Red Lines", "Red Metropolis", "Red Mustang", "Red Passat", "Red Peugeot", "Red Rhombus", "Red Ring", "Red Sexy", "Red Slanted Stripes", "Red Spray", "Red Subaru", "Red The N", "Red The X", "Red The Y", "Red Triangles", "Red Triple Stripes", "Red Volkswagen", "Violet Lilac", "White Slanted Stripes", "White Snake" } local shaders = {} local currentLight = "high quality" local drawLights = true addEventHandler("onClientResourceStart",resourceRoot, function () currentLight = getCookieOption("lights") or "high quality" setElementData(localPlayer,"vehiclelight",currentLight,true) if getCookieOption("draw") ~= "false" then for i,vehicle in ipairs (getElementsByType("vehicle")) do loadVehicleLights(vehicle) end end end ) addEventHandler("onClientElementStreamIn",root, function () if getElementType(source) == "vehicle" then loadVehicleLights(source) end end ) addEventHandler("onClientVehicleEnter",root, function () loadVehicleLights(source) end ) function loadVehicleLights (vehicle) local controller = getVehicleController(vehicle) if not controller then return end local image = getElementData(controller,"vehiclelight") if not image then return end if not shaders[image] then local texture = dxCreateTexture("images/"..image..".jpg","dxt3") local shader = dxCreateShader("lights.fx") dxSetShaderValue(shader,"gTexture",texture) shaders[image] = shader end engineApplyShaderToWorldTexture(shaders[image],"vehiclelights128",vehicle) engineApplyShaderToWorldTexture(shaders[image],"vehiclelightson128",vehicle) -- needs messing with alpha end function unloadVehicleLights (vehicle) local controller = getVehicleController(vehicle) if not controller then return end local image = getElementData(controller,"vehiclelight") if not image then return end engineRemoveShaderFromWorldTexture(shaders[image],"vehiclelights128",vehicle) engineRemoveShaderFromWorldTexture(shaders[image],"vehiclelightson128",vehicle) end function saveChanges (btn) if btn ~= "left" then return end if guiCheckBoxGetSelected(drawlightsCheckBox) ~= drawLights then local drawlights = guiCheckBoxGetSelected(drawlightsCheckBox) if drawlights then for i,vehicle in ipairs (getElementsByType("vehicle")) do loadVehicleLights(vehicle) end else for i,vehicle in ipairs (getElementsByType("vehicle")) do unloadVehicleLights(vehicle) end for name,shader in pairs (shaders) do destroyElement(shader) shaders[name] = nil end end setCookieOption("draw",tostring(drawlights)) end local image = guiComboBoxGetItemText(lightsComboBox,guiComboBoxGetSelected(lightsComboBox)) if image ~= currentLight then currentLight = image setElementData(localPlayer,"vehiclelight",image) setCookieOption("lights",image) end guiSetVisible(lightsWindow,false) showCursor(false) end function closeWindow (btn) if btn ~= "left" then return end guiStaticImageLoadImage(previewStaticImage,"images/"..currentLight..".jpg") guiSetVisible(lightsWindow,false) showCursor(false) end function changeLights () local image = guiComboBoxGetItemText(lightsComboBox,guiComboBoxGetSelected(lightsComboBox)) guiStaticImageLoadImage(previewStaticImage,"images/"..image..".jpg") end addEventHandler("onClientElementDataChange",root, function (key,oldvalue) if key == "vehiclelight" then local vehicle = getPedOccupiedVehicle(source) if vehicle then loadVehicleLights(vehicle) end end end ) --GUI: function startGui () lightsWindow = guiCreateWindow (200, 70, 400, 450, "Vehicle Lights", false) guiSetAlpha (lightsWindow, 1) guiWindowSetSizable (lightsWindow, false) guiCreateLabel (15, 40, 380, 20, "Lights:", false, lightsWindow) guiCreateLabel (15, 140, 380, 20, "Preview:", false, lightsWindow) lightsComboBox = guiCreateComboBox (25, 60, 350, 160, "Default", false, lightsWindow) for i,light in ipairs (lights) do local id = guiComboBoxAddItem (lightsComboBox,light) if light == currentLight then guiComboBoxSetSelected(lightsComboBox,id) end end addEventHandler("onClientGUIComboBoxAccepted",lightsComboBox,changeLights) drawlightsCheckBox = guiCreateCheckBox (15, 90, 380, 20, "Draw lights", true, false, lightsWindow) previewStaticImage = guiCreateStaticImage (25, 160, 350, 220, "images/"..currentLight..".jpg", false, lightsWindow) local saveChangesButton = guiCreateButton (25, 400, 150, 30, "Save", false, lightsWindow) local closeWindowButton = guiCreateButton (225, 400, 150, 30, "Close", false, lightsWindow) addEventHandler("onClientGUIClick",saveChangesButton,saveChanges,false) addEventHandler("onClientGUIClick",closeWindowButton,closeWindow,false) end bindKey('F3','down', function () if lightsWindow then guiSetVisible(lightsWindow,not guiGetVisible(lightsWindow)) showCursor(guiGetVisible(lightsWindow)) else showCursor (true) startGui() end end)
  10. https://community.multitheftauto.com/ind ... ls&id=3032 https://community.multitheftauto.com/ind ... ls&id=4820
  11. مقدمة في البرمجة https://wiki.multitheftauto.com/wiki/Sc ... troduction باللغة العربية https://wiki.multitheftauto.com/wiki/Sc ... troduction
  12. تابل هو جرب على الكود الخطأ ماعطيته الكود بعد التعديل صاحب الموضوع جرب ذا time = {} function Countdown (player, cmd) if isTimer(time[player]) then return end time[player] = setTimer(function() time[player] = nil end,30000,1) local name = getPlayerName(player) local r,g,b = getPlayerNametagColor (player) local accountname = getAccountName (getPlayerAccount(player)) outputChatBox ( "" .. name .. ": #2600FF start countdown!!!", getRootElement(), r, g, b, true ) outputChatBox ( "#2600FF ===3===", getRootElement(), 255, 255, 255, true ) triggerClientEvent("triggerclientforGridCountdown", getRootElement()) setTimer ( Countdown5, 1000, 1 ) end function Countdown5 ( root ) outputChatBox ( "#2600FF ===2===", getRootElement(), 255, 255, 255, true ) setTimer ( Countdown4, 1000, 1 ) end function Countdown4 ( root ) outputChatBox ( "#2600FF ===1===", getRootElement(), 255, 255, 255, true ) setTimer ( Countdown3, 1000, 1 ) end function Countdown3 ( root ) outputChatBox ( "#2600FF Go Go Go!!!", getRootElement(), 255, 255, 255, true ) setTimer ( Countdown2, 1000, 1 ) end addCommandHandler( "countdown", Countdown )
  13. انا جربت كلآم البندر في اكثر من سيرفر جاني كيك وماتوقع احد بيحمي كل الحسابات اكيد حساب ادمن
×
×
  • Create New...