aL.Kfo Posted September 30, 2013 Share Posted September 30, 2013 مرحبا شباب عندي كود ماركر بس مشكلته انةةة لقروب مخصص لزم تكتب اسم القروب عشان يفتح لهم لسته السيارات ابيه يكون للكل الاكواد markerpv = createMarker( 1566.9652099609, -1610.640625, 12.3828125, "cylinder", 2, 0, 0, 255, 255 ) local vehicles = {} function spawnVehp(id) local x, y, z = getElementPosition(source) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end vehicles[source] = createVehicle(id, x + 2, y, z) warpPedIntoVehicle(source, vehicles[source]) end addEvent("CreVehicePv",true) addEventHandler("CreVehicePv", root, spawnVehp) addEventHandler("onPlayerQuit", root, function() if isElement(vehicles[source]) then destroyElement(vehicles[source]) vehicles[source] = nil end end) function showGUIpv(hitPlayer) if hitPlayer and getElementType(hitPlayer) == "player" then if ( getPlayerTeam ( hitPlayer ) == getTeamFromName ( "11111" ) ) then triggerClientEvent (hitPlayer,"showGUIpv",getRootElement(),hitPlayer) else warnText("vehicles for 11111 only!",hitPlayer) end end end addEventHandler("onMarkerHit",markerpv,showGUIpv) اسم القروب 11111 Link to comment
فاّرس Posted September 30, 2013 Share Posted September 30, 2013 local markerpv = createMarker( 1566.9652099609, -1610.640625, 12.3828125, "cylinder", 2, 0, 0, 255, 255 ) local vehicles = {} function spawnVehp(id) local x, y, z = getElementPosition(source) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end vehicles[source] = createVehicle(id, x + 2, y, z) warpPedIntoVehicle(source, vehicles[source]) end addEvent("CreVehicePv",true) addEventHandler("CreVehicePv", root, spawnVehp) addEventHandler("onPlayerQuit", root,function() if isElement(vehicles[source]) then destroyElement(vehicles[source]) vehicles[source] = nil end end ) function showGUIpv(hitPlayer) if getElementType(hitPlayer) == "player" then triggerClientEvent ("showGUIpv",root) end end addEventHandler("onMarkerHit",markerpv,showGUIpv) تبي النافذه للكل ولا للي لمس الماركر؟ اذا للي لمس الماركر حط الكود كلنت وريح نفسك احسن من تريقر وشغله ذذ ^ الكود اذا لمست الماركر تنفتح اللوحه للكل , Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 local markerpv = createMarker( 1566.9652099609, -1610.640625, 12.3828125, "cylinder", 2, 0, 0, 255, 255 ) local vehicles = {} function spawnVehp(id) local x, y, z = getElementPosition(source) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end vehicles[source] = createVehicle(id, x + 2, y, z) warpPedIntoVehicle(source, vehicles[source]) end addEvent("CreVehicePv",true) addEventHandler("CreVehicePv", root, spawnVehp) addEventHandler("onPlayerQuit", root,function() if isElement(vehicles[source]) then destroyElement(vehicles[source]) vehicles[source] = nil end end ) function showGUIpv(hitPlayer) if getElementType(hitPlayer) == "player" then triggerClientEvent (root,"showGUIpv",root) end end addEventHandler("onMarkerHit",markerpv,showGUIpv) تبي النافذه للكل ولا للي لمس الماركر؟ اذا للي لمس الماركر حط الكود كلنت وريح نفسك احسن من تريقر وشغله ذذ ^ الكود اذا لمست الماركر تنفتح اللوحه للكل , لا هنت ي بعد حيي ضبط بس استفسار بسيط هل اقدر اغير اتجاه السياره لا نزلها لاعب من الماركر يعني اول ما تنزل اخلي الوجهيه من الحهه الاي ابي و اقدر اضيف مثلا 5 ماركرات احط فوق 5 احداث بس المشكله لا رحت ل ماركر و نزلت سياره تنزل لي 5 ع حسب عدد الماركرات Link to comment
فاّرس Posted September 30, 2013 Share Posted September 30, 2013 اكيد تقدر , لو تلاحظ في ارقومنتات للاتجاه, vehicle createVehicle ( int model, float x, float y, float z [, float rx, float ry, float rz, string numberplate, bool bDirection, int variant1, int variant2 ] ) rx,ry,rz < حق الاتجاه ذذ Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 طيب حلو حلو بس فيه طريقه اضيف 5 ماركرات سيارات بدون م يكون فيه تواصل مع الماركرات الاي قبل لين لو حطيت 5 ماركرات ب السيرفر و رحت ل اي ماركر و نزلت سياره تنزل لي 5 لو حطيت ماركر واحد تنزل لي سياره وحده صراحه فكرت احط كل كود في مجلد مضغوط لحاله بس كثيرر Link to comment
فاّرس Posted September 30, 2013 Share Posted September 30, 2013 سوي جدول ماركرات واستخدم لوب واذا لمس اي ماركر اكيد تنزل سياره وحده , Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 سوي جدول ماركرات واستخدم لوب واذا لمس اي ماركر اكيد تنزل سياره وحده , م فهمتك مره بس قصدكك اسوي هيكك local markerpv = createMarker1( 1721.6893310547,-1607.6824951172,13.546875, "cylinder", 2, 0, 0, 255, 255 ) local markerpv = createMarker2( 1721.6893310547,-1607.6824951172,13.546875, "cylinder", 2, 0, 0, 255, 255 ) local markerpv = createMarker3( 1721.6893310547,-1607.6824951172,13.546875, "cylinder", 2, 0, 0, 255, 255 ) local markerpv = createMarker4( 1721.6893310547,-1607.6824951172,13.546875, "cylinder", 2, 0, 0, 255, 255 ) طيب لو احذف الاي فوق و احط بداله ذي و اعدل الاحداث و الخ يضبط GUIEditor_Marker[1] = createMarker( 1721.4497070313,-1606.8637695313,13.546875, 'cylinder', 1.5, 4, 247, 250, 255 ) GUIEditor_Marker[2] = createMarker( 3181, 1070.4000244141, 32.799999237061, 'cylinder', 1.5, 4, 247, 250, 255 ) GUIEditor_Marker[3] = createMarker( 3175.1999511719, 1070.4000244141, 32.799999237061, 'cylinder', 1.5, 4, 247, 250, 255 ) GUIEditor_Marker[4] = createMarker( 3169.1999511719, 1070.5999755859, 32.799999237061, 'cylinder', 1.5, 4, 247, 250, 255 ) Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 خلاصصص تمت الافاده لا هنت ي بعدي ع التفاعل بس والله غريبه منتدى MTA الرسمي و مافيه نشاط Link to comment
فاّرس Posted September 30, 2013 Share Posted September 30, 2013 ^ تسوي كذا مشوار , جرب سوي كذا, markers = { {x,y,z}, {x,y,z}, {x,y,z} } addEventHandler('onResourceStart',resourceRoot,function() for k,v in ipairs(markers) do marker = createMarker(v[1],v[2],v[3],'cylinder',3,255,255,175,170) end end ) Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 سويت هيككك صار الماركرات تطلع بس لا خشيت م تطلع لوحه السياارت markers = { {2508.953125,-1672.2054443359,13.381790161133}, {2497.9853515625,-1672.5334472656,13.34220790863}, {2495.8220214844,-1682.44921875,13.347380638123} } addEventHandler('onResourceStart',resourceRoot,function() for k,v in ipairs(markers) do marker = createMarker(v[1],v[2],v[3],'cylinder',3,255,255,175,170) end end ) local vehicles = {} function spawnVehp(id) local x, y, z = getElementPosition(source) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end vehicles[source] = createVehicle(id, x + 2, y, z) warpPedIntoVehicle(source, vehicles[source]) end addEvent("CreVehicePv",true) addEventHandler("CreVehicePv", root, spawnVehp) addEventHandler("onPlayerQuit", root,function() if isElement(vehicles[source]) then destroyElement(vehicles[source]) vehicles[source] = nil end end ) function showGUIpv(hitPlayer) if getElementType(hitPlayer) == "player" then triggerClientEvent ("showGUIpv",root) end end addEventHandler("onMarkerHit",markerpv,showGUIpv) وقلت خل اجرب قبل اطرح المشكله سويت هيكك حطيت في المستند كودك markers = { {x,y,z}, {x,y,z}, {x,y,z} } addEventHandler('onResourceStart',resourceRoot,function() for k,v in ipairs(markers) do marker = createMarker(v[1],v[2],v[3],'cylinder',3,255,255,175,170) end end ) نفس الشي تطلع ماركرات بدون لوحه Link to comment
فاّرس Posted September 30, 2013 Share Posted September 30, 2013 markers = { {2508.953125,-1672.2054443359,13.381790161133}, {2497.9853515625,-1672.5334472656,13.34220790863}, {2495.8220214844,-1682.44921875,13.347380638123} } addEventHandler('onResourceStart',resourceRoot,function() for k,v in ipairs(markers) do createMarker(v[1],v[2],v[3],'cylinder',3,255,255,175,170) end end ) local vehicles = {} addEvent('CreVehicePv',true) addEventHandler('CreVehicePv', root , function(id) local x, y, z = getElementPosition(source) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end vehicles[source] = createVehicle(id, x + 2, y, z) warpPedIntoVehicle(source, vehicles[source]) end ) addEventHandler('onPlayerQuit', root,function() if isElement(vehicles[source]) then destroyElement(vehicles[source]) vehicles[source] = nil end end ) addEventHandler('onMarkerHit',resourceRoot,function(hitPlayer) if getElementType(hitPlayer) == 'player' then triggerClientEvent ('showGUIpv',root) end end ) Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 markers = { {2508.953125,-1672.2054443359,13.381790161133}, {2497.9853515625,-1672.5334472656,13.34220790863}, {2495.8220214844,-1682.44921875,13.347380638123} } addEventHandler('onResourceStart',resourceRoot,function() for k,v in ipairs(markers) do createMarker(v[1],v[2],v[3],'cylinder',3,255,255,175,170) end end ) local vehicles = {} addEvent('CreVehicePv',true) addEventHandler('CreVehicePv', root , function(id) local x, y, z = getElementPosition(source) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end vehicles[source] = createVehicle(id, x + 2, y, z) warpPedIntoVehicle(source, vehicles[source]) end ) addEventHandler('onPlayerQuit', root,function() if isElement(vehicles[source]) then destroyElement(vehicles[source]) vehicles[source] = nil end end ) addEventHandler('onMarkerHit',resourceRoot,function(hitPlayer) if getElementType(hitPlayer) == 'player' then triggerClientEvent ('showGUIpv',root) end end ) ضبط و زي العسل ي عسل الكيبورد يعجز عن التعبير عن مجخودك هه تممت الافاده برب اشوف شش الفرق بين الاي عدلت انت و الاي عدلت عشان نفهم بعدين Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 باكككك لا سويت هيكك markers = { {2472.0881347656,-1688.6563720703,13.5078125}, {2228.4409179688,-1167.3218994141,25.747329711914}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, } addEventHandler('onResourceStart',resourceRoot,function() for k,v in ipairs(markers) do createMarker(v[1],v[2],v[3],'cylinder',3,255,255,175,170) end end ) local vehicles = {} addEvent('CreVehicePv',true) addEventHandler('CreVehicePv', root , function(id) local x, y, z = getElementPosition(source) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end vehicles[source] = createVehicle(id, x + 2, y, z) warpPedIntoVehicle(source, vehicles[source]) end ) addEventHandler('onPlayerQuit', root,function() if isElement(vehicles[source]) then destroyElement(vehicles[source]) vehicles[source] = nil end end ) addEventHandler('onMarkerHit',resourceRoot,function(hitPlayer) if getElementType(hitPlayer) == 'player' then triggerClientEvent ('showGUIpv',root) end end ) لا اضفت اكثر من 3 احداث الكود يخرب لزم بس 3 انا ابي كل م طقت براسي حطيت سطر احداث زياده بس ذا م يقبل الا 3 وش الحل Link to comment
فاّرس Posted September 30, 2013 Share Posted September 30, 2013 markers = { {2472.0881347656,-1688.6563720703,13.5078125}, {2228.4409179688,-1167.3218994141,25.747329711914}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875} } دائما آخر سطر خليه بدون فاصله , Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 markers = { {2472.0881347656,-1688.6563720703,13.5078125}, {2228.4409179688,-1167.3218994141,25.747329711914}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875} } دائما آخر سطر خليه بدون فاصله , اهاا كويس جاري التجربه Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 markers = { {2472.0881347656,-1688.6563720703,13.5078125}, {2228.4409179688,-1167.3218994141,25.747329711914}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875}, {1719.2711181641,-1607.2225341797,13.546875} } دائما آخر سطر خليه بدون فاصله , اهاا كويس جاري التجربه ضبط تمام التمام بس م فيه طريقه اخلي الماركر متساوي مع الارض كتبت -1 ك العاده بس م ضبط مو مهم مره بس يعني عشان الشكل افضل Link to comment
iPrestege Posted September 30, 2013 Share Posted September 30, 2013 اطرح كامل الكود . Link to comment
فاّرس Posted September 30, 2013 Share Posted September 30, 2013 جرب نقص 2-؟ -2 or -3 or... Link to comment
G.KinG Posted September 30, 2013 Share Posted September 30, 2013 تبي تخليه على الارض الماركر سهله ذي انا اقول لك كيف markers = { {2472.0881347656,-1688.6563720703,13.5078125}, } تاخذ اخر عدد الي هو markers = { {13.5078125}, } وتحوله زي كذا markers = { {12.5078125}, } لو تلاحظ الفرق شوف 13 , 12 يسير زي كذا markers = { {2472.0881347656,-1688.6563720703,12.5078125}, } موفق .. Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 ذا بست جربتها م ضبط كنق طريفتك اخفت الماركر برسستيج ذا الكود + ذا بست markers = { {2472.0881347656,-1688.6563720703,13.5078125}, {2228.4409179688,-1167.3218994141,25.747329711914}, {1719.2711181641,-1607.2225341797,13.546875}, {1506.5936279297,-1749.0170898438,13.546875}, {1220.3937988281,-1734.4114990234,13.580118179321}, {1144.107421875,-1292.6887207031,13.616773605347}, {666.86676025391,-1281.0958251953,13.4609375}, {1422.1994628906,-1136.7351074219,23.954034805298}, {1427.0316162109,-1046.7501220703,23.743759155273}, {1796.4952392578,-1439.7015380859,13.422317504883}, {987.70751953125,-1227.5476074219,16.922908782959}, {1944.8569335937,-1368.2105712891,18.578125} } addEventHandler('onResourceStart',resourceRoot,function() for k,v in ipairs(markers) do createMarker(v[1],v[2],v[3],'cylinder',3,255,255,175,170) end end ) local vehicles = {} addEvent('CreVehicePv',true) addEventHandler('CreVehicePv', root , function(id) local x, y, z = getElementPosition(source) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end vehicles[source] = createVehicle(id, x + 2, y, z) warpPedIntoVehicle(source, vehicles[source]) end ) addEventHandler('onPlayerQuit', root,function() if isElement(vehicles[source]) then destroyElement(vehicles[source]) vehicles[source] = nil end end ) addEventHandler('onMarkerHit',resourceRoot,function(hitPlayer) if getElementType(hitPlayer) == 'player' then triggerClientEvent ('showGUIpv',root) end end ) هذا هو الكود م اقدر اغير اتجاك السياره صح ضيف عليه كود تغيير اتجاه السياره لا هنت Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 ^^ذا بست امممممم الكود لا واحد خش للماركر و طلعت له الوحه تطلع لكل الاي ب السيرفر ^^ Link to comment
فاّرس Posted September 30, 2013 Share Posted September 30, 2013 مو انت قلت لكل السيرفر؟ خليته للي لمس الماركر بس ذذ , وجرب الماركر شوف نزل ولا لا ؟ وشوف ارقومنت السياره فيه 120 هذا الدوران عدله مثل ما تبي ذذ markers = { {2472.0881347656,-1688.6563720703,13.5078125-1}, {2228.4409179688,-1167.3218994141,25.747329711914-1}, {1719.2711181641,-1607.2225341797,13.546875-1}, {1506.5936279297,-1749.0170898438,13.546875-1}, {1220.3937988281,-1734.4114990234,13.580118179321-1}, {1144.107421875,-1292.6887207031,13.616773605347-1}, {666.86676025391,-1281.0958251953,13.4609375-1}, {1422.1994628906,-1136.7351074219,23.954034805298-1}, {1427.0316162109,-1046.7501220703,23.743759155273-1}, {1796.4952392578,-1439.7015380859,13.422317504883-1}, {987.70751953125,-1227.5476074219,16.922908782959-1}, {1944.8569335937,-1368.2105712891,18.578125-1} } addEventHandler('onResourceStart',resourceRoot,function() for k,v in ipairs(markers) do createMarker(v[1],v[2],v[3],'cylinder',3,255,255,175,170) end end ) local vehicles = {} addEvent('CreVehicePv',true) addEventHandler('CreVehicePv', root , function(id) local x, y, z = getElementPosition(source) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end vehicles[source] = createVehicle(id, x + 2, y, z,0,0,120) warpPedIntoVehicle(source, vehicles[source]) end ) addEventHandler('onPlayerQuit', root,function() if isElement(vehicles[source]) then destroyElement(vehicles[source]) vehicles[source] = nil end end ) addEventHandler('onMarkerHit',resourceRoot,function(hitPlayer) if getElementType(hitPlayer) == 'player' then triggerClientEvent (hitPlayer,'showGUIpv',hitPlayer) end end ) Link to comment
aL.Kfo Posted September 30, 2013 Author Share Posted September 30, 2013 مو انت قلت لكل السيرفر؟خليته للي لمس الماركر بس ذذ , وجرب الماركر شوف نزل ولا لا ؟ وشوف ارقومنت السياره فيه 120 هذا الدوران عدله مثل ما تبي ذذ markers = { {2472.0881347656,-1688.6563720703,13.5078125-1}, {2228.4409179688,-1167.3218994141,25.747329711914-1}, {1719.2711181641,-1607.2225341797,13.546875-1}, {1506.5936279297,-1749.0170898438,13.546875-1}, {1220.3937988281,-1734.4114990234,13.580118179321-1}, {1144.107421875,-1292.6887207031,13.616773605347-1}, {666.86676025391,-1281.0958251953,13.4609375-1}, {1422.1994628906,-1136.7351074219,23.954034805298-1}, {1427.0316162109,-1046.7501220703,23.743759155273-1}, {1796.4952392578,-1439.7015380859,13.422317504883-1}, {987.70751953125,-1227.5476074219,16.922908782959-1}, {1944.8569335937,-1368.2105712891,18.578125-1} } addEventHandler('onResourceStart',resourceRoot,function() for k,v in ipairs(markers) do createMarker(v[1],v[2],v[3],'cylinder',3,255,255,175,170) end end ) local vehicles = {} addEvent('CreVehicePv',true) addEventHandler('CreVehicePv', root , function(id) local x, y, z = getElementPosition(source) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end vehicles[source] = createVehicle(id, x + 2, y, z,0,0,120) warpPedIntoVehicle(source, vehicles[source]) end ) addEventHandler('onPlayerQuit', root,function() if isElement(vehicles[source]) then destroyElement(vehicles[source]) vehicles[source] = nil end end ) addEventHandler('onMarkerHit',resourceRoot,function(hitPlayer) if getElementType(hitPlayer) == 'player' then triggerClientEvent (hitPlayer,'showGUIpv',hitPlayer) end end ) يب صوح شكلي غلطت وانت فهمتها لكل السيرفر المهم انها ضبططت تمام التمام تممت الافادةةة Link to comment
تم حذف Posted October 6, 2013 Share Posted October 6, 2013 خوذ هاد مود جاهز وغير مشفر https://community.multitheftauto.com/ind ... ls&id=7285 Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now