Jump to content

اتمني التعديل علي الكود وشكرا/تمت الافاده من اخونا جعفر شكرا


Recommended Posts

شباب معي كود ماركر سيارات الشرطهويشتغل تمام التمام

بس المجرم يقدر ياخد سياره ابيكم تعدلولي علي الكود وتجعلوه لتيم الشرطه فقط شباب وتقبلو دعائي وشكرا

اتمني ماتقصرو معي شباب

هدا السيرفر

markers = { 
    {1585.4683837891,-1677.7601318359,4.5}, 
    {1601.015625,-1709.9270019531,4.5}, 
    {1544.4505615234,-1645.6096191406,4.5}, 
    {1546.0128173828,-1609.8051757813,12.5}, 
    {1599.4171142578,-1610.4891357422,12.5}, 
    {1600.0526123047,-1627.7546386719,12.5}, 
  --{ x, y, z }, 
  } 
  
  
for i,v in ipairs (markers) do 
    marker = createMarker(v[1], v[2], v[3], "cylinder", get("markerSize"), get("markerColorR"), get("markerColorG"), get("markerColorB"), get("markerAlpha")) 
end 
  
veh = {} 
  
addEvent ("getCar", true) 
addEventHandler ("getCar", getRootElement(), 
function(car) 
    if veh[source] and isElement( veh[source] ) then destroyElement( veh[source] )  
    veh[source] = nil  
    end 
     
end 
) 
  
addEventHandler ( "onPlayerQuit", getRootElement(),  
function () 
    if veh[source] and isElement( veh[source] ) then destroyElement( veh[source] )  
    veh[source] = nil  
    end 
end) 
  
function markerHit (hitPlayer, matchingDimension) 
if isPedInVehicle (hitPlayer) then return end 
if getElementType(hitPlayer) == "player" then 
    triggerClientEvent ("openMean2000", hitPlayer) 
end 
end 
  
addEventHandler ("onMarkerHit", resourceRoot, markerHit) 
  
function markerLeave (hitPlayer, matchingDimension) 
if getElementType(hitPlayer) == "player" then 
   triggerClientEvent ("closeopenMean2000", hitPlayer) 
end 
end 
addEventHandler ("onMarkerLeave", resourceRoot, markerLeave) 

وهدا الوند

GUIEditor = { 
    gridlist = {}, 
    window = {}, 
    button = {} 
} 
  
cars = { 
    {523}, 
    {598}, 
    {597}, 
    {599}, 
  
  --{carID}, 
    } 
  
local l, w = guiGetScreenSize() 
GUIEditor.window[1111] = guiCreateWindow(231, 161, 256, 306, "[Gta-DARCK] Police Cars", false) 
guiWindowSetSizable(GUIEditor.window[1111], false) 
guiSetVisible(GUIEditor.window[1111],false) 
guiSetAlpha(GUIEditor.window[1111], 1.00) 
guiSetProperty(GUIEditor.window[1111], "CaptionColour", "FFFFFFFF") 
  
GUIEditor.gridlist[1000] = guiCreateGridList(9, 21, 237, 275, false, GUIEditor.window[1111]) 
guiGridListAddColumn(GUIEditor.gridlist[1000], "#", 0.4) 
guiGridListAddColumn(GUIEditor.gridlist[1000], "Vehicle", 0.4) 
GUIEditor.button[1001] = guiCreateButton(4, 255, 141, 15, "Spawn", false, GUIEditor.gridlist[1000]) 
GUIEditor.button[2002] = guiCreateButton(149, 255, 78, 15, "Close", false, GUIEditor.gridlist[1000]) 
  
for i,v in ipairs (cars) do 
    local carName = getVehicleNameFromModel (v[1]) 
    local row = guiGridListAddRow (GUIEditor.gridlist[1000]) 
    guiGridListSetItemText (GUIEditor.gridlist[1000], row, 1, i.."-", false, true) 
    guiGridListSetItemText (GUIEditor.gridlist[1000], row, 2, carName, false, true) 
    guiGridListSetItemColor(GUIEditor.gridlist[1000], row, 1, 255, 255, 255, 255) 
end 
  
addEvent ("openMean2000", true) 
function openMean2000 () 
if (getLocalPlayer() == source) then 
guiSetVisible(GUIEditor.window[1111],true) 
showCursor(true) 
end 
end 
addEventHandler ("openMean2000", getRootElement(), openMean2000) 
  
