Hello MTAsa Community i have a Prob and can't locate it :3
server side
local shopMakers = {
{x=-23.42, y=-55.26, z=1003.54, int=6, dim=1},
{x=-23.41, y=-55.37, z=1003.54, int=6, dim=0},
}
function TheMarkerof247Shop( player, matchingDim)
if ( matchingDim ) then
if ( isElement( player ) and getElementType( player ) == "player" ) then
if ( isPedInVehicle ( player ) == false ) then
triggerClientEvent( player, "247shop.CoolwindowOpen", player )
end
end
end
end
for _, v in pairs ( shopMakers ) do
local x, y, z, interior, dimension = v["x"], v["y"], v["z"], v["int"], v["dim"]
local shopMarker = createMarker( x, y, z -1,"cylinder", 1, 225, 225, 225 ,170)
setElementInterior( shopMarker, interior)
setElementDimension ( shopMarker, dimension )
addEventHandler( "onMarkerHit", shopMarker, TheMarkerof247Shop )
end
client-side
addEvent("247shop.CoolwindowOpen", true)
addEventHandler("247shop.CoolwindowOpen", localPlayer,
function ()
addEventHandler( "onClientRender", root, shop247 )
addEventHandler ( "onClientClick", root, shop247onClientClick )
showCursor( true )
end
)
The client side works 100% as i was test it with binkey the problem is in server side they just no trigger it all others works ok i mean they create the marker they se it to dim and int but no trigger and no any error