Jump to content

مساعدة


fargot..

Recommended Posts

Posted

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

شباب انا اليوم سويت ماب و ابي انتقل له بكلمة اكتبها من الاف 8 

كيف 

..

Posted

خذ الإحداثيات حقت الماب اللي تبي تنتقل له, وإستخدم الفنكشن ذا عشان تغير موقع اللاعب

setElementPosition

Posted (edited)

كيف اسوي بظبط تراني لسه جديد في برمجة

وين احط الاحداثيات و كيف 

.

 

Edited by Ad[N]a[N]e
Posted
 

كيف اسوي بظبط تراني لسه جديد في برمجة

وين احط الاحداثيات و كيف 

function onMove ()
setElementPosition ( localPlayer, x, y, z ) -- x,y,z الاحداثيات
end
addCommandHandler ( "movePlayer", onMove ) -- movePlayer الكلمة اللي تكتبها ميشان نتنقل

 

Posted
48 minutes ago, Developer Ahmed said:

function onMove ()setElementPosition ( localPlayer, x, y, z ) -- x,y,z الاحداثيات
end
addCommandHandler ( "movePlayer", onMove ) -- movePlayer الكلمة اللي تكتبها ميشان نتنقل

 

لو خليته يحاول الاول 

Posted

مشكوورين 

انا الحين سويت مركرين و بعدين انا ابي لكل مركر ينتقلو له حسب التيم الي انا ابيه كيف ؟؟ 

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

..

Posted
 

مشكوورين 

انا الحين سويت مركرين و بعدين انا ابي لكل مركر ينتقلو له حسب التيم الي انا ابيه كيف ؟؟ 

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

..

"onClientMarkerHit" -- Event
getElementType
getPlayerTeam
getTeamName
setElementPosition

 

Posted
addEventHandler ( 'onClientMarkerHit' )
getLocalPlayer
isPedInVehicle -- هذا اذا بغيت تحقق انة بدون مركبة
getPlayerTeam
getTeamFromName
setElementPosition

-- To Do :

addEventHandler ( 'onClientMarkerHit',aMyMarker,
	function ( aEle )
    	if aEle and aEle == localPlayer then 
      	-- to do team check and set pos
      end
   end
)

 

عطيتك نص الحكايه بقي عليك تزبط الناقص :) 

Posted

اسوي اسم التيمين 

  1. getTeamFromName - كيف احط اسم التيمين + انا ابي احط تيمين و قروبين
  2. لازم احط الماركرين في ماب ؟ + كيف وريني بظبط
  3. كيف اسوي البوابة انا معي بوبتين كيف اسويهما تفتحا بالكلمة من اف 8 او بالوحة
  4. في الحقيقة انا ابي اسوي مود حرب كلانات
  5. اسف على ازعاج انا ابي اتعمل برمجة
  6. ..
Posted (edited)
 

احمد تقدر توضح لي شوي 

جرب هذا سويته لك بدون ما اجربه في اللعبة
اذا كان في خطأ قولي وبساعدك في حله بإذن الله

Marker1 = createMarker ( x,y,z, "cylinder", 2, 255, 255, 0, 0 ) -- ماركر التيم الاةل
Marker2 = createMarker ( x,y,z, "cylinder", 2, 255, 255, 0, 0 ) -- ماركر التيم الثاني

team1 = "الفريق الاول"
team2 = "الفريق الثاني"

x1,y1,z1 = 0,0,0 -- ينقل التيم  الاول هنا
x2,y2,z2 = 0,0,0 -- ينقل التيم الثاني هنا

addEventHandler("onClientMarkerHit",Marker,
function (player)

    if source == Marker1 then
        if (getElementType (player) == "player") and (player == localPlayer)  then
            if not isPedInVehicle (player) then
                local Team = getPlayerTeam(getLocalPlayer())
                if Team and getTeamName(Team) == team1 then
                    setElementPosition ( player, x1,y1,z1 )
                    exports["guimessages"]:outputClient("لقد ذهبت الى الحرب", 0, 255, 0,source)
                else
                    exports["guimessages"]:outputClient("يجب ان تكون في هذا التيم "..team1, 255, 0, 0,source)
                end
            end
        end
    end
    
    if source == Marker2 then
        if (getElementType (player) == "player") and (player == localPlayer)  then
            if not isPedInVehicle (player) then
                local Team = getPlayerTeam(getLocalPlayer())
                if Team and getTeamName(Team) == team2 then
                    setElementPosition ( player, x2,y2,z2 )
                    exports["guimessages"]:outputClient("لقد ذهبت الى الحرب", 0, 255, 0,source)
                else
                    exports["guimessages"]:outputClient("يجب ان تكون في هذا التيم "..team2, 255, 0, 0,source)
                end
            end
        end
    end

end
)

 

