Jump to content

edit .


Adham

Recommended Posts

تعديل اكواد

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

اول ما اخش السرفر ما تفتح

وحاطط الاكواد صح

كلنت !

        wnd = guiCreateWindow(584, 117, 212, 446, "لوحة الشرطي", false) 
        guiWindowSetSizable(wnd, false) 
        guiWindowSetMovable(wnd, false) 
        guiSetVisible(wnd, false) 
        putRight(wnd) 
        guiSetProperty(wnd, "CaptionColour", "ffffffff") 
  
        
        grid = guiCreateGridList(12, 29, 190, 192, false, wnd) 
        column = guiGridListAddColumn(grid, "اللاعبين", 0.9) 
        
        Search = guiCreateEdit(15, 232, 177, 25, "", false, wnd) 
        
        Spectate = guiCreateButton(15, 388, 177, 35, "مراقبه", false, wnd) 
        guiSetFont(Spectate, "default-bold-small") 
        guiSetProperty(Spectate, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Spectate, "HoverTextColour", "FFFFFF00") 
        Slap = guiCreateButton(15, 304, 177, 35, "سلاب", false, wnd) 
        guiSetFont(Slap, "default-bold-small") 
        guiSetProperty(Slap, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Slap, "HoverTextColour", "FFFFFF00") 
        Destroy = guiCreateButton(15, 343, 177, 35, "سحب المركبه", false, wnd) 
        guiSetFont(Destroy, "default-bold-small") 
        guiSetProperty(Destroy, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Destroy, "HoverTextColour", "FFFFFF00") 
        rButton = guiCreateButton(15, 263, 177, 35, "تحديث القائمه", false, wnd) 
        guiSetFont(rButton, "default-small") 
        guiSetProperty(rButton, "NormalTextColour", "FF00FF00") 
        guiSetProperty(rButton, "HoverTextColour", "FF00FF00")   
        
        
        
            
        
function strong ( ) 
guiSetVisible (wnd, true) 
showCursor (true) 
end 
addEvent( "openGui", true ) 
addEventHandler( "openGui",root,strong) 
  
bindKey( "M", "down", 
function() 
triggerServerEvent ( "check", localPlayer ) 
guiSetVisible ( wnd, not guiGetVisible ( wndName ) ) 
showCursor ( guiGetVisible ( wnd ) ) 
end) 
-- 
addEventHandler("onClientGUIClick",root, 
    function () 
        local sel = guiGridListGetSelectedItem(grid) 
        local text = guiGridListGetItemText(grid,sel,1) 
        if ( source == Spectate ) then 
            if ( sel ~= -1 ) then 
                setPlayerSep(getPlayerFromName(text)) 
            else 
                show("Please Choose Player To Spectator it") 
            end 
        elseif ( source == Slap ) then 
            if ( sel ~= -1 ) then 
                triggerServerEvent("killPlayer",localPlayer,text) 
            else 
                show("Please Choose Player To Kill it") 
            end 
        elseif ( source == Destroy ) then 
            if ( sel ~= -1 ) then 
                local player = getPlayerFromName(text) 
                if isPedInVehicle(player) then 
                    triggerServerEvent("onDes",localPlayer,text) 
                else 
                    show("This Player Don't Have Vehicle") 
                end 
            else 
                show("Please Choose Player To Destroy His Vehicle") 
            end 
        elseif ( source == GUIEditor_Button[4] ) then 
            if ( sel ~= -1 ) then 
                local player = getPlayerFromName(text) 
                if isPedInVehicle(player) then 
                    triggerServerEvent("onBlow",localPlayer,text) 
                else 
                    show("This Player Don't Have Vehicle") 
                end 
            else 
                show("Please Choose Player To Blow His Vehicle") 
            end 
        end 
    end 
) 

سرفر

-

addEvent("check",true) 
addEventHandler("check",root, 
function() 
local account = getPlayerAccount(client) 
if(isObjectInACLGroup("user."..getAccountName(account),aclGetGroup("Police"))) then 
triggerClientEvent(client,"openre",client) 
end 
end 
) 
  
  
addEventHandler( "onElementClicked",root, 
function ( x, y, z ) 
triggerClientEvent ( source, "openGui", source ) 
end 
-- 
  
addEvent("isPolice",true) 
addEventHandler("isPolice",root, 
    function () 
        if isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)),aclGetGroup("Police")) then 
            triggerClientEvent(source,"Yes",source) 
        end 
    end 
) 
  