addEvent ("closeopenMean2000", true) 
function closeopenMean2000 () 
if (getLocalPlayer() == source) then 
guiSetVisible(GUIEditor.window[1111],false) 
showCursor(false) 
end 
end 
addEventHandler ("closeopenMean2000", getRootElement(), closeopenMean2000) 
  
addEventHandler ("onClientGUIClick", GUIEditor.button[2002], 
function (button, state, absoluteX, absoluteYe) 
 guiSetVisible(GUIEditor.window[1111],false) 
 showCursor(false) 
end) 
function trigger () 
if (guiGridListGetSelectedItem (GUIEditor.gridlist[1000])) then 
local car = guiGridListGetItemText (GUIEditor.gridlist[1000], guiGridListGetSelectedItem (GUIEditor.gridlist[1000]), 2) 
if car == "" or car == nil then outputChatBox( "oعليك ان تختار سيارةo",255,0,0,true ) return end 
  triggerServerEvent ("getCar", getLocalPlayer(), car) 
  guiSetVisible(GUIEditor.window[1111],false) 
  showCursor(false) 
end 
end 
  
addEventHandler ("onClientGUIClick", GUIEditor.button[1001], 
function (button, state, absoluteX, absoluteYe) 
trigger(getLocalPlayer()) 
end) 
  
addEventHandler ("onClientGUIDoubleClick", GUIEditor.gridlist[1000], 
function (button, state, absoluteX, absoluteYe) 
trigger(getLocalPlayer()) 
end) 

اتمني ماتقصرو معي شباب لان هدا طولت فيه

Edited by Guest
Link to comment

هدا السيرفر

markers = { 
    {1585.4683837891,-1677.7601318359,4.5}, 
    {1601.015625,-1709.9270019531,4.5}, 
    {1544.4505615234,-1645.6096191406,4.5}, 
    {1546.0128173828,-1609.8051757813,12.5}, 
    {1599.4171142578,-1610.4891357422,12.5}, 
    {1600.0526123047,-1627.7546386719,12.5}, 
  --{ x, y, z }, 
  } 
  
  
for i,v in ipairs (markers) do 
    marker = createMarker(v[1], v[2], v[3], "cylinder", get("markerSize"), get("markerColorR"), get("markerColorG"), get("markerColorB"), get("markerAlpha")) 
end 
  
veh = {} 
  
addEvent ("getCar", true) 
addEventHandler ("getCar", getRootElement(), 
function(car) 
    if veh[source] and isElement( veh[source] ) then destroyElement( veh[source] )  
    veh[source] = nil  
    end 
     
end 
) 
  
addEventHandler ( "onPlayerQuit", getRootElement(),  
function () 
    if veh[source] and isElement( veh[source] ) then destroyElement( veh[source] )  
    veh[source] = nil  
    end 
end) 
  
function markerHit (hitPlayer, matchingDimension) 
if isPedInVehicle (hitPlayer) then return end 
if getElementType(hitPlayer) == "player" then 
    triggerClientEvent ("openMean2000", hitPlayer) 
end 
end 
  
addEventHandler ("onMarkerHit", resourceRoot, markerHit) 
  
function markerLeave (hitPlayer, matchingDimension) 
if getElementType(hitPlayer) == "player" then 
   triggerClientEvent ("closeopenMean2000", hitPlayer) 
end 
end 
addEventHandler ("onMarkerLeave", resourceRoot, markerLeave) 

وهداالوند

GUIEditor = { 
    gridlist = {}, 
    window = {}, 
    button = {} 
} 
  
cars = { 
    {523}, 
    {598}, 
    {597}, 
    {599}, 
  
  --{carID}, 
    } 
  
local l, w = guiGetScreenSize() 
GUIEditor.window[1111] = guiCreateWindow(231, 161, 256, 306, "[Gta-DARCK] Police Cars", false) 
guiWindowSetSizable(GUIEditor.window[1111], false) 
guiSetVisible(GUIEditor.window[1111],false) 
guiSetAlpha(GUIEditor.window[1111], 1.00) 
guiSetProperty(GUIEditor.window[1111], "CaptionColour", "FFFFFFFF") 
  
GUIEditor.gridlist[1000] = guiCreateGridList(9, 21, 237, 275, false, GUIEditor.window[1111]) 
guiGridListAddColumn(GUIEditor.gridlist[1000], "#", 0.4) 
guiGridListAddColumn(GUIEditor.gridlist[1000], "Vehicle", 0.4) 
GUIEditor.button[1001] = guiCreateButton(4, 255, 141, 15, "Spawn", false, GUIEditor.gridlist[1000]) 
GUIEditor.button[2002] = guiCreateButton(149, 255, 78, 15, "Close", false, GUIEditor.gridlist[1000]) 
  
