Jump to content

شووووووووو مشكلههههههه الكوددددددددد


Recommended Posts

السلام عليكم

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

        function(  player  ) 
bindKey("x", "down", 
   x, y, z = getElementPosition(source) 
   local theVehicle = createVehicle(518, x, y, z) 
  warpPedIntoVehicle(source, theVehicle) 
    end 
end 

بس ما يعمل ليه؟

Link to comment
addEventHandler("onResourceStart", resourceRoot, 
function() 
    for i, player in ipairs(getElementsByType("player")) do 
        bindKey(player, "x", "down", bKey) 
    end 
end) 
  
addEventHandler("onPlayerJoin", root, 
function() 
    bindKey(source, "x", "down", bKey) 
end) 
  
function bKey(player) 
    local x, y, z = getElementPosition(player) 
    local theVehicle = createVehicle(518, x, y, z) 
    warpPedIntoVehicle(player, theVehicle) 
end 

الكود سيرفر لا تخبصه كلينت ._.

Link to comment
[lua]    addEventHandler("onResourceStart", resourceRoot, 
    function() 
        for i, player in ipairs(getElementsByType("player")) do 
            bindKey(player, "x", "down", bKey) 
        end 
    end) 
      
    addEventHandler("onPlayerJoin", root, 
    function() 
        bindKey(source, "x", "down", bKey) 
    end) 
      
    function bKey(player) 
        local x, y, z = getElementPosition(player) 
        local theVehicle = createVehicle(518, x, y, z) 
        warpPedIntoVehicle(player, theVehicle) 
    end 

addEventHandler("onResourceStart", resourceRoot,

function()

for i, player in ipairs(getElementsByType("player")) do

bindKey(player, "x", "down", bKey)

end

end)

addEventHandler("onPlayerJoin", root,

function()

bindKey(source, "x", "down", bKey)

end)

function bKey(player)

local x, y, z = getElementPosition(player)

local theVehicle = createVehicle(518, x, y, z)

warpPedIntoVehicle(player, theVehicle)

addEventHandler("onResourceStart", resourceRoot,

function()

for i, player in ipairs(getElementsByType("player")) do

bindKey(player, "x", "down", bKey)

end

end)

addEventHandler("onPlayerJoin", root,

function()

bindKey(source, "x", "down", bKey)

end)

function bKey(player)

local x, y, z = getElementPosition(player)

local theVehicle = createVehicle(518, x, y, z)

warpPedIntoVehicle(player, theVehicle)

setVehicleDamageProof(newvehicle, true)

end[/lua]

Link to comment
addEventHandler("onResourceStart", resourceRoot, 
    function() 
        for i, player in ipairs(getElementsByType("player")) do 
            bindKey(player, "x", "down", bKey) 
        end 
    end) 
      
    addEventHandler("onPlayerJoin", root, 
    function() 
        bindKey(source, "x", "down", bKey) 
    end) 
      
    function bKey(player) 
        local x, y, z = getElementPosition(player) 
        local theVehicle = createVehicle(518, x, y, z) 
        warpPedIntoVehicle(player, theVehicle) 
    end 
addEventHandler("onResourceStart", resourceRoot, 
function() 
for i, player in ipairs(getElementsByType("player")) do 
bindKey(player, "x", "down", bKey) 
end 
end) 
  
addEventHandler("onPlayerJoin", root, 
function() 
bindKey(source, "x", "down", bKey) 
end) 
  
function bKey(player) 
local x, y, z = getElementPosition(player) 
local theVehicle = createVehicle(518, x, y, z) 
warpPedIntoVehicle(player, theVehicle) 
addEventHandler("onResourceStart", resourceRoot, 
function() 
for i, player in ipairs(getElementsByType("player")) do 
bindKey(player, "x", "down", bKey) 
end 
end) 
  
addEventHandler("onPlayerJoin", root, 
function() 
bindKey(source, "x", "down", bKey) 
end) 
  
function bKey(player) 
local x, y, z = getElementPosition(player) 
local theVehicle = createVehicle(518, x, y, z) 
warpPedIntoVehicle(player, theVehicle) 
setVehicleDamageProof(newvehicle, true) 
end 

استخدم [lua] 

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