addEvent("killPlayer",true) 
addEventHandler("killPlayer",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        if ( player ) then 
            killPed(player) 
            outputChatBox("* [ Police ] : The Player Killed Successfuly",source,0,255,0) 
            outputChatBox("* [ Police ] : You Are Killed By " .. getPlayerName(source),player,255,0,0) 
        end 
    end 
) 
  
  
addEvent("onDes",true) 
addEventHandler("onDes",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        local veh = getPedOccupiedVehicle(player) 
        destroyElement(veh) 
        outputChatBox("* [ Police ] : The Player Vehicle Successfuly Destoryed",source,0,255,0) 
        outputChatBox("* [ Police ] : Your Vehicle Destroy By " .. getPlayerName(source),player,255,0,0) 
    end 
) 
  
  
addEvent("onBlow",true) 
addEventHandler("onBlow",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        local veh = getPedOccupiedVehicle(player) 
        blowVehicle(veh) 
        outputChatBox("* [ Police ] : The Player Vehicle Successfuly Blowed",source,0,255,0) 
        outputChatBox("* [ Police ] : Your Vehicle Blow By " .. getPlayerName(source),player,255,0,0) 
    end 
) 
  
addEventHandler("onPlayerLogin",root, 
    function (_,acc) 
        if isObjectInACLGroup("user." .. getAccountName(acc),aclGetGroup("Police")) then 
            outputChatBox("* Welcome Police Man Press m To Open Police Panel",source,255,255,255,true) 
        end 
    end 
) 
  
addEventHandler("onResourceStart",resourceRoot, 
    function () 
        if not aclGetGroup("Police") then 
            outputChatBox("* Admin Please Add Group Name Police To Add Player in it To Be Police",root,255,0,0) 
        end 
    end 
) 
  
Link to comment
تعديل اكواد

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

اول ما اخش السرفر ما تفتح

وحاطط الاكواد صح

كلنت !

        wnd = guiCreateWindow(584, 117, 212, 446, "لوحة الشرطي", false) 
        guiWindowSetSizable(wnd, false) 
        guiWindowSetMovable(wnd, false) 
        guiSetVisible(wnd, false) 
        putRight(wnd) 
        guiSetProperty(wnd, "CaptionColour", "ffffffff") 
  
        
        grid = guiCreateGridList(12, 29, 190, 192, false, wnd) 
        column = guiGridListAddColumn(grid, "اللاعبين", 0.9) 
        
        Search = guiCreateEdit(15, 232, 177, 25, "", false, wnd) 
        
        Spectate = guiCreateButton(15, 388, 177, 35, "مراقبه", false, wnd) 
        guiSetFont(Spectate, "default-bold-small") 
        guiSetProperty(Spectate, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Spectate, "HoverTextColour", "FFFFFF00") 
        Slap = guiCreateButton(15, 304, 177, 35, "سلاب", false, wnd) 
        guiSetFont(Slap, "default-bold-small") 
        guiSetProperty(Slap, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Slap, "HoverTextColour", "FFFFFF00") 
        Destroy = guiCreateButton(15, 343, 177, 35, "سحب المركبه", false, wnd) 
        guiSetFont(Destroy, "default-bold-small") 
        guiSetProperty(Destroy, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Destroy, "HoverTextColour", "FFFFFF00") 
        rButton = guiCreateButton(15, 263, 177, 35, "تحديث القائمه", false, wnd) 
        guiSetFont(rButton, "default-small") 
        guiSetProperty(rButton, "NormalTextColour", "FF00FF00") 
        guiSetProperty(rButton, "HoverTextColour", "FF00FF00")   
        
        
        
            
        
function strong ( ) 
guiSetVisible (wnd, true) 
showCursor (true) 
end 
addEvent( "openGui", true ) 
addEventHandler( "openGui",root,strong) 
  
