Jump to content

مساعدة في صنع Ped


MrCor

Recommended Posts

السلام عليكم ورحمة الله وبركاته

كيف حالكم شباب أنشاء الله طيبين

أنا قبل يومين سويت موضوع بنفس هذا العنوان بس مادري صارت هوشه فيه و أنحذف

المساعدة :

أنا أبي أحد يسوي ليي كود بيد أذا تقرب منه أحد يطلق عليه يعني يصير حوله ماركر

انا سويت واحد بس على طول يطلق ما يوقف

أنا صراحه عجزت و أنا ابي أسوي هذا الكود

Link to comment
  • Replies 73
  • Created
  • Last Reply

Top Posters In This Topic

الأفضل انك تسوي الكود بنفسك وقد عطيناك الوظايف الي تساعدك على عمل المكود وانت تبيه جاهز ,, ما احد أبداً هنا رح يتعبلك ويقعد ساعتين يسويلك في الكود وبدون مقابل , استخدم

---- وظايف ----

createPed -- يصنع البيد 
setPedRotation -- الاتجاه 
setTimer -- وقت 
setPedControlState -- يسوي اشياء بدون تحكم 
giveWeapon -- اعطاء سلاح 
createMarker -- يصنع ماركر 
  

---- أحداث ----

onMarkerHit - عند لمس الماركر الي بتسويها على هالبيد

اذا تبي الكود جاهز وما تبي تسويه بنفسك

أنا اطالب بحذف هالموضوع

Link to comment
السلام عليكم ورحمة الله وبركاته

كيف حالكم شباب أنشاء الله طيبين

أنا قبل يومين سويت موضوع بنفس هذا العنوان بس مادري صارت هوشه فيه و أنحذف

المساعدة :

أنا أبي أحد يسوي ليي كود بيد أذا تقرب منه أحد يطلق عليه يعني يصير حوله ماركر

انا سويت واحد بس على طول يطلق ما يوقف

أنا صراحه عجزت و أنا ابي أسوي هذا الكود

اخوي انت تباه يحرس منطقة معينة

و الي في نفس تيمه مايذبحه ؟

Link to comment
السلام عليكم ورحمة الله وبركاته

كيف حالكم شباب أنشاء الله طيبين

أنا قبل يومين سويت موضوع بنفس هذا العنوان بس مادري صارت هوشه فيه و أنحذف

المساعدة :

أنا أبي أحد يسوي ليي كود بيد أذا تقرب منه أحد يطلق عليه يعني يصير حوله ماركر

انا سويت واحد بس على طول يطلق ما يوقف

أنا صراحه عجزت و أنا ابي أسوي هذا الكود

اخوي انت تباه يحرس منطقة معينة

و الي في نفس تيمه مايذبحه ؟

اي بالضبط

Link to comment
الأفضل انك تسوي الكود بنفسك وقد عطيناك الوظايف الي تساعدك على عمل المكود وانت تبيه جاهز ,, ما احد أبداً هنا رح يتعبلك ويقعد ساعتين يسويلك في الكود وبدون مقابل , استخدم

---- وظايف ----

createPed -- يصنع البيد 
setPedRotation -- الاتجاه 
setTimer -- وقت 
setPedControlState -- يسوي اشياء بدون تحكم 
giveWeapon -- اعطاء سلاح 
createMarker -- يصنع ماركر 
  

---- أحداث ----

onMarkerHit - عند لمس الماركر الي بتسويها على هالبيد

اذا تبي الكود جاهز وما تبي تسويه بنفسك

أنا اطالب بحذف هالموضوع

أخوي انا سويت كل شي بس ما عرفت أسوي

onMarkerHit

يعني مو تفكر أبي كل شي جاهز

Link to comment

جرب اذا اشتغل ولا لا

-- Client Side --

addEvent("onShot",true) 
addEvent("onStop",true) 
time = {} 
  
addEventHandler("onShot",root, 
    function (ped,x,y,z) 
        if ( time[localPlayer] ) then 
            killTimer(time[localPlayer]) 
        end 
        time[localPlayer] = setTimer(setPedAimTarget,50,0,ped,x,y,z) 
        setPedControlState(ped,"fire",true) 
    end 
) 
  
addEventHandler("onStop",root, 
    function (ped) 
        if ( time[localPlayer] ) then 
            killTimer(time[localPlayer]) 
        end 
        setPedControlState(ped,"fire",false) 
    end 
)  

-- Server Side --

local x,y,z = 0,0,0 
marker = createMarker(x,y,z,"cylinder",4,0,0,0,0) 
ped = createPed(285,x,y,z) 
giveWeapon(ped,31,1000) 
setPedWeaponSlot(getSlotFromWeapon(31)) 
  
