so if i want to make it work with get / set element data , i must to write :
client
addEventHandler("onPlayerLogin", root,
function()
bindKey(source, "n", "down", factionVehicle)
end)
addEventHandler("onResourceStart", root,
function()
for p, v in ipairs(getElementsByType("player")) do
bindKey(v, "n", "down", factionVehicle)
end
end)
function factionVehicle(thePlayer, theVehicle)
getElementData (theVehicle, "test")
triggerServerEvent ("test1", getLocalPlayer(), theVehicle)
end
end