bindKey( "M", "down", 
function() 
triggerServerEvent ( "check", localPlayer ) 
guiSetVisible ( wnd, not guiGetVisible ( wndName ) ) 
showCursor ( guiGetVisible ( wnd ) ) 
end) 
-- 
addEventHandler("onClientGUIClick",root, 
    function () 
        local sel = guiGridListGetSelectedItem(grid) 
        local text = guiGridListGetItemText(grid,sel,1) 
        if ( source == Spectate ) then 
            if ( sel ~= -1 ) then 
                setPlayerSep(getPlayerFromName(text)) 
            else 
                show("Please Choose Player To Spectator it") 
            end 
        elseif ( source == Slap ) then 
            if ( sel ~= -1 ) then 
                triggerServerEvent("killPlayer",localPlayer,text) 
            else 
                show("Please Choose Player To Kill it") 
            end 
        elseif ( source == Destroy ) then 
            if ( sel ~= -1 ) then 
                local player = getPlayerFromName(text) 
                if isPedInVehicle(player) then 
                    triggerServerEvent("onDes",localPlayer,text) 
                else 
                    show("This Player Don't Have Vehicle") 
                end 
            else 
                show("Please Choose Player To Destroy His Vehicle") 
            end 
        elseif ( source == GUIEditor_Button[4] ) then 
            if ( sel ~= -1 ) then 
                local player = getPlayerFromName(text) 
                if isPedInVehicle(player) then 
                    triggerServerEvent("onBlow",localPlayer,text) 
                else 
                    show("This Player Don't Have Vehicle") 
                end 
            else 
                show("Please Choose Player To Blow His Vehicle") 
            end 
        end 
    end 
) 

سرفر

-

addEvent("check",true) 
addEventHandler("check",root, 
function() 
local account = getPlayerAccount(client) 
if(isObjectInACLGroup("user."..getAccountName(account),aclGetGroup("Police"))) then 
triggerClientEvent(client,"openre",client) 
end 
end 
) 
  
  
addEventHandler( "onElementClicked",root, 
function ( x, y, z ) 
triggerClientEvent ( source, "openGui", source ) 
end 
-- 
  
addEvent("isPolice",true) 
addEventHandler("isPolice",root, 
    function () 
        if isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)),aclGetGroup("Police")) then 
            triggerClientEvent(source,"Yes",source) 
        end 
    end 
) 
  
addEvent("killPlayer",true) 
addEventHandler("killPlayer",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        if ( player ) then 
            killPed(player) 
            outputChatBox("* [ Police ] : The Player Killed Successfuly",source,0,255,0) 
            outputChatBox("* [ Police ] : You Are Killed By " .. getPlayerName(source),player,255,0,0) 
        end 
    end 
) 
  
  
addEvent("onDes",true) 
addEventHandler("onDes",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        local veh = getPedOccupiedVehicle(player) 
        destroyElement(veh) 
        outputChatBox("* [ Police ] : The Player Vehicle Successfuly Destoryed",source,0,255,0) 
        outputChatBox("* [ Police ] : Your Vehicle Destroy By " .. getPlayerName(source),player,255,0,0) 
    end 
) 
  
  
addEvent("onBlow",true) 
addEventHandler("onBlow",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        local veh = getPedOccupiedVehicle(player) 
        blowVehicle(veh) 
        outputChatBox("* [ Police ] : The Player Vehicle Successfuly Blowed",source,0,255,0) 
        outputChatBox("* [ Police ] : Your Vehicle Blow By " .. getPlayerName(source),player,255,0,0) 
    end 
) 
  
addEventHandler("onPlayerLogin",root, 
    function (_,acc) 
        if isObjectInACLGroup("user." .. getAccountName(acc),aclGetGroup("Police")) then 
            outputChatBox("* Welcome Police Man Press m To Open Police Panel",source,255,255,255,true) 
        end 
    end 
) 
  
addEventHandler("onResourceStart",resourceRoot, 
    function () 
        if not aclGetGroup("Police") then 
            outputChatBox("* Admin Please Add Group Name Police To Add Player in it To Be Police",root,255,0,0) 
        end 
    end 
) 
  

انت تبي اول ما يخش الي سيرفر لاعب تفتح لوحه و لا بزر ولا كيف