addEventHandler("onMarkerHit",marker, 
    function (player) 
        local x,y,z = getElementPosition(player) 
        triggerClientEvent(player,"onShot",player,ped,x,y,z) 
    end 
) 
  
addEventHandler("onMarkerLeave",marker, 
    function (player) 
        triggerClientEvent(player,"onStop",player,ped) 
    end 
) 

Edited by Guest
Link to comment
جرب اذا اشتغل ولا لا

-- Client Side --

addEvent("onShot",true) 
addEvent("onStop",true) 
  
addEventHandler("onShot",root, 
    function (ped) 
        setPedControlState(ped,"fire",true) 
    end 
) 
  
addEventHandler("onStop",root, 
    function (ped) 
        setPedControlState(ped,"fire",false) 
    end 
) 
  

-- Server Side --

local x,y,z = 0,0,0 
marker = createMarker(x,y,z,"cylinder",4,0,0,0,0) 
ped = createPed(285,x,y,z) 
time = {} 
giveWeapon(ped,31,1000) 
  
addEventHandler("onMarkerHit",marker, 
    function (player) 
        if ( time[player] ) then 
            killTimer(time[player]) 
        end 
        local rx,ry,rz = getElementRotation(player) 
        time[player] = setTimer(setElementRotation,100,0,ped,rx,ry,rz) 
        triggerClientEvent(player,"onShot",player,ped) 
    end 
) 
  
addEventHandler("onMarkerLeave",marker, 
    function (player) 
        if ( isTimer(time[player]) ) then 
            killTimer(time[player]) 
        end 
        triggerClientEvent(player,"onStop",player,ped) 
    end 
) 

شكرا طلال وجاري التجربة

Link to comment
جرب اذا اشتغل ولا لا

-- Client Side --

addEvent("onShot",true) 
addEvent("onStop",true) 
  
addEventHandler("onShot",root, 
    function (ped) 
        setPedControlState(ped,"fire",true) 
    end 
) 
  
addEventHandler("onStop",root, 
    function (ped) 
        setPedControlState(ped,"fire",false) 
    end 
) 
  

-- Server Side --

local x,y,z = 0,0,0 
marker = createMarker(x,y,z,"cylinder",4,0,0,0,0) 
ped = createPed(285,x,y,z) 
time = {} 
giveWeapon(ped,31,1000) 
  
addEventHandler("onMarkerHit",marker, 
    function (player) 
        if ( time[player] ) then 
            killTimer(time[player]) 
        end 
        local rx,ry,rz = getElementRotation(player) 
        time[player] = setTimer(setElementRotation,100,0,ped,rx,ry,rz) 
        triggerClientEvent(player,"onShot",player,ped) 
    end 
) 
  
addEventHandler("onMarkerLeave",marker, 
    function (player) 
        if ( isTimer(time[player]) ) then 
            killTimer(time[player]) 
        end 
        triggerClientEvent(player,"onStop",player,ped) 
    end 
) 

طلال الكود به أخطاء

1- ما ينعطى سلاح

2- لم تروح له يضرب بيده بس ضربه وحده

3- لم تروح جنبه يدور و يعطيك ضهره و يضرب بكس

ياليت أحد يساعدني

عاشق الشرق بشوف المود

Link to comment
بالنسبة للسلاح اخذه لكن ما سار في يد الباد

استخدم

setPedWeaponSlot 

لكن مودك بيكون فيه رياضيات كثير

انا ما احبطك لكن بالتوفيق

EDIT : شوف مود الزومبي يمكن تلاقي اكواد تساعدك

أستخدمته ما زبط

وين تاااابل

عااشق الشرق ابي المود أذا تقدر

Link to comment
Ped أستخدم ذا لتحديد مكان تصويب الـ
setPedAimTarget 

بعد كلام تابل انا عدلت كودي الي اول

روح جربه

ركبت انا عليه

setPedAimTarget 

جربه اذا اشتغل ولا لا

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

المشاكل الحالية :

البيد ما عنده سلاح

البيد يضرب ضربه وحده بس

Link to comment
-- Server Side 
x, y, z = 0, 0, 0 
thePed = createPed ( 285, x, y, z ) 
theMarker = createMarker ( 0, 0, 0, "cylinder", 15, 0, 0, 0, 0 ) 
attachElements ( theMarker, thePed, 0, 0, -1 ) 
setTimer ( giveWeapon, 500, 1, thePed, 30, 999, true ) 
  
addEventHandler ( "onMarkerHit", theMarker, 
    function ( thePlayer ) 
        if thePlayer == thePlayer then 
            triggerClientEvent ( thePlayer, "setPedAttacking", thePlayer, thePed ) 
            outputChatBox ( "* Start Shooting !!!", thePlayer, 255, 255, 0, true ) 
        end 
    end 
) 
  
