Jump to content

KING-_-HOHO

Members
  • Posts

    211
  • Joined

  • Last visited

Everything posted by KING-_-HOHO

  1. لا لاني انا عنددي مود نفس الي فوق اللي هي كذا exports.killmessages:outputMessage شفت كودك استغربت ض١
  2. اتوقع كذا تمام exports.killmessages:outputMessage("#FF6464[shop] #00FF00"..name .." Has Bought #FF0000( Health )", source, 255, 255, 0, true) او احذف : اللي بعد killmessages
  3. اها قول حق الحدث function hideLoginWindow() guiSetInputEnabled(false) guiSetVisible(mainWindow, false) guiSetVisible(registerWindow, false) showforallteam() end addEvent("hideLoginWindow", true) addEventHandler("hideLoginWindow", getRootElement(), hideLoginWindow)
  4. ايه في نفس الكود اللي فوق triggerClientEvent (source,"hideLoginWindow",getRootElement())
  5. اسمع ما أضن انه التريقير حق تسجيل الدخول بيأثر لانه في. اية لوحة لتسجيل الدخول مو بس حقت القيم مود يجي الخطا وعلى العموم. هذي التريقر function loginPlayer(username,password) if not (username == "") then if not (password == "") then local account = getAccount ( username, password ) if ( account ~= false ) then logIn (source, account, password) triggerClientEvent (source,"hideLoginWindow",getRootElement()) else OutPut( "user name or paassward is wrong",source,255,255,0) end else OutPut( "enter password",source,255,255,0) end else OutPut( "enter user name",source,255,255,0) end end + المود بدون اضافة قيم حرب شغال تمام يعني بعد التعديل خرب احسكم تضنون انه كله خطأ بدون تعديل والله بتعديل
  6. المود مافيه الا تريقر واحد ذذ وهو triggerServerEvent("onClientWantsToSpawn", getLocalPlayer(), getLocalPlayer(), ID, TeamName[NewTeam]) setTime(12, 0) unbindKey("arrow_r", "down", Nextd) unbindKey("arrow_l", "down", Nextd) unbindKey("arrow_r", "down", Next) unbindKey("arrow_l", "down", Next) unbindKey("enter", "down", SpawnPlayer) if Ped[1] then destroyElement(Ped[1]) Ped[1] = nil end + وآسف إذا غلطت عليكــــــــــــ
  7. إيهـــ موجود وش فيكـــ مآتشوف function showforallteam() foundInTeam = "There are Players" foundInall = "all Players" GameType = {"الــــــــهـــــجـــــولــــــة","حــــــرب الـــعــــصـــابــــات","الــــــــحـــــــــــــــــــرب"} Info = {"<-إخــتــر الـقـيـم مـود->","إضـغـط إنـتـر للإختيار"} fadeCamera( true ) GameNameType = "الــــــــهـــــجـــــولــــــة" typeGame = "drift" mn = nil showChat(false) bindKey("arrow_r","down",ShowGameType) bindKey("arrow_l","down",ShowGameType) bindKey("enter","down",SpawnGameType) l1, l2, l3, l4, l5, l6 = unpack(CamGameType[1]) info1 = Info[1] info2 = Info[2] SelectGame = 3 addEventHandler("onClientRender",getRootElement(),DrawGameType) setCameraMatrix(l1, l2, l3, l4, l5, l6) end هذا بعد ماتسجل دخول يظهر حق إختيار القيمات لكن الخطأ الي في المود خلى القيمات ماتظهر فجاء هذا الخطأ اللي في debugscript 3 أتمنى مستر سعد يدخل لإنهـ صاحب المود هو يعرفلهـ هه
  8. المود يشتغل لكن بعد تسجيل الدخول لمن أبي إختيار القيم مود مايظهر حق إختيار القيم مود تجي الشاشة عادي ومع الماوس وهذا الـــــ debugscript 3
  9. السلام عليكم ورحمة الله وبركاته لاهنتوا ابيكم تصححون ذا المود مره حاولت اصححه كذا مره ماسار شي طبعا المود هو قيم مود حرب العصابات وهجوله حق مستر سعد انا حاولت اسوي قيم زيادة على الحرب والهجوله وسويت كل شي تمام لكن فيه شي خرب المود اتمنى تصححونه clinet local x, y = guiGetScreenSize() rRoot = getResourceRootElement(getThisResource()) Music = "Other/Intro.mp3" Anims = {"DAN_UP_A", "dnce_M_b", "DAN_Left_A", "DAN_Down_A", "DAN_Loop_A", "dance_loop"} num = 0 local TeamNameee = "" local Team = "" local findskin = nil local Text = "" local mn = nil Color = {255, 255, 255} local NewTeam = 0 local ID, skin = nil, nil, nil TeamName = {"Grove", "Aztecas", "Police", "Ballas", "No Team", "Medic", "Drift", "War_Ballas", "War_Grove"} local WaeponID = {5, 22, 3, 1, 32, 41, 43} allPlayer = 0 local Weapon = 0 local NameWeap = "Fist" GameType = {} ColorGame = {0, 255, 255} GameNameType = "" Info = {} SkinSelectMusic = nil local foundTeam = 0 local findskin = 0 typeGame = "drift" local foundInTeam = "" local foundInall = "" Ped = {} skin = { Grove = {105, 106, 107}, Aztecas = {115, 116, 117}, Police = {283, 284, 285}, Ballas = {102, 103, 104}, ["No Team"] = {29, 30, 31}, Medic = {274, 275, 276}, Drift = {46, 124, 43, 63, 64, 75, 285, 0}, WarBallas = {102, 103, 104}, WarGrove = {105, 106, 107} } AllTeamName = { --- Camera & ped -- [x] , [y] , [z], [x1], [y1], [z1] --> CameraMatrix --- [x], [y], [z] ---> position ped Grove = {2494.96948, -1684.03101, 14.3313, 2494.98486, -1685.02856, 14.26363, 2495.38843, -1688.54297, 13.87171}, Aztecas = {1764.75586, -1928.03674, 15.2383, 1763.80432, -1928.0498, 14.93086, 1761.0708, -1928.08801, 13.57734}, Police = {1568.73779, -1695.54541, 7.0456, 1568.71582, -1694.55835, 6.8869, 1568.64075, -1691.68494, 5.89063}, Ballas = {2217.03027, -1167.91956, 27.0701, 2217.0166, -1168.89661, 26.85767, 2216.97534, -1171.77625, 25.72656}, No Team = {901.33551, -1208.65796, 18.4756, 901.27332, -1207.69299, 18.22063, 901.05676, -1204.8208, 16.98322}, Medic = {2022.72839, -1426.36877, 18.3914, 2023.34521, -1425.61548, 18.16297, 2025.20178, -1423.47644, 16.99219}, Drift = {1959.1826171875, 1342.6208496094, 16.885499954224, 1958.2171630859, 1342.6363525391, 16.625249862671, -3689.1884765625, -2997.0432128906, 65.950134277344}, WarBallas = {901.33551, -1208.65796, 18.4756, 901.27332, -1207.69299, 18.22063, 690.064087, -2679.982666, 8.608082}, WarGrove = {2022.72839, -1426.36877, 18.3914, 2023.34521, -1425.61548, 18.16297, 543.465149, -2691.799561, 8.608082} } Rot = {357.4391784668, 271.10339355469, 179.70733642578, 0, 179.01052856445, 132.08488464355,268.76651000977} -- Rotation ped CamGameType = { --- Camera {2053.451171875, 1247.1739501953, 99.397598266602, 2053.4731445313, 1247.9654541016, 98.786827087402}, -- Cam Hajwalah {2454.49487, -1654.69812, 26.19402, 2541.42432, -1686.7251, -11.45641}, --- Cam Gang Wars {2454.49487, -1654.69812, 26.19402, 2541.42432, -1686.7251, -11.45641}, --- Cam War } function dxDrawColorText(str, ax, ay, bx, by, color, scale, font, alignX, alignY) bx, by, color, scale, font = bx or ax, by or ay, color or tocolor(255,255,255,255), scale or 1, font or "default" if alignX then if alignX == "center" then ax = ax + (bx - ax - dxGetTextWidth(str:gsub("#%x%x%x%x%x%x",""), scale, font))/2 elseif alignX == "right" then ax = bx - dxGetTextWidth(str:gsub("#%x%x%x%x%x%x",""), scale, font) end end if alignY then if alignY == "center" then ay = ay + (by - ay - dxGetFontHeight(scale, font))/2 elseif alignY == "bottom" then ay = by - dxGetFontHeight(scale, font) end end local alpha = string.format("%08X", color):sub(1,2) local pat = "(.-)#(%x%x%x%x%x%x)" local s, e, cap, col = str:find(pat, 1) local last = 1 while s do if cap == "" and col then color = tocolor(getColorFromString("#"..col..alpha)) end if s ~= 1 or cap ~= "" then local w = dxGetTextWidth(cap, scale, font) dxDrawText(cap, ax, ay, ax + w, by, color, scale, font,"left", "top", false, false, true, false, false) ax = ax + w color = tocolor(getColorFromString("#"..col..alpha)) end last = e + 1 s, e, cap, col = str:find(pat, last) end if last <= #str then cap = str:sub(last) dxDrawText(cap, ax, ay, ax + dxGetTextWidth(cap, scale, font), by, color, scale, font,"left", "top", false, false, true, false, false) end end local function getTeam(team) return getTeamFromName(team) end local function count(team) return countPlayersInTeam(getTeamFromName(team)) end function onStop() resetSkyGradient() showChat(true) showPlayerHudComponent("all", true) end addEventHandler("onClientResourceStop", resourceRoot, onStop) function foundPos(nummm) local foundPo = AllTeamName[TeamName[NewTeam]][tonumber(nummm)] return foundPo end function showforallteam() foundInTeam = "There are Players" foundInall = "all Players" GameType = {"الــــــــهـــــجـــــولــــــة","حــــــرب الـــعــــصـــابــــات","الــــــــحـــــــــــــــــــرب"} Info = {"<-إخــتــر الـقـيـم مـود->","إضـغـط إنـتـر للإختيار"} fadeCamera( true ) GameNameType = "الــــــــهـــــجـــــولــــــة" typeGame = "drift" mn = nil showChat(false) bindKey("arrow_r","down",ShowGameType) bindKey("arrow_l","down",ShowGameType) bindKey("enter","down",SpawnGameType) l1, l2, l3, l4, l5, l6 = unpack(CamGameType[1]) info1 = Info[1] info2 = Info[2] info3 = Info[3] SelectGame = 2 addEventHandler("onClientRender",getRootElement(),DrawGameType) setCameraMatrix(l1, l2, l3, l4, l5, l6) end addEventHandler("onClientPlayerWasted", getLocalPlayer(), function(killer, weapon, bodypart) if getElementData(localPlayer, "WasChangeTeam") == true then setElementDimension (localPlayer, 0 ) showforallteam() else return false end end) function ShowGameType() if SelectGame == 1 then mn = nil ColorGame = {84,100,222} l1, l2, l3, l4, l5, l6 = unpack(CamGameType[1]) setCameraMatrix(l1, l2, l3, l4, l5, l6) SelectGame = 2 GameNameType = GameType[1] typeGame = "drift" else ColorGame = {255,255,0} l1, l2, l3, l4, l5, l6 = unpack(CamGameType[2]) setCameraMatrix(l1, l2, l3, l4, l5, l6) SelectGame = 1 GameNameType = GameType[2] count2 = count("Grove") count3 = count("Aztecas") count4 = count("Police") count5 = count("Ballas") count6 = count("No Team") mn = count2 + count3 + count4 + count5 + count6 typeGame = "gang" else ColorGame = {255,0,0} l1, l2, l3, l4, l5, l6 = unpack(CamGameType[3]) setCameraMatrix(l1, l2, l3, l4, l5, l6) SelectGame = 3 GameNameType = GameType[3] count2 = count("WarBallas") count3 = count("WarGrove") mn = count2 + count3 typeGame = "war" end end function SpawnGameType() if typeGame == "drift" then setTimer(MakeDrift, 500, 1) elseif typeGame == "gang" then setTimer(MakeGangWars, 500, 1) elseif typeGame == "war" then setTimer(MakeWar, 500, 1) end unbindKey("arrow_r", "down", ShowGameType) unbindKey("arrow_l", "down", ShowGameType) unbindKey("enter", "down", SpawnGameType) TeamNameee = "Team Name" end function MakeGangWars() Color = {0, 255, 0} Team = " " .. TeamName[1] .. " " allPlayer = count(TeamName[1]) Weapon = WaeponID[1] NameWeap = getWeaponNameFromID(Weapon) NameWeap = getWeaponNameFromID(Weapon) NewTeam = 1 local x, y, z, lx, ly, lz = foundPos(1), foundPos(2), foundPos(3), foundPos(4), foundPos(5), foundPos(6) setCameraMatrix(x, y, z, lx, ly, lz) removeEventHandler("onClientRender", getRootElement(), DrawGameType) bindKey("arrow_r", "down", Next) bindKey("arrow_l", "down", Next) bindKey("enter", "down", SpawnPlayer) addEventHandler("onClientRender", getRootElement(), DrawTeam) SkinSelectMusic = playSound(Music, true) local pedx, pedy, pedz = foundPos(7), foundPos(8), foundPos(9) findskin = math.random(1, 3) ID = 105 Ped[1] = createPed(ID, pedx, pedy, pedz, Rot[1]) if not isElement(Ped[1]) then Ped[1] = createPed(ID, pedx, pedy, pedz, Rot[NewTeam]) end setElementFrozen(Ped[1], true) setPedAnimation(Ped[1], "DANCING", Anims[math.random(1, 6)]) foundTeam = 1 findskin = 1 end function Next(key) if key == "arrow_l" then num = num - 1 else num = num + 1 end if key == "arrow_l" then findskin = findskin - 1 else findskin = findskin + 1 end if findskin < 1 then findskin = 3 end if findskin > 3 then findskin = 1 end if num < 1 then num = 16 foundTeam = 6 elseif num == 1 then foundTeam = 1
  10. شكرا بس كان فيه كود غلط فما فتحت اللوحة. وشكرا على المساعده
  11. شكراً طلعت اللوحة عدلت على meta بدال misc script وحذفت كودات خاصة انا مسويها وجات اللوحه شكراً لكم
  12. ترا كلهــ تمام اللي فوق الكلنت وذا الميتا "KING-_-HOHO" name="aa" description="aa" version="1.0" type="misc" /> ومافيه سيرفر
  13. مافتحت وش فيها ظغط اف7 و اف 4 و مافتحت انتوو جربوا تفتح عندكمــ ولا لآآآ
  14. جربت مافتحت اللوحة وش اسوي
  15. السلام عليكم شوفولي حل مع ذي اللوحة جربت كل الطرق والكودات بس مافتحت c GUIEditor = { gridlist = {}, button = {}, checkbox = {}, window = {}, } addEventHandler("onClientResourceStart", resourceRoot, function() GUIEditor.window[1] = guiCreateWindow(211, 80, 387, 484, "panel", false) guiWindowSetSizable(GUIEditor.window[1], false) GUIEditor.gridlist[1] = guiCreateGridList(21, 45, 160, 384, false, GUIEditor.window[1]) guiGridListAddColumn(GUIEditor.gridlist[1], "a", 0.9) GUIEditor.button[1] = guiCreateButton(22, 440, 74, 35, "S", false, GUIEditor.window[1]) GUIEditor.button[3] = guiCreateButton(100, 439, 74, 35, "d", false, GUIEditor.window[1]) GUIEditor.checkbox[1] = guiCreateCheckBox(185, 406, 98, 15, "b", false, false, GUIEditor.window[1]) GUIEditor.checkbox[2] = guiCreateCheckBox(185, 386, 98, 15, "d", false, false, GUIEditor.window[1]) GUIEditor.checkbox[3] = guiCreateCheckBox(185, 366, 98, 15, "n", false, false, GUIEditor.window[1]) GUIEditor.checkbox[4] = guiCreateCheckBox(185, 346, 98, 15, "l", false, false, GUIEditor.window[1]) guiSetVisible (GUIEditor.window[1], false) end ) function OpenWin() if guiGetVisible (GUIEditor.window[1] ) then guiSetVisible ( GUIEditor.window[1], false ) showCursor(false) guiSetInputEnabled(false) else guiSetVisible ( GUIEditor.window[1], true ) showCursor(true) guiSetInputEnabled(true) end end bindKey("F7", "down", OpenWin)
  16. مانفع ولا شي بالنسبه للكود موجود المود كامل بالكومنتي هذا الرابط https://community.multitheftauto.com/index.php?p=resources&s=details&id=8966
  17. السلام عليكم ورحمة الله وبركاته ليش ذي الماركرات ماتجي مع انه اول كانت تجي بس اللحين ماتجي ليش server object1 = createObject ( 2930, 1560, -1664.9000244141, 549.79998779297 ) marker1 = createMarker ( 1560, -1664.9000244141, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object2 = createObject ( 971, 1564.5999755859, -1661.8000488281, 549.40002441406 ) marker2 = createMarker ( 1564.5999755859, -1661.8000488281, 549.40002441406, 'cylinder', 3.5, 0, 0, 0, 0 ) object3 = createObject ( 2930, 1575.3000488281, -1658, 549.79998779297 ) marker3 = createMarker ( 1575.3000488281, -1658, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object4 = createObject ( 2930, 1575.3000488281, -1653.3000488281, 549.79998779297 ) marker4 = createMarker ( 1575.3000488281, -1653.3000488281, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object5 = createObject ( 2930, 1575.3000488281, -1648.5, 549.79998779297 ) marker5 = createMarker ( 1575.3000488281, -1648.5, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object6 = createObject ( 2930, 1575.3000488281, -1643.8000488281, 549.79998779297) marker6 = createMarker ( 1575.3000488281, -1643.8000488281, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object7 = createObject ( 2930, 1575.3000488281, -1639, 549.79998779297) marker7 = createMarker ( 1575.3000488281, -1639, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object8 = createObject ( 2930, 1575.3000488281, -1633.8000488281, 549.79998779297) marker8 = createMarker ( 1575.3000488281, -1633.8000488281, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object9 = createObject ( 971, 1569.099609375, -1632.5, 550.20001220703 ) marker9 = createMarker ( 1569.099609375, -1632.5, 550.20001220703, 'cylinder', 3.5, 0, 0, 0, 0 ) object10 = createObject ( 2930, 1559.099609375, -1633.69921875, 549.79998779297 ) marker10 = createMarker ( 1559.099609375, -1633.69921875, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object11 = createObject ( 2930, 1559, -1638.9000244141, 549.79998779297 ) marker11 = createMarker ( 1559, -1638.9000244141, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object12 = createObject ( 2930, 1559, -1643.6999511719, 549.79998779297 ) marker12 = createMarker ( 1559, -1643.6999511719, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object13 = createObject ( 2930, 1559.0999755859, -1648.4000244141, 549.79998779297 ) marker13 = createMarker ( 1559.0999755859, -1648.4000244141, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object14 = createObject ( 2930, 1559, -1653.1999511719, 549.79998779297 ) marker14 = createMarker ( 1559, -1653.1999511719, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object15 = createObject ( 2930, 1559, -1658, 549.79998779297 ) marker15 = createMarker ( 1559, -1658, 549.79998779297, 'cylinder', 3.5, 0, 0, 0, 0 ) object16 = createObject ( 2930, 1559.0999755859, -1633.6999511719, 556.09997558594 ) marker16 = createMarker ( 1559.0999755859, -1633.6999511719, 'cylinder', 3.5, 0, 0, 0, 0 ) object17 = createObject ( 2930, 1559.0999755859, -1638.9000244141, 556.09997558594 ) marker17 = createMarker ( 1559.0999755859, -1638.9000244141, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object18 = createObject ( 2930, 1559, -1643.6999511719, 556.09997558594 ) marker18 = createMarker ( 1559, -1643.6999511719, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object19 = createObject ( 2930, 1559.0999755859, -1648.4000244141, 556.09997558594 ) marker19 = createMarker ( 1559.0999755859, -1648.4000244141, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object20 = createObject ( 2930, 1559.0999755859, -1653.1999511719, 556.09997558594 ) marker20 = createMarker ( 1559.0999755859, -1653.1999511719, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object21 = createObject ( 2930, 1559.0999755859, -1658.0999755859, 556.09997558594 ) marker21 = createMarker ( 1559.0999755859, -1658.0999755859, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object22 = createObject ( 2930, 1559.0999755859, -1663, 556.09997558594 ) marker22 = createMarker ( 1559.0999755859, -1663, 556.0999755859, 'cylinder', 3.5, 0, 0, 0, 0 ) object23 = createObject ( 2930, 1575.3000488281, -1663.0999755859, 556.09997558594 ) marker23 = createMarker ( 1575.3000488281, -1663.0999755859, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object24 = createObject ( 2930, 1575.1999511719, -1658.1999511719, 556.09997558594 ) marker24 = createMarker ( 1575.1999511719, -1658.1999511719, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object25 = createObject ( 2930, 1575.1999511719, -1653.3000488281, 556.09997558594 ) marker25 = createMarker ( 1575.1999511719, -1653.3000488281, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object26 = createObject ( 2930, 1575.1999511719, -1648.5, 556.09997558594 ) marker26 = createMarker ( 1575.1999511719, -1648.5, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object27 = createObject ( 2930, 1575.1999511719, -1643.8000488281, 556.09997558594 ) marker27 = createMarker ( 1575.1999511719, -1643.8000488281, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object28 = createObject ( 2930, 1575.1999511719, -1639, 556.09997558594 ) marker28 = createMarker ( 1575.1999511719, -1639, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) object29 = createObject ( 2930, 1575.1999511719, -1633.8000488281, 556.09997558594 ) marker29 = createMarker ( 1575.1999511719, -1633.8000488281, 556.09997558594, 'cylinder', 3.5, 0, 0, 0, 0 ) i1 = false i2 = false i3 = false i4 = false i5 = false i6 = false i7 = false i8 = false i9 = false i10 = false i11 = false i12 = false i13 = false i14 = false i15 = false i16 = false i17 = false i18 = false i19 = false i20 = false i21 = false i22 = false i23 = false i24 = false i25 = false i26 = false i27 = false i28 = false i29 = false function AlBab ( plr_ ) local player = plr_ or source local playerTeam = getPlayerTeam ( player ) local policeTeam = getTeamFromName ( "Police" ) if playerTeam and policeTeam then if playerTeam == policeTeam then if isElementWithinMarker ( player, marker1 ) then if i1 then moveObject ( object1, 2500, 1560, -1663.3000488281, 549.79998779297 ) i1 = false else moveObject ( object1, 1500, 1560, -1664.9000244141, 549.79998779297 ) i1 = true end elseif isElementWithinMarker ( player, marker2 ) then if i2 then moveObject ( object2, 2500, 1572.5999755859, -1661.8000488281, 549.40002441406 ) i2 = false else moveObject ( object2, 1500, 1564.5999755859, -1661.8000488281, 549.40002441406 ) i2 = true end elseif isElementWithinMarker ( player, marker3 ) then if i3 then moveObject ( object3, 2500, 1575.3000488281, -1656.5, 549.79998779297 ) i3 = false else moveObject ( object3, 1500, 1575.3000488281, -1658, 549.79998779297 ) i3 = true end elseif isElementWithinMarker ( player, marker4 ) then if i4 then moveObject ( object4, 2500, 1575.3000488281, -1651.8000488281, 549.79998779297 ) i4 = false else moveObject ( object4, 1500, 1575.3000488281, -1653.3000488281, 549.79998779297 ) i4 = true end elseif isElementWithinMarker ( player, marker5 ) then if i5 then moveObject ( object5, 2500, 1575.3000488281, -1647, 549.79998779297 ) i5 = false else moveObject ( object5, 1500, 1575.3000488281, -1648.5, 549.79998779297 ) i5 = true end elseif isElementWithinMarker ( player, marker6 ) then if i6 then moveObject ( object6, 2500, 1575.3000488281, -1642.1999511719, 549.79998779297 ) i6 = false else moveObject ( object6, 1500, 1575.3000488281, -1643.8000488281, 549.79998779297 ) i6 = true end elseif isElementWithinMarker ( player, marker7 ) then if i7 then moveObject ( object7, 2500, 1575.3000488281, -1637.5, 549.79998779297 ) i7 = false else moveObject ( object7, 1500, 1575.3000488281, -1639, 549.79998779297 ) i7 = true end elseif isElementWithinMarker ( player, marker8 ) then if i8 then moveObject ( object8, 2500, 1575.3000488281, -1632.3000488281, 549.79998779297 ) i8 = false else moveObject ( object8, 1500, 1575.3000488281, -1633.8000488281, 549.79998779297 ) i8 = true end elseif isElementWithinMarker ( player, marker9 ) then if i9 then moveObject ( object9, 2500, 1571.9000244141, -1632.5, 550.20001220703 ) i9 = false else moveObject ( object9, 1500, 1569.099609375, -1632.5, 550.20001220703 ) i9 = true end elseif isElementWithinMarker ( player, marker10 ) then if i10 then moveObject ( object10, 2500, 1559, -1635.1999511719, 549.79998779297 ) i10 = false else moveObject ( object10, 1500, 1559.099609375, -1633.69921875, 549.79998779297 ) i10 = true end elseif isElementWithinMarker ( player, marker11 ) then if i11 then moveObject ( object11, 2500, 1559, -1640.5, 549.79998779297 ) i11 = false else moveObject ( object11, 1500, 1559, -1638.9000244141, 549.79998779297 ) i11 = true end elseif isElementWithinMarker ( player, marker12 ) then if i12 then moveObject ( object12, 2500, 1559, -1645.3000488281, 549.79998779297 ) i12 = false else moveObject ( object12, 1500, 1559, -1643.6999511719, 549.79998779297 ) i12 = true end elseif isElementWithinMarker ( player, marker13 ) then if i13 then moveObject ( object13, 2500, 1559.0999755859, -1650, 549.79998779297 ) i13 = false else moveObject ( object13, 1500, 1559.0999755859, -1648.4000244141, 549.79998779297 ) i13 = true end elseif isElementWithinMarker ( player, marker14 ) then if i14 then moveObject ( object14, 2500, 1559, -1654.8000488281, 549.79998779297 ) i14 = false else moveObject ( object14, 1500, 1559, -1653.1999511719, 549.79998779297 ) i14 = true end elseif isElementWithinMarker ( player, marker15 ) then if i15 then moveObject ( object15, 2500, 1559, -1659.5, 549.79998779297 ) i15 = false else moveObject ( object15, 1500, 1559, -1658, 549.79998779297 ) i15 = true end elseif isElementWithinMarker ( player, marker16 ) then if i16 then moveObject ( object16, 2500, 1559.0999755859, -1635.3000488281, 556.09997558594 ) i16 = false else moveObject ( object16, 1500, 1559.0999755859, -1633.6999511719, 556.09997558594 ) i16 = true end elseif isElementWithinMarker ( player, marker17 ) then if i17 then moveObject ( object17, 2500, 1559.0999755859, -1640.5, 556.09997558594 ) i17 = false else moveObject ( object17, 1500, 1559.0999755859, -1638.9000244141, 556.09997558594 ) i17 = true end elseif isElementWithinMarker ( player, marker18 ) then if i18 then moveObject ( object18, 2500, 1559.0999755859, -1645.3000488281, 556.09997558594 ) i18 = false else moveObject ( object18, 1500, 1559, -1643.6999511719, 556.09997558594 ) i18 = true end elseif isElementWithinMarker ( player, marker19 ) then if i19 then moveObject ( object19, 2500, 1559.0999755859, -1650, 556.09997558594 ) i19 = false else moveObject ( object19, 1500, 1559.0999755859, -1648.4000244141, 556.09997558594 ) i19 = true end elseif isElementWithinMarker ( player, marker20 ) then if i20 then moveObject ( object20, 2500, 1559.0999755859, -1654.8000488281, 556.09997558594 ) i20 = false
  18. عرفت الحل هذا هو الحل Server startJailTimer ( thePlayer , theTimex ) local x,y,z = theJail[2],theJail[3],theJail[4] local int = theJail[0]-------------------تغير 5 وتحطها 0 local dim = theJail[6] setElementInterior ( thePlayer, int ) setElementDimension ( thePlayer, dim ) setElementPosition (thePlayer,x,y,z ) setElementData(thePlayer,"jailed",true) setElementData(rRoot,""..getPlayerSerial(thePlayer).."-j",true) toggleControl(thePlayer,"fire",false) if showWho ~= true then outputChatBox("** #FFFF00You Jailed [ "..getPlayerName(thePlayer).." #FFFF00] at "..theJail[1].." For "..time,source,255,0,0,true) outputChatBox("** #FFFF00You Have Been Jailed By [ "..getPlayerName(source).." #FFFF00] at "..theJail[1].." For "..time,thePlayer,255,0,0,true) end Data "Jail 1" posX="1829.7049560547" posY="862.68627929688" posZ="11.497849464417" int="1" dim="1"/> " int="1" تغير الـــ وتغيير 1 وتخليه 0 يسير كذا "Jail 1" posX="1829.7049560547" posY="862.68627929688" posZ="11.497849464417" int="0" dim="1"/> وبعد كذا غير الإحداثيات على كيفكــــــ
  19. تم التعديل وش الخطأ الحين
  20. هل هو هذا الكود اللي ضفته ولا فيه اكواد ثانيه local iTeam = 'drift' function toggleFRWindow ( ) if getPlayerTeam ( localPlayer ) and getTeamName ( getPlayerTeam ( localPlayer ) ) ~= iTeam then return false end if isWindowOpen(wndMain) then showCursor(false) hideAllWindows() colorPicker.closeSelect() else showCursor(true) showAllWindows() end end
  21. السلام عليكم ورحمة الله فيه هنا خطأ محيرني ماقدرت أحله وهو لمن أسجن يجي اللاعب في سراب ويطيح من فوووق أرجوكم حلو الخطأ Client lp = getLocalPlayer() rRoot = getResourceRootElement(getThisResource()) setElementData(lp,"jailed",false) ------ addEventHandler("onClientResourceStart",rRoot,function() triggerServerEvent("getDataz",lp,lp) outputDebugString("Jail System v2.1 By Al3grab | Started") end ) desz = {} addEvent("sendDataz",true) addEventHandler("sendDataz",root,function(jTable,tTable) ------ jWin = guiCreateWindow(460,172,445,416,"Jail System v2.1 | By KING-_-HOHO",false) --- Center Window --- local screenW,screenH=guiGetScreenSize() local windowW,windowH=guiGetSize(jWin,false) local x,y = (screenW-windowW)/2,(screenH-windowH)/2 guiSetPosition(jWin,x,y,false) ----- Center Window ----- guiSetVisible(jWin,false) guiWindowSetSizable(jWin,false) ------------------------- jBut = guiCreateButton(247,338,167,31,"Jail Him",false,jWin) tGrid = guiCreateGridList(240,184,190,144,false,jWin) guiGridListSetSelectionMode(tGrid,0) ------- -- sEdit = guiCreateEdit(14,380,217,23,"Search ..",false,jWin) -- -------- local timeC = guiGridListAddColumn( tGrid, "Time", 0.85 ) if timeC then for k,v in ipairs ( tTable ) do local time = v[1] local des = v[2] local row = guiGridListAddRow ( tGrid ) desz[row] = des guiGridListSetItemText ( tGrid, row, timeC, time.." "..des, false, true ) end local row = guiGridListAddRow ( tGrid ) guiGridListSetItemText ( tGrid, row, timeC,"Other ..", false, true ) end -------- jGrid = guiCreateGridList(240,31,190,144,false,jWin) guiGridListSetSelectionMode(jGrid,0) -------- local jailC = guiGridListAddColumn( jGrid, "Jail", 0.85 ) for k,v in ipairs ( jTable ) do local name = v[1] local row = guiGridListAddRow ( jGrid ) guiGridListSetItemText ( jGrid, row, jailC, name, false, false ) end jcBut = guiCreateButton(246,378,172,24,"Close",false,jWin) function jailShow () guiSetVisible(jWin,not guiGetVisible ( jWin ) ) showCursor(guiGetVisible ( jWin ) ) guiSetInputEnabled(guiGetVisible ( jWin ) ) destroyElement(pList) -- Players List pList = guiCreateGridList(14,31,218,338,false,jWin) column = guiGridListAddColumn( pList, "Player", 0.85 ) if ( column ) then for id, player in ipairs(getElementsByType("player")) do row = guiGridListAddRow ( pList ) guiGridListSetItemText ( pList, row, column, getPlayerName ( player ), false, false ) end end -- Players List end addEvent("jailShow",true) addEventHandler("jailShow",root,jailShow) function changeText(button,state,x,y) selectedRow, selectedCol = guiGridListGetSelectedItem( pList ) sPlayer = guiGridListGetItemText( pList, selectedRow, selectedCol ) local thePlr = getPlayerFromName(sPlayer) if thePlr then local isJailed = getElementData(thePlr,"jailed") if isJailed == false then guiSetText(jBut,"Jail Him") elseif isJailed == true then guiSetText(jBut,"Release Him") end end end addEventHandler("onClientGUIClick",root,changeText) function onClick (button, state, absoluteX, absoluteY) selectedRow, selectedCol = guiGridListGetSelectedItem( pList ) sPlayer = guiGridListGetItemText( pList, selectedRow, selectedCol ) jail = guiGridListGetItemText ( jGrid, guiGridListGetSelectedItem ( jGrid ), 1 ) time = guiGridListGetItemText ( tGrid, guiGridListGetSelectedItem ( tGrid ), 1 ) timeDes = tostring(desz[guiGridListGetSelectedItem ( tGrid )]) if ( source == jBut ) then if guiGetText(jBut) == "Jail Him" then if time ~= "Other .." then triggerServerEvent("JailHimx",lp,sPlayer,jail,time,timeDes) else createTimeSelect(sPlayer,jail) end elseif guiGetText(jBut) == "Release Him" then triggerServerEvent("unJailHim",lp,sPlayer) end ---------- elseif ( source == jcBut ) then guiSetVisible (jWin, false) showCursor (false) guiSetInputEnabled(false) end end addEventHandler( "onClientGUIClick", root, onClick ) ------------ end ) addEventHandler("onClientPlayerDamage",root,function(at) if getElementData(source,"jailed") == true then if at then cancelEvent() end end end ) ------- addEventHandler("onClientGUIClick",root,function() if source == sEdit then guiSetText(sEdit,"") --[[ else guiSetText(sEdit,"Search ..") --]] end end ) addEventHandler("onClientGUIChanged",root,function() if source == sEdit then ------ guiGridListClear(pList) for k,v in ipairs ( getElementsByType("player") ) do local name = string.lower(getPlayerName(v)) if name then if string.find (name,string.lower(guiGetText(sEdit)) ) then row = guiGridListAddRow ( pList ) guiGridListSetItemText ( pList, row, column, getPlayerName ( v ), false, false ) end end end end ------ end ) ------ function createTimeSelect(theJailed,theJail) if not tostring(theJailed) then outputChatBox("** #FFFF00Please Select a Player !",255,0,0,true) return end if not tostring(theJail) then outputChatBox("** #FFFF00Please Select a Jail !",255,0,0,true) return end if isElement(TimeSelect_Window) then return end TimeSelect_Window = guiCreateWindow(550,397,270,125,"Enter Time",false) -- local screenW,screenH=guiGetScreenSize() local windowW,windowH=guiGetSize(TimeSelect_Window,false) local x,y = (screenW-windowW)/2,(screenH-windowH)/2 guiSetPosition(TimeSelect_Window,x,y,false) -- -- guiSetVisible(jWin,false) -- TimeSelect_Edit = guiCreateEdit(15,37,89,26,"",false,TimeSelect_Window) TimeSelect_Label = guiCreateLabel(110,41,10,15,"in",false,TimeSelect_Window) TimeSelect_Grid = guiCreateGridList(126,31,130,95,false,TimeSelect_Window) guiGridListSetSelectionMode(TimeSelect_Grid,2) --- column = guiGridListAddColumn( TimeSelect_Grid, "", 0.80 ) r1 = guiGridListAddRow(TimeSelect_Grid) r2 = guiGridListAddRow(TimeSelect_Grid) r3 = guiGridListAddRow(TimeSelect_Grid) guiGridListSetItemText ( TimeSelect_Grid , r1, column, "Hours", false, false ) guiGridListSetItemText ( TimeSelect_Grid , r2, column,"Minutes", false, false ) guiGridListSetItemText ( TimeSelect_Grid , r3, column, "Seconds", false, false ) TimeSelect_Button = guiCreateButton(14,72,91,40,"OK",false,TimeSelect_Window) -- function onOk() if source == TimeSelect_Button then -- removeEventHandler("onClientGUIClick",root,onOk) -- ---------------- theTime = guiGetText(TimeSelect_Edit) timeType = guiGridListGetItemText ( TimeSelect_Grid, guiGridListGetSelectedItem ( TimeSelect_Grid ) ) -- destroyElement(TimeSelect_Window) jailShow () -- if tonumber(theTime) then if tostring(timeType) then triggerServerEvent("JailHimx",lp,theJailed,theJail,theTime.." "..timeType,timeType,true) else outputChatBox("** #FFFF00Please Select , Hours or Minutes or Seconds !",255,0,0,true) end else outputChatBox("** #FFFF00Please Enter a Number !",255,0,0,true) end ---------------- end end addEventHandler("onClientGUIClick",root,onOk) end Server Command = get("command") -- getTheCommand rRoot = getResourceRootElement(getThisResource()) ------ function getData(to) local file = xmlLoadFile("data.xml") jTable = {} tTable = {} if file then for k,v in ipairs (xmlNodeGetChildren(xmlFindChild(file,"Jails",0)))do local name = xmlNodeGetAttribute(v,"name") local posX,posY,posZ = xmlNodeGetAttribute(v,"posX"),xmlNodeGetAttribute(v,"posY"),xmlNodeGetAttribute(v,"posZ") local int = xmlNodeGetAttribute(v,"int") local dim = xmlNodeGetAttribute(v,"dim") table.insert(jTable, {name,posX,posY,posZ,int,dim}) end for k,v in ipairs (xmlNodeGetChildren(xmlFindChild(file,"time",0)))do local times = xmlNodeGetAttribute(v,"times") for i =1,50 do local iTime = gettok ( times, i, string.byte(',') ) if iTime then -- if tonumber(iTime) > 59.5 then iTime = math.floor(iTime / 60) iTimeDes = "Minutes" if iTime > 59.5 then iTime = math.floor(iTime / 60) iTimeDes = "Hours" end else iTimeDes = "Seconds" end table.insert(tTable,{iTime,iTimeDes}) end end end end triggerClientEvent(to,"sendDataz",to,jTable,tTable) -- sending to client event end addEvent("getDataz",true) addEventHandler("getDataz",root,getData) addCommandHandler ( Command, -- Adding The Command Handler function ( player, cmd ) if hasObjectPermissionTo ( player, "function.banPlayer" ) then triggerClientEvent(player,"jailShow",player) else outputChatBox(" Access Denied ",player,255,0,0) end end ) anims = { "F_smklean_loop", "M_smklean_loop", "M_smkstnd_loop", "M_smk_drag", "M_smk_in", "M_smk_loop", "M_smk_out", "M_smk_tap" , } function removeVehicle(thePlayer) if isPedInVehicle(thePlayer) then destroyElement(getPedOccupiedVehicle(thePlayer)) end end function JailHim(jailed,theJails,time,timeDes,showWho,timeReady) thePlayer = getPlayerFromName(jailed) if not thePlayer then outputChatBox("** #FFFF00Please Select a Player !",source,255,0,0,true) return end removePedFromVehicle(thePlayer) for k,v in ipairs ( jTable ) do if theJails == v[1] then theJail = v end end if theJail then if tostring(time) then if timeReady == true then theTimex = tonumber(time) else theTimex = gettok ( time, 1, string.byte(timeDes) ) end if timeDes == "Hours" then theTimex = math.floor(theTimex*60*60*1000) elseif timeDes == "Minutes" then theTimex = math.floor(theTimex*60*1000) elseif timeDes == "Seconds" then theTimex = math.floor(theTimex*1000) end startJailTimer ( thePlayer , theTimex ) local x,y,z = theJail[2],theJail[3],theJail[4] local int = theJail[5] local dim = theJail[6] setElementInterior ( thePlayer, int ) setElementDimension ( thePlayer, dim ) setElementPosition (thePlayer,x,y,z ) setElementData(thePlayer,"jailed",true) setElementData(rRoot,""..getPlayerSerial(thePlayer).."-j",true) toggleControl(thePlayer,"fire",false) if showWho ~= true then outputChatBox("** #FFFF00You Jailed [ "..getPlayerName(thePlayer).." #FFFF00] at "..theJail[1].." For "..time,source,255,0,0,true) outputChatBox("** #FFFF00You Have Been Jailed By [ "..getPlayerName(source).." #FFFF00] at "..theJail[1].." For "..time,thePlayer,255,0,0,true) end outputChatBox("** #FFFF00[ "..getPlayerName(thePlayer).." #FFFF00] Has Been Jailed For "..time,root,255,0,0,true) else outputChatBox("** #FFFF00Please Select Time !",source,255,0,0,true) end else outputChatBox("** #FFFF00Please Select a Jail !",source,255,0,0,true) end end addEvent("JailHimx",true) addEventHandler("JailHimx",root,JailHim) function unJailHim(jailed,showWho) thePlayer = getPlayerFromName(jailed) if not thePlayer then outputChatBox("** #FFFF00Please Select a Player !",source,255,0,0,true) return end --if getElementData(thePlayer,"jailed") == true then setElementInterior ( thePlayer, 0) setElementDimension ( thePlayer, 0 ) setElementPosition ( thePlayer, 1552.9108886719, -1675.5844726563, 16.1953125) setElementData(thePlayer,"jailed",false) setElementData(rRoot,""..getPlayerSerial(thePlayer).."-j",false) if showWho ~= true then outputChatBox("** #FFFF00You Released [ "..getPlayerName(thePlayer).." #FFFF00]",source,255,0,0,true) outputChatBox("** #FFFF00You Have Been Released by [ "..getPlayerName(source).." #FFFF00]",thePlayer,255,0,0,true) end outputChatBox("** #FFFF00[ "..getPlayerName(thePlayer).." #FFFF00] Has Been Released ",root,255,0,0,true) setPedAnimation(thePlayer) stopJailTimer(Player) toggleControl(thePlayer,"fire",true) -- setTimer(killPed,1500,1,thePlayer) --else -- outputChatBox("The Player is Not Jailed !",source,255,0,0,true) --end end addEvent("unJailHim",true)-- unJail addEventHandler("unJailHim",root,unJailHim) addEvent("onJailEnd",true) addEventHandler("onJailEnd",root,function(player) unJailHim(getPlayerName(player),true) end ) addEventHandler("onPlayerSpawn",root, -- Check If He Is Jailed [ OnSpawn ] function() if getElementData(source,"jailed") == true then randomJail = jTable[math.random(#jTable)] if randomJail then x,y,z = randomJail[2],randomJail[3],randomJail[4] int = randomJail[5] dim = randomJail[6] setElementInterior ( source, int ) setElementDimension(source,dim) setElementPosition (source,x,y,z ) end end end) addEventHandler("onPlayerJoin",root, -- Check If He Is Jailed - By Serial [ OnJoin ] function() if getElementData(rRoot,""..getPlayerSerial(source).."-j") == true then randomJail = jTable[math.random(#jTable)] if randomJail then x,y,z = randomJail[2],randomJail[3],randomJail[4] int = randomJail[5] dim = randomJail[6] setElementInterior ( source, int ) setElementDimension(source,dim) setElementPosition (source,x,y,z ) -- time = getElementData(rRoot,""..getPlayerSerial(source).."-t",time) or 5 * 1000 startJailTimer(source,time) setElementData(source,"jailed",true) end end end ) ---- function startJailTimer(Player,theTime) -- to start mission timer .. if Player then TimerDisplay = textCreateDisplay() m,s,cs = msToTimeStr(theTime) fullTime = m..":"..s TimerText = textCreateTextItem ( "Time Left : "..tostring(fullTime).."", 0.39, 0.7 ,"medium",0,255,0,255,2.0,"left","center",255) textDisplayAddText ( TimerDisplay, TimerText ) textDisplayAddObserver ( TimerDisplay, Player ) sortTimerShit(Player,TimerText,theTime) end end --Robbed from JailTimerr resource , and it was robbed from arc_ function msToTimeStr(ms) if not ms then return '' end if ms < 0 then return "0","00","00" end local centiseconds = tostring(math.floor(math.fmod(ms, 1000)/10)) if #centiseconds == 1 then centiseconds = '0' .. centiseconds end local s = math.floor(ms / 1000) local seconds = tostring(math.fmod(s, 60)) if #seconds == 1 then seconds = '0' .. seconds end local minutes = tostring(math.floor(s / 60)) return minutes, seconds, centiseconds end function sortTimerShit(plr,timer,time) -- to sort timer's shit .. if timer and time then if isTimer(timerShitTimer) then killTimer(timerShitTimer) end timerShitTimer = setTimer(function(plr) time = time - 70 m,s,cs = msToTimeStr(time) fullTime = m..":"..s textItemSetText(timer,"Time Left : "..tostring(fullTime).."") if plr then setElementData(rRoot,""..getPlayerSerial(plr).."-t",time) end if ( tonumber(m) <= 0 and tonumber(s) <= 0 and tonumber(cs) <= 0 ) then onTimerFinish(plr,timer) end end , 50 , 0 ,plr ) end end function stopJailTimer(Player) textDestroyDisplay(TimerDisplay) if TimerText then textDestroyTextItem(TimerText) end if isTimer(timerShitTimer) then killTimer(timerShitTimer) end end function onTimerFinish(Player) -- on timer end stopJailTimer
  22. تقصد ذا الماركر مو مشفر https://community.multitheftauto.com/index.php?p=resources&s=details&id=7493
  23. هذا رابط للمود مافيه حفظ مكان ولا شخصيه ولاتيم لاكن فيه حفظ فلووس وسلااح والنجوم http://www.gulfup.com/?eJe64z
  24. شكرا على التنويه يا نصور واللحين بحط الرابط للمود مافيه حفظ مكان ولا شخصيه ولاتيم
×
×
  • Create New...