Link to comment
        wnd = guiCreateWindow(584, 117, 212, 446, "لوحة الشرطي", false) 
        guiWindowSetSizable(wnd, false) 
        guiWindowSetMovable(wnd, false) 
        guiSetVisible(wnd, false) 
        putRight(wnd) 
        guiSetProperty(wnd, "CaptionColour", "ffffffff") 
  
        
        grid = guiCreateGridList(12, 29, 190, 192, false, wnd) 
        column = guiGridListAddColumn(grid, "اللاعبين", 0.9) 
        
        Search = guiCreateEdit(15, 232, 177, 25, "", false, wnd) 
        
        Spectate = guiCreateButton(15, 388, 177, 35, "مراقبه", false, wnd) 
        guiSetFont(Spectate, "default-bold-small") 
        guiSetProperty(Spectate, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Spectate, "HoverTextColour", "FFFFFF00") 
        Slap = guiCreateButton(15, 304, 177, 35, "سلاب", false, wnd) 
        guiSetFont(Slap, "default-bold-small") 
        guiSetProperty(Slap, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Slap, "HoverTextColour", "FFFFFF00") 
        Destroy = guiCreateButton(15, 343, 177, 35, "سحب المركبه", false, wnd) 
        guiSetFont(Destroy, "default-bold-small") 
        guiSetProperty(Destroy, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Destroy, "HoverTextColour", "FFFFFF00") 
        rButton = guiCreateButton(15, 263, 177, 35, "تحديث القائمه", false, wnd) 
        guiSetFont(rButton, "default-small") 
        guiSetProperty(rButton, "NormalTextColour", "FF00FF00") 
        guiSetProperty(rButton, "HoverTextColour", "FF00FF00")   
        
        
        
            
        
function ss () 
guiSetVisible (wnd, not guiGetVisible ( wnd )) 
showCursor ( guiGetVisible ( wnd ) ) 
end 
addEvent( "mezo", true ) 
addEventHandler( "mezo",root,ss) 
  
bindKey( "M", "down", 
function() 
triggerServerEvent ( "check", localPlayer ) 
end) 
-- 
addEventHandler("onClientGUIClick",root, 
    function () 
        local sel = guiGridListGetSelectedItem(grid) 
        local text = guiGridListGetItemText(grid,sel,1) 
        if ( source == Spectate ) then 
            if ( sel ~= -1 ) then 
                setPlayerSep(getPlayerFromName(text)) 
            else 
                show("Please Choose Player To Spectator it") 
            end 
        elseif ( source == Slap ) then 
            if ( sel ~= -1 ) then 
                triggerServerEvent("killPlayer",localPlayer,text) 
            else 
                show("Please Choose Player To Kill it") 
            end 
        elseif ( source == Destroy ) then 
            if ( sel ~= -1 ) then 
                local player = getPlayerFromName(text) 
                if isPedInVehicle(player) then 
                    triggerServerEvent("onDes",localPlayer,text) 
                else 
                    show("This Player Don't Have Vehicle") 
                end 
            else 
                show("Please Choose Player To Destroy His Vehicle") 
            end 
        elseif ( source == GUIEditor_Button[4] ) then 
            if ( sel ~= -1 ) then 
                local player = getPlayerFromName(text) 
                if isPedInVehicle(player) then 
                    triggerServerEvent("onBlow",localPlayer,text) 
                else 
                    show("This Player Don't Have Vehicle") 
                end 
            else 
                show("Please Choose Player To Blow His Vehicle") 
            end 
        end 
    end 
) 

سرفر

-

addEvent("check",true) 
addEventHandler("check",root, 
function(p) 
local account = getPlayerAccount(p) 
if(isObjectInACLGroup("user."..getAccountName(account),aclGetGroup("Police"))) then 
triggerClientEvent(p,"mezo " p) 
end 
end) 
-- 
  
addEvent("killPlayer",true) 
addEventHandler("killPlayer",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        if ( player ) then 
            killPed(player) 
            outputChatBox("* [ Police ] : The Player Killed Successfuly",source,0,255,0) 
            outputChatBox("* [ Police ] : You Are Killed By " .. getPlayerName(source),player,255,0,0) 
        end 
    end 
) 
  
  
addEvent("onDes",true) 
addEventHandler("onDes",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        local veh = getPedOccupiedVehicle(player) 
        destroyElement(veh) 
        outputChatBox("* [ Police ] : The Player Vehicle Successfuly Destoryed",source,0,255,0) 
        outputChatBox("* [ Police ] : Your Vehicle Destroy By " .. getPlayerName(source),player,255,0,0) 
    end 
) 
  
  
addEvent("onBlow",true) 
addEventHandler("onBlow",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        local veh = getPedOccupiedVehicle(player) 
        blowVehicle(veh) 
        outputChatBox("* [ Police ] : The Player Vehicle Successfuly Blowed",source,0,255,0) 
        outputChatBox("* [ Police ] : Your Vehicle Blow By " .. getPlayerName(source),player,255,0,0) 
    end 
) 
  