addEventHandler ( "onMarkerLeave", theMarker, 
    function ( thePlayer ) 
        if thePlayer == thePlayer then 
            triggerClientEvent ( thePlayer, "setPedStanding", thePlayer, thePed ) 
            outputChatBox ( "* Stop Shooting !!!", thePlayer, 255, 255, 0, true ) 
        end 
    end 
) 
  
addEvent ( "setPedWeaponAmmo", true ) 
addEventHandler ( "setPedWeaponAmmo", root, 
    function ( ) 
        setWeaponAmmo ( thePed, 30, 999 ) 
    end 
) 
  

-- Client Side 
addEvent ( "setPedAttacking", true ) 
addEventHandler ( "setPedAttacking", root, 
    function ( thePed ) 
        setTimer (  
            function ( )  
                x, y, z = getElementPosition ( localPlayer ) 
                setPedAimTarget ( thePed, x, y, z ) 
            end 
        , 100, 0 ) 
        setPedControlState ( thePed, "fire", true ) 
    end 
) 
  
addEvent ( "setPedStanding", true ) 
addEventHandler ( "setPedStanding", root, 
    function ( thePed ) 
        setPedControlState ( thePed, "fire", false ) 
        for _, x3NAD in ipairs ( getTimers ( 100 ) ) do 
            killTimer ( x3NAD ) 
        end      
        triggerServerEvent ( "setPedWeaponAmmo", localPlayer ) 
    end 
) 
  

Link to comment
-- Server Side 
x, y, z = 0, 0, 0 
thePed = createPed ( 285, x, y, z ) 
theMarker = createMarker ( 0, 0, 0, "cylinder", 15, 0, 0, 0, 0 ) 
attachElements ( theMarker, thePed, 0, 0, -1 ) 
setTimer ( giveWeapon, 500, 1, thePed, 30, 999, true ) 
  
addEventHandler ( "onMarkerHit", theMarker, 
    function ( thePlayer ) 
        if thePlayer == thePlayer then 
            triggerClientEvent ( thePlayer, "setPedAttacking", thePlayer, thePed ) 
            outputChatBox ( "* Start Shooting !!!", thePlayer, 255, 255, 0, true ) 
        end 
    end 
) 
  
addEventHandler ( "onMarkerLeave", theMarker, 
    function ( thePlayer ) 
        if thePlayer == thePlayer then 
            triggerClientEvent ( thePlayer, "setPedStanding", thePlayer, thePed ) 
            outputChatBox ( "* Stop Shooting !!!", thePlayer, 255, 255, 0, true ) 
        end 
    end 
) 
  
addEvent ( "setPedWeaponAmmo", true ) 
addEventHandler ( "setPedWeaponAmmo", root, 
    function ( ) 
        setWeaponAmmo ( thePed, 30, 999 ) 
    end 
) 
  

-- Client Side 
addEvent ( "setPedAttacking", true ) 
addEventHandler ( "setPedAttacking", root, 
    function ( thePed ) 
        setTimer (  
            function ( )  
                x, y, z = getElementPosition ( localPlayer ) 
                setPedAimTarget ( thePed, x, y, z ) 
            end 
        , 100, 0 ) 
        setPedControlState ( thePed, "fire", true ) 
    end 
) 
  
addEvent ( "setPedStanding", true ) 
addEventHandler ( "setPedStanding", root, 
    function ( thePed ) 
        setPedControlState ( thePed, "fire", false ) 
        for _, x3NAD in ipairs ( getTimers ( 100 ) ) do 
            killTimer ( x3NAD ) 
        end      
        triggerServerEvent ( "setPedWeaponAmmo", localPlayer ) 
    end 
) 
  

-- Server Side 
x, y, z = 0, 0, 0 
thePed = createPed ( 285, x, y, z ) 
theMarker = createMarker ( 0, 0, 0, "cylinder", 15, 0, 0, 0, 0 ) 
attachElements ( theMarker, thePed, 0, 0, -1 ) 
setTimer ( giveWeapon, 500, 1, thePed, 30, 999, true ) 
  
addEventHandler ( "onMarkerHit", theMarker, 
    function ( thePlayer ) 
        if getElementType(thePlayer) == 'player' then 
            triggerClientEvent ( thePlayer, "setPedAttacking", thePlayer, thePed ) 
            outputChatBox ( "* Start Shooting !!!", thePlayer, 255, 255, 0, true ) 
        end 
    end 
) 
  
addEventHandler ( "onMarkerLeave", theMarker, 
    function ( thePlayer ) 
        if getElementType(thePlayer) == 'player' then 
            triggerClientEvent ( thePlayer, "setPedStanding", thePlayer, thePed ) 
            outputChatBox ( "* Stop Shooting !!!", thePlayer, 255, 255, 0, true ) 
        end 
    end 
) 
  
