Jump to content

Dking2001

Members
  • Posts

    7
  • Joined

  • Last visited

Details

  • Gang
    bh_Gang
  • Location
    bahrain

Recent Profile Visitors

461 profile views

Dking2001's Achievements

Newbie

Newbie (4/54)

0

Reputation

  1. its not working ... mta server write like this [16:06:25] WARNING: banner\pylonhead.lua:17: Bad argument @ 'setPedRotation' [Expected element at argument 1] [DUP x101] [16:06:25] WARNING: banner\pylonhead.lua:21: Bad argument @ 'setPedRotation' [Expected element at argument 1] [DUP x101] [16:06:25] WARNING: banner\pylonhead.lua:25: Bad argument @ 'setPedRotation' [Expected element at argument 1] [DUP x101] [16:06:25] WARNING: banner\pylonhead.lua:29: Bad argument @ 'setPedRotation' [Expected element at argument 1] [DUP x101] but i dont know why its working for one time only
  2. hi guys i have a problem to set ped rotation like player rotation always i mean if you change yor rotation the ped change his rotation too sorry for bad English here is the code local pylonid = 2662 local pylon_x, pylon_y = 0, 0.5 local pylon_c, pylon_v = 0, 0 local pylonheight = 0 local pylonscale = 1.3 local function pylonHead(player, command) if not pylon or pylon == nil then local px, py, pz = getElementPosition( player ) pylon = createObject( pylonid, px, py, pz) attachElements(pylon, player, pylon_x-1, pylon_y, pylonheight, 0, 0, 180) setObjectScale( pylon, pylonscale ) setElementCollisionsEnabled( pylon, true ) myBlip = createBlipAttachedTo ( player, 19 ) ped = createPed( 105, px, py, pz) attachElements( ped, player, pylon_c-2, pylon_v, pylonheight) setPedAnimation(ped, "wuzi", "wuzi_walk") peda = createPed( 33, px, py, pz) attachElements( peda, player, pylon_c-1, pylon_v-1, pylonheight) setPedAnimation(peda, "wuzi", "wuzi_walk") pedb = createPed( 33, px, py, pz) attachElements( pedb, player, pylon_c, pylon_v-1, pylonheight) setPedAnimation(pedb, "wuzi", "wuzi_walk") pedc = createPed( 105, px, py, pz) attachElements( pedc, player, pylon_c-2, pylon_v-1, pylonheight) setPedAnimation(pedc, "wuzi", "wuzi_walk") else detachElements( pylon, player ) detachElements( ped, player ) detachElements( peda, player ) detachElements( pedb, player ) detachElements( pedc, player ) destroyElement( pylon ) setPedAnimation(ped, "riot", "riot_angry") setPedAnimation(peda, "riot", "riot_chant") setPedAnimation(pedb, "riot", "riot_punches") setPedAnimation(pedc, "riot", "riot_shout") destroyElement( myBlip ) pylon = nil end end addCommandHandler("bnr", pylonHead) i want the peds (ped , peda , pedb and pedc) moveing with me i need only to set rotation changing with me thank you ... mta server write like this [00:53:36] WARNING: banner\pylonhead.lua:28: Bad argument @ 'setElementRotation' [Expected element at argument 1, got number '0']
  3. بس عندي مشكلة انه يشتغل مرة واحدة بس يصير انه يكرر الامر اكثر من مرة او يكون unlimited لانه انا راح اغير اتجاهيي او الروتيشن اكثر من مرة جيكته و ما ضبط عندي ممكن تشوف لي حل هذي كل الكواد الي عندي وللعلم فهمت ان ال100 = 100لحظة وان الصفر تعني تكرار لا نهائي local pylonid = 2662 local pylon_x, pylon_y = 0, 0.5 local pylon_c, pylon_v = 0, 0 local pylonheight = 0 local pylonscale = 1.3 local function pylonHead(player, command) if not pylon or pylon == nil then local px, py, pz = getElementPosition( player ) pylon = createObject( pylonid, px, py, pz) attachElements(pylon, player, pylon_x-1, pylon_y, pylonheight, 0, 0, 180) setObjectScale( pylon, pylonscale ) setElementCollisionsEnabled( pylon, true ) myBlip = createBlipAttachedTo ( player, 19 ) ped = createPed( 105, px, py, pz) attachElements( ped, player, pylon_c-2, pylon_v, pylonheight) setPedAnimation(ped, "wuzi", "wuzi_walk") peda = createPed( 33, px, py, pz) attachElements( peda, player, pylon_c-1, pylon_v-1, pylonheight) setPedAnimation(peda, "wuzi", "wuzi_walk") pedb = createPed( 33, px, py, pz) attachElements( pedb, player, pylon_c, pylon_v-1, pylonheight) setPedAnimation(pedb, "wuzi", "wuzi_walk") pedc = createPed( 105, px, py, pz) attachElements( pedc, player, pylon_c-2, pylon_v-1, pylonheight) setPedAnimation(pedc, "wuzi", "wuzi_walk") setTimer(setPedRotation, 100, 0, pedc, getPedRotation(player)) else detachElements( pylon, player ) detachElements( ped, player ) detachElements( peda, player ) detachElements( pedb, player ) detachElements( pedc, player ) destroyElement( pylon ) setPedAnimation(ped, "riot", "riot_angry") setPedAnimation(peda, "riot", "riot_chant") setPedAnimation(pedb, "riot", "riot_punches") setPedAnimation(pedc, "riot", "riot_shout") destroyElement( myBlip ) pylon = nil end end addCommandHandler("bnr", pylonHead) ضبطت معاي بس مرة وحدة شوف الصورة عقب ما خليت البيد C يتغير الروتيشن حقه بس مرة وحدة يغير الروتيشن حقه مو اكثر
  4. ما عرفت كيف تقدر تفهمني انا مخلي اكثر من بيد يتحركون نفس الي يتحركون معاي بس اذا اشغل المود اشوفهم يتحركون معاي بس يواجهون اتجاه غير اتجاه اللاعب
  5. السلام عليكم المشكلة باختصار انه انا اريد اسوي بيد (ped) واخلي الروتيشن حقه مثل الروتيشن حق اللاعب يعي يتغير باستمرار قصدي من يفتر اللاعب يفتر معاه البيد يعني من يغير اللاعب الروتيشن حقه ابي يسوي البيد setElementRotation(thePed, (getPlayerRotation (thePlayer) ) ) بس حاليا المشكلة اني ما اعرف كيف اجيب كود انه اذا تغير روتيشن اللاعب ولعلمكم انا مخلي ped attached with player pedc = createPed( 105, px, py, pz) attachElements( pedc, player, pylon_c-2, pylon_v-1, pylonheight) setPedAnimation(pedc, "wuzi", "wuzi_walk")
×
×
  • Create New...