Edited by Developer Ahmed
  • Like 1
Posted (edited)

احمد مشكور + وين احط ذي البيانات في ملف سيرفير او ملف سيلينت ؟ + ابي اخلي القروب ينتقل من كلمة الي انا ااسويها

ما تقدر تخلي ينتقل اعضاء القروبات بس و تيم لازم ؟؟

و وين احط احداثيات الماب حق حرب ؟ 

و بعد ما ينسحب التيم يعطيه دم 100 و درع  

و ابي اخلي البوابة تفتح بكلمة من اف 8 او من لوحة 

Edited by Ad[N]a[N]e
Posted
 

احمد مشكور + وين احط ذي البيانات في ملف سيرفير او ملف سيلينت ؟

و وين احط احداثيات الماب حق حرب ؟ 

و بعد ما ينسحب التيم يعطيه دم 100 و درع  

و ابي اخلي البوابة تفتح بكلمة من اف 8 او من لوحة 

ضيف الكود في ملف كلينت

setElementHealth -- يعطي دم للاعب
setPedArmor -- يعطي اللاعب درع
-- server
addCommandHandler -- اضافة كلمة في اف 8
createObject -- يصنع اوبجكت
moveObject -- يحرك الاوبجكت

 

Posted
 

ابيها منظمة مع المعلومات الي سويتها فوق لصقهم مع بعض و عطيني الاكواد ضربة واحدة

عدناني انا آسف بس انت لازم تجرب بنفسك واذا واجهتك اخطاء نساعدك

Posted (edited)
Just now, Ad[N]a[N]e said:

setElementHealth  - كيف احط 100

setPedArmor - كيف احط 100

كيف انضمهم مع المعلومات الي فوق الي عطيتها لي اخوي 

..

Syntax

 bool setElementHealth ( element theElement, float newHealth )

 

Syntax

bool setPedArmor ( ped thePed, float armor )

Syntax شوف الـ

وادخل على الوظيفه و شوف الامثله

 

 

Edited by iMr ~ MnHmAr
Posted (edited)

بتوفيق لك 

 

..

On 15.11.2016 at 9:22 PM, Ad[N]a[N]e said:

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

شباب انا اليوم سويت ماب و ابي انتقل له بكلمة اكتبها من الاف 8 

كيف 

..

---لايوجد داتا يمكن زيادة --

local marker = createMarker    ( 1733.29956,-2202.67969,12.7 , "cylinder", 1.2,240,230,40,255 ) --محل الماركار مكانه

function entrarGuard (hitPlayer, matchingDimension)     --فاتكشن
    local playerTeam = getPlayerTeam (hitPlayer)
    local Clann = getTeamFromName ( "Rifa" ) -- التيم الي يمكنه يدخل
    if ( playerTeam ) == Clann then 

            setTimer ( setElementPosition, 1000, 1, hitPlayer, 3702.71997,-1787.36548,5.69160 ) --احدثيات الماب اول الدخول

 
    setPedArmor (hitPlayer, 100) --درع
   setElementHealth (hitPlayer,100) -- دم
    else
    exports["guimessages"]:outputServer(root," #E4F20A * #00FF00 [ClanWar] #E4F20A This Marker For Team Rifa  ! !", 0, 255, 0) --من فوق اول التركيب
end
end

addEventHandler ( "onMarkerHit", marker, entrarGuard )

--------------------------------------------------------------------------------------------------------------------------------------------------
local marker1 = createMarker    ( 1727.34155,-2202.96704,12.7 , "cylinder", 1.2,170,20,120,255 ) --محل الماركار مكانه
    setElementInterior ( marker1, 0 )    --افتح الوحة وشوف interior
function entrarGuard (hitPlayer, matchingDimension)      --فاتكشن
    local playerTeam = getPlayerTeam (hitPlayer)
    local Clann = getTeamFromName ( "Mafia" ) --التيم الي يخشونه
 
    if ( playerTeam ) == Clann then 

            setTimer ( setElementPosition, 1000, 1, hitPlayer, 3468.07056,-1856.62256,5.69160 ) --احدثيات الماب اول الدخول


    setPedArmor (hitPlayer, 100) --درع
   setElementHealth (hitPlayer,100) --دم
    else
    exports["guimessages"]:outputServer(root,"  #960594 * #00FF00 [ClanWar] #960594 This Marker For Team Mafia  ! !", 0, 255, 0)
end
end
addEventHandler ( "onMarkerHit", marker1, entrarGuard )
-------------------------------------------


createBlip (1730.21716,-2202.68091,13.54688 , 38 ) --علامة اف11 

--------------------------------------------------------------

 

كود جاهز 

  setElementgroup

Edited by DmAr511

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