addEvent ( "setPedWeaponAmmo", true ) 
addEventHandler ( "setPedWeaponAmmo", root, 
    function ( ) 
        setWeaponAmmo ( thePed, 30, 999 ) 
    end 
) 
  

-- Client Side 
addEvent ( "setPedAttacking", true ) 
addEventHandler ( "setPedAttacking", root, 
    function ( thePed ) 
        setTimer (  
            function ( )  
                x, y, z = getElementPosition ( localPlayer ) 
                setPedAimTarget ( thePed, x, y, z ) 
            end 
        , 100, 0 ) 
        setPedControlState ( thePed, "fire", true ) 
    end 
) 
  
addEvent ( "setPedStanding", true ) 
addEventHandler ( "setPedStanding", root, 
    function ( thePed ) 
        setPedControlState ( thePed, "fire", false ) 
        for _, x3NAD in ipairs ( getTimers ( 100 ) ) do 
            killTimer ( x3NAD ) 
        end      
        triggerServerEvent ( "setPedWeaponAmmo", localPlayer ) 
    end 
) 
  

Link to comment
-- Server Side 
x, y, z = 0, 0, 0 
thePed = createPed ( 285, x, y, z ) 
theMarker = createMarker ( 0, 0, 0, "cylinder", 15, 0, 0, 0, 0 ) 
attachElements ( theMarker, thePed, 0, 0, -1 ) 
setTimer ( giveWeapon, 500, 1, thePed, 30, 999, true ) 
  
addEventHandler ( "onMarkerHit", theMarker, 
    function ( thePlayer ) 
        if thePlayer == thePlayer then 
            triggerClientEvent ( thePlayer, "setPedAttacking", thePlayer, thePed ) 
            outputChatBox ( "* Start Shooting !!!", thePlayer, 255, 255, 0, true ) 
        end 
    end 
) 
  
addEventHandler ( "onMarkerLeave", theMarker, 
    function ( thePlayer ) 
        if thePlayer == thePlayer then 
            triggerClientEvent ( thePlayer, "setPedStanding", thePlayer, thePed ) 
            outputChatBox ( "* Stop Shooting !!!", thePlayer, 255, 255, 0, true ) 
        end 
    end 
) 
  
addEvent ( "setPedWeaponAmmo", true ) 
addEventHandler ( "setPedWeaponAmmo", root, 
    function ( ) 
        setWeaponAmmo ( thePed, 30, 999 ) 
    end 
) 
  

-- Client Side 
addEvent ( "setPedAttacking", true ) 
addEventHandler ( "setPedAttacking", root, 
    function ( thePed ) 
        setTimer (  
            function ( )  
                x, y, z = getElementPosition ( localPlayer ) 
                setPedAimTarget ( thePed, x, y, z ) 
            end 
        , 100, 0 ) 
        setPedControlState ( thePed, "fire", true ) 
    end 
) 
  
addEvent ( "setPedStanding", true ) 
addEventHandler ( "setPedStanding", root, 
    function ( thePed ) 
        setPedControlState ( thePed, "fire", false ) 
        for _, x3NAD in ipairs ( getTimers ( 100 ) ) do 
            killTimer ( x3NAD ) 
        end      
        triggerServerEvent ( "setPedWeaponAmmo", localPlayer ) 
    end 
) 
  

شكرا عناد غناتي الكود شغال بس فيه حاجتين أبيك تسويها فيه

أبيه لم يدخل الدائرة على طول يطلق مو لم تضربه

و ابيه يقتل تيم معين

ومره ثانيه أشكرك ي مبدع

Link to comment

سويه بنفسك , عطيناك الاكواد وانت ما تبي تسوي شي بنفسك

اذا تبيني اسويه ارسلي رسالة خاصة , فيه كم السعر الي بتعطيني عشان اسويه لك

وانا اعقلها بمخي

أو رآآسل اي مبرمج تبي

.

Link to comment
سويه بنفسك , عطيناك الاكواد وانت ما تبي تسوي شي بنفسك

اذا تبيني اسويه ارسلي رسالة خاصة , فيه كم السعر الي بتعطيني عشان اسويه لك

وانا اعقلها بمخي

أو رآآسل اي مبرمج تبي

.

خوك الحين الكود موجود

بس أبيك تسويه يقتل على طول من تدخل الدائرة و يقتل تيم معين

Link to comment
سويه بنفسك , عطيناك الاكواد وانت ما تبي تسوي شي بنفسك

اذا تبيني اسويه ارسلي رسالة خاصة , فيه كم السعر الي بتعطيني عشان اسويه لك

وانا اعقلها بمخي

أو رآآسل اي مبرمج تبي

.

أنا خليته يقتل تيم معين بس صارت مشكله قلت الي سوا الكود بيعرف له

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