addEventHandler("onPlayerLogin",root, 
    function (_,acc) 
        if isObjectInACLGroup("user." .. getAccountName(acc),aclGetGroup("Police")) then 
            outputChatBox("* Welcome Police Man Press m To Open Police Panel",source,255,255,255,true) 
        end 
    end 
) 
  
addEventHandler("onResourceStart",resourceRoot, 
    function () 
        if not aclGetGroup("Police") then 
            outputChatBox("* Admin Please Add Group Name Police To Add Player in it To Be Police",root,255,0,0) 
        end 
    end 
) 
  

جرب

Link to comment
تعديل اكواد

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

اول ما اخش السرفر ما تفتح

وحاطط الاكواد صح

كلنت !

        wnd = guiCreateWindow(584, 117, 212, 446, "لوحة الشرطي", false) 
        guiWindowSetSizable(wnd, false) 
        guiWindowSetMovable(wnd, false) 
        guiSetVisible(wnd, false) 
        putRight(wnd) 
        guiSetProperty(wnd, "CaptionColour", "ffffffff") 
  
        
        grid = guiCreateGridList(12, 29, 190, 192, false, wnd) 
        column = guiGridListAddColumn(grid, "اللاعبين", 0.9) 
        
        Search = guiCreateEdit(15, 232, 177, 25, "", false, wnd) 
        
        Spectate = guiCreateButton(15, 388, 177, 35, "مراقبه", false, wnd) 
        guiSetFont(Spectate, "default-bold-small") 
        guiSetProperty(Spectate, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Spectate, "HoverTextColour", "FFFFFF00") 
        Slap = guiCreateButton(15, 304, 177, 35, "سلاب", false, wnd) 
        guiSetFont(Slap, "default-bold-small") 
        guiSetProperty(Slap, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Slap, "HoverTextColour", "FFFFFF00") 
        Destroy = guiCreateButton(15, 343, 177, 35, "سحب المركبه", false, wnd) 
        guiSetFont(Destroy, "default-bold-small") 
        guiSetProperty(Destroy, "NormalTextColour", "FFFFFF00") 
        guiSetProperty(Destroy, "HoverTextColour", "FFFFFF00") 
        rButton = guiCreateButton(15, 263, 177, 35, "تحديث القائمه", false, wnd) 
        guiSetFont(rButton, "default-small") 
        guiSetProperty(rButton, "NormalTextColour", "FF00FF00") 
        guiSetProperty(rButton, "HoverTextColour", "FF00FF00")   
        
        
        
            
        
function strong ( ) 
guiSetVisible (wnd, true) 
showCursor (true) 
end 
addEvent( "openGui", true ) 
addEventHandler( "openGui",root,strong) 
  
bindKey( "M", "down", 
function() 
triggerServerEvent ( "check", localPlayer ) 
guiSetVisible ( wnd, not guiGetVisible ( wndName ) ) 
showCursor ( guiGetVisible ( wnd ) ) 
end) 
-- 
addEventHandler("onClientGUIClick",root, 
    function () 
        local sel = guiGridListGetSelectedItem(grid) 
        local text = guiGridListGetItemText(grid,sel,1) 
        if ( source == Spectate ) then 
            if ( sel ~= -1 ) then 
                setPlayerSep(getPlayerFromName(text)) 
            else 
                show("Please Choose Player To Spectator it") 
            end 
        elseif ( source == Slap ) then 
            if ( sel ~= -1 ) then 
                triggerServerEvent("killPlayer",localPlayer,text) 
            else 
                show("Please Choose Player To Kill it") 
            end 
        elseif ( source == Destroy ) then 
            if ( sel ~= -1 ) then 
                local player = getPlayerFromName(text) 
                if isPedInVehicle(player) then 
                    triggerServerEvent("onDes",localPlayer,text) 
                else 
                    show("This Player Don't Have Vehicle") 
                end 
            else 
                show("Please Choose Player To Destroy His Vehicle") 
            end 
        elseif ( source == GUIEditor_Button[4] ) then 
            if ( sel ~= -1 ) then 
                local player = getPlayerFromName(text) 
                if isPedInVehicle(player) then 
                    triggerServerEvent("onBlow",localPlayer,text) 
                else 
                    show("This Player Don't Have Vehicle") 
                end 
            else 
                show("Please Choose Player To Blow His Vehicle") 
            end 
        end 
    end 
) 