for i,v in ipairs (cars) do 
    local carName = getVehicleNameFromModel (v[1]) 
    local row = guiGridListAddRow (GUIEditor.gridlist[1000]) 
    guiGridListSetItemText (GUIEditor.gridlist[1000], row, 1, i.."-", false, true) 
    guiGridListSetItemText (GUIEditor.gridlist[1000], row, 2, carName, false, true) 
    guiGridListSetItemColor(GUIEditor.gridlist[1000], row, 1, 255, 255, 255, 255) 
end 
  
addEvent ("openMean2000", true) 
function openMean2000 () 
if (getLocalPlayer() == source) then 
guiSetVisible(GUIEditor.window[1111],true) 
showCursor(true) 
end 
end 
addEventHandler ("openMean2000", getRootElement(), openMean2000) 
  
addEvent ("closeopenMean2000", true) 
function closeopenMean2000 () 
if (getLocalPlayer() == source) then 
guiSetVisible(GUIEditor.window[1111],false) 
showCursor(false) 
end 
end 
addEventHandler ("closeopenMean2000", getRootElement(), closeopenMean2000) 
  
addEventHandler ("onClientGUIClick", GUIEditor.button[2002], 
function (button, state, absoluteX, absoluteYe) 
 guiSetVisible(GUIEditor.window[1111],false) 
 showCursor(false) 
end) 
function trigger () 
if (guiGridListGetSelectedItem (GUIEditor.gridlist[1000])) then 
local car = guiGridListGetItemText (GUIEditor.gridlist[1000], guiGridListGetSelectedItem (GUIEditor.gridlist[1000]), 2) 
if car == "" or car == nil then outputChatBox( "oعليك ان تختار سيارةo",255,0,0,true ) return end 
  triggerServerEvent ("getCar", getLocalPlayer(), car) 
  guiSetVisible(GUIEditor.window[1111],false) 
  showCursor(false) 
end 
end 
  
addEventHandler ("onClientGUIClick", GUIEditor.button[1001], 
function (button, state, absoluteX, absoluteYe) 
trigger(getLocalPlayer()) 
end) 
  
addEventHandler ("onClientGUIDoubleClick", GUIEditor.gridlist[1000], 
function (button, state, absoluteX, absoluteYe) 
trigger(getLocalPlayer()) 
end) 

اتمني تجيدون لي حلا قريبا

Link to comment
-- Server Side ! 
  
markers = { 
    {1585.4683837891,-1677.7601318359,4.5}, 
    {1601.015625,-1709.9270019531,4.5}, 
    {1544.4505615234,-1645.6096191406,4.5}, 
    {1546.0128173828,-1609.8051757813,12.5}, 
    {1599.4171142578,-1610.4891357422,12.5}, 
    {1600.0526123047,-1627.7546386719,12.5}, 
  --{ x, y, z }, 
  } 
  
  
for i,v in ipairs (markers) do 
    marker = createMarker(v[1], v[2], v[3], "cylinder", get("markerSize"), get("markerColorR"), get("markerColorG"), get("markerColorB"), get("markerAlpha")) 
end 
  
veh = {} 
  
addEvent ("getCar", true) 
addEventHandler ("getCar", getRootElement(), 
function(car) 
    if veh[source] and isElement( veh[source] ) then destroyElement( veh[source] ) 
    veh[source] = nil 
    end 
    
end 
) 
  
addEventHandler ( "onPlayerQuit", getRootElement(), 
function () 
    if veh[source] and isElement( veh[source] ) then destroyElement( veh[source] ) 
    veh[source] = nil 
    end 
end) 
  
function markerHit (hitPlayer, matchingDimension) 
if isPedInVehicle (hitPlayer) then return end 
if getElementType(hitPlayer) == "player" then 
  if getPlayerTeam ( hitPlayer ) and getPlayerTeam ( hitPlayer ) == getTeamFromName ( "Police" ) then 
    triggerClientEvent ("openMean2000", hitPlayer) 
end 
end 
end 
addEventHandler ("onMarkerHit", resourceRoot, markerHit) 
  