سرفر

-

addEvent("check",true) 
addEventHandler("check",root, 
function() 
local account = getPlayerAccount(client) 
if(isObjectInACLGroup("user."..getAccountName(account),aclGetGroup("Police"))) then 
triggerClientEvent(client,"openre",client) 
end 
end 
) 
  
  
addEventHandler( "onElementClicked",root, 
function ( x, y, z ) 
triggerClientEvent ( source, "openGui", source ) 
end 
-- 
  
addEvent("isPolice",true) 
addEventHandler("isPolice",root, 
    function () 
        if isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)),aclGetGroup("Police")) then 
            triggerClientEvent(source,"Yes",source) 
        end 
    end 
) 
  
addEvent("killPlayer",true) 
addEventHandler("killPlayer",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        if ( player ) then 
            killPed(player) 
            outputChatBox("* [ Police ] : The Player Killed Successfuly",source,0,255,0) 
            outputChatBox("* [ Police ] : You Are Killed By " .. getPlayerName(source),player,255,0,0) 
        end 
    end 
) 
  
  
addEvent("onDes",true) 
addEventHandler("onDes",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        local veh = getPedOccupiedVehicle(player) 
        destroyElement(veh) 
        outputChatBox("* [ Police ] : The Player Vehicle Successfuly Destoryed",source,0,255,0) 
        outputChatBox("* [ Police ] : Your Vehicle Destroy By " .. getPlayerName(source),player,255,0,0) 
    end 
) 
  
  
addEvent("onBlow",true) 
addEventHandler("onBlow",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        local veh = getPedOccupiedVehicle(player) 
        blowVehicle(veh) 
        outputChatBox("* [ Police ] : The Player Vehicle Successfuly Blowed",source,0,255,0) 
        outputChatBox("* [ Police ] : Your Vehicle Blow By " .. getPlayerName(source),player,255,0,0) 
    end 
) 
  
addEventHandler("onPlayerLogin",root, 
    function (_,acc) 
        if isObjectInACLGroup("user." .. getAccountName(acc),aclGetGroup("Police")) then 
            outputChatBox("* Welcome Police Man Press m To Open Police Panel",source,255,255,255,true) 
        end 
    end 
) 
  
addEventHandler("onResourceStart",resourceRoot, 
    function () 
        if not aclGetGroup("Police") then 
            outputChatBox("* Admin Please Add Group Name Police To Add Player in it To Be Police",root,255,0,0) 
        end 
    end 
) 
  

addEvent("check",true) 
addEventHandler("check",root, 
function() 
local account = getPlayerAccount(client) 
if(isObjectInACLGroup("user."..getAccountName(account),aclGetGroup("Police"))) then 
triggerClientEvent(client,"openre",client) 
end 
end 
) 
  
  
addEventHandler( "onElementClicked",root, 
function ( x, y, z ) 
triggerClientEvent ( source, "openGui", source ) 
end 
-- 
  
addEvent("isPolice",true) 
addEventHandler("isPolice",root, 
    function () 
        if isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)),aclGetGroup("Police")) then 
            triggerClientEvent(source,"Yes",source) 
        end 
    end 
) 
  
addEvent("killPlayer",true) 
addEventHandler("killPlayer",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        if ( player ) then 
            killPed(player) 
            outputChatBox("* [ Police ] : The Player Killed Successfuly",source,0,255,0) 
            outputChatBox("* [ Police ] : You Are Killed By " .. getPlayerName(source),player,255,0,0) 
        end 
    end 
) 
  
  
addEvent("onDes",true) 
addEventHandler("onDes",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        local veh = getPedOccupiedVehicle(player) 
        destroyElement(veh) 
        outputChatBox("* [ Police ] : The Player Vehicle Successfuly Destoryed",source,0,255,0) 
        outputChatBox("* [ Police ] : Your Vehicle Destroy By " .. getPlayerName(source),player,255,0,0) 
    end 
) 
  
  
addEvent("onBlow",true) 
addEventHandler("onBlow",root, 
    function (player) 
        local player = getPlayerFromName(player) 
        local veh = getPedOccupiedVehicle(player) 
        blowVehicle(veh) 
        outputChatBox("* [ Police ] : The Player Vehicle Successfuly Blowed",source,0,255,0) 
        outputChatBox("* [ Police ] : Your Vehicle Blow By " .. getPlayerName(source),player,255,0,0) 
    end 
) 
  