function markerLeave (hitPlayer, matchingDimension) 
if getElementType(hitPlayer) == "player" then 
   triggerClientEvent ("closeopenMean2000", hitPlayer) 
end 
end 
addEventHandler ("onMarkerLeave", resourceRoot, markerLeave) 

Link to comment
-- Server Side ! 
  
markers = { 
    {1585.4683837891,-1677.7601318359,4.5}, 
    {1601.015625,-1709.9270019531,4.5}, 
    {1544.4505615234,-1645.6096191406,4.5}, 
    {1546.0128173828,-1609.8051757813,12.5}, 
    {1599.4171142578,-1610.4891357422,12.5}, 
    {1600.0526123047,-1627.7546386719,12.5}, 
  --{ x, y, z }, 
  } 
  
  
for i,v in ipairs (markers) do 
    marker = createMarker(v[1], v[2], v[3], "cylinder", get("markerSize"), get("markerColorR"), get("markerColorG"), get("markerColorB"), get("markerAlpha")) 
end 
  
veh = {} 
  
addEvent ("getCar", true) 
addEventHandler ("getCar", getRootElement(), 
function(car) 
    if veh[source] and isElement( veh[source] ) then destroyElement( veh[source] ) 
    veh[source] = nil 
    end 
    
end 
) 
  
addEventHandler ( "onPlayerQuit", getRootElement(), 
function () 
    if veh[source] and isElement( veh[source] ) then destroyElement( veh[source] ) 
    veh[source] = nil 
    end 
end) 
  
function markerHit (hitPlayer, matchingDimension) 
if isPedInVehicle (hitPlayer) then return end 
if getElementType(hitPlayer) == "player" then 
  if getPlayerTeam ( hitPlayer ) and getPlayerTeam ( hitPlayer ) == getTeamFromName ( "Police" ) then 
    triggerClientEvent ("openMean2000", hitPlayer) 
end 
end 
end 
addEventHandler ("onMarkerHit", resourceRoot, markerHit) 
  
function markerLeave (hitPlayer, matchingDimension) 
if getElementType(hitPlayer) == "player" then 
   triggerClientEvent ("closeopenMean2000", hitPlayer) 
end 
end 
addEventHandler ("onMarkerLeave", resourceRoot, markerLeave) 

كفؤؤؤؤؤؤ اخي شكرا علي المساعده تم التجربه ويعمل ميه علي ميه

Link to comment
-- Server Side ! 
  
markers = { 
    {1585.4683837891,-1677.7601318359,4.5}, 
    {1601.015625,-1709.9270019531,4.5}, 
    {1544.4505615234,-1645.6096191406,4.5}, 
    {1546.0128173828,-1609.8051757813,12.5}, 
    {1599.4171142578,-1610.4891357422,12.5}, 
    {1600.0526123047,-1627.7546386719,12.5}, 
  --{ x, y, z }, 
  } 
  
  
for i,v in ipairs (markers) do 
    marker = createMarker(v[1], v[2], v[3], "cylinder", get("markerSize"), get("markerColorR"), get("markerColorG"), get("markerColorB"), get("markerAlpha")) 
end 
  
veh = {} 
  
addEvent ("getCar", true) 
addEventHandler ("getCar", getRootElement(), 
function(car) 
    if veh[source] and isElement( veh[source] ) then destroyElement( veh[source] ) 
    veh[source] = nil 
    end 
    
end 
) 
  
addEventHandler ( "onPlayerQuit", getRootElement(), 
function () 
    if veh[source] and isElement( veh[source] ) then destroyElement( veh[source] ) 
    veh[source] = nil 
    end 
end) 
  
function markerHit (hitPlayer, matchingDimension) 
if isPedInVehicle (hitPlayer) then return end 
if getElementType(hitPlayer) == "player" then 
  if getPlayerTeam ( hitPlayer ) and getPlayerTeam ( hitPlayer ) == getTeamFromName ( "Police" ) then 
    triggerClientEvent ("openMean2000", hitPlayer) 
end 
end 
end 
addEventHandler ("onMarkerHit", resourceRoot, markerHit) 
  
function markerLeave (hitPlayer, matchingDimension) 
if getElementType(hitPlayer) == "player" then 
   triggerClientEvent ("closeopenMean2000", hitPlayer) 
end 
end 
addEventHandler ("onMarkerLeave", resourceRoot, markerLeave) 

كفؤؤؤؤؤؤ اخي شكرا علي المساعده تم التجربه ويعمل ميه علي ميه

العفو

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...