addEventHandler("onPlayerLogin",root, 
    function () 
       local acc = getAccountName(getPlayerAccount(source)) 
        if isObjectInACLGroup ( "user."..acc, aclGetGroup("Police")) then 
       outputChatBox("* Welcome Police Man Press m To Open Police Panel",source,255,255,255,true) 
        end 
    end 
) 
  
addEventHandler("onResourceStart",resourceRoot, 
    function () 
        if not aclGetGroup("Police") then 
            outputChatBox("* Admin Please Add Group Name Police To Add Player in it To Be Police",root,255,0,0) 
        end 
    end 
) 
  
Link to comment

  
addEventHandler( "onElementClicked",root, 
function ( x, y, z ) 
triggerClientEvent ( source, "openGui", source ) 
end 
  

وكيف تعرف ان اللى ضغط عليه لاعب او سياره ؟

مش انا الي عامل هيك هو الي عامل الكود ده

انا صلحت لو الي

onPlayerLogin +

addEventHandler( "onElementClicked",root, 
function ( x, y, z, Player) 
if getElementType(source) == "player" then 
triggerClientEvent (  Player, "openGui", Player ) 
    end 
end) 

+ الحين انتا تبي اللوحة تفتح لمين

لو تباها تفتح لللاعب الي اتضغط عليه

خلي بدل

Player

source

فلتريقر

Link to comment
انا فوق ظبطله الكود عي

بند كي

وش يبي هو؟

ابي اليضعط حرف m

يطلع له اشاره الهيا ( الماوس ) يشاور علي لاعب يطلع له لوحه #

كلامه واضح هو عايز يظهر السهم من حرف ال ة ولو ضغط على اللاعب بالسهم تظهر لوحه

Link to comment

يعرف الPlayer سيارة او اوبجيكت ؟ :!:

سوي and وتحقق ان السورس والبلاير

المنت ﻻعب

addEventHandler( "onElementClicked",root, 
function ( x, y, z, Player) 
if getElementType(source) and getElementType(Player) == "player" then 
triggerClientEvent (  Player, "openGui", Player ) 
    end 
end) 
Link to comment
يعرف الPlayer سيارة او اوبجيكت ؟ :!:

سوي and وتحقق ان السورس والبلاير

المنت ﻻعب

addEventHandler( "onElementClicked",root, 
function ( x, y, z, Player) 
if getElementType(source) and getElementType(Player) == "player" then 
triggerClientEvent (  Player, "openGui", Player ) 
    end 
end) 

يعني يجي اوبجكت ويضغط على الاعب ؟

:cry:

Link to comment
يعرف الPlayer سيارة او اوبجيكت ؟ :!:

سوي and وتحقق ان السورس والبلاير

المنت ﻻعب

addEventHandler( "onElementClicked",root, 
function ( x, y, z, Player) 
if getElementType(source) and getElementType(Player) == "player" then 
triggerClientEvent (  Player, "openGui", Player ) 
    end 
end) 

يعني يجي اوبجكت ويضغط على الاعب ؟

:cry:

لو اللا عب ضغط علي اوبجيكت

تفتح اللوحة للاوبجيكت ؟؟

:cry:

Link to comment

السلام عليكم اخواني انتو مش فاهمين قصده هو يبي يسويها زي طاره يعني لما يضغط m

يصير m بايند كاي للماوس

طيب

ولما يضغط بالماوس على اي لاعب

يطلعله

اللوحه الخاصه بالشرطي بس يقدر يتحكم في اللاعب اللي ضغط عليه بس يعني لو يسويله سلاب يسويله اي شي بس في

اللاعب اللي ضغط عليه هذا قصده زي لوحة الشرطي حقت طاره هو ما يبي الجريد لست اصلا

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...