Jump to content

(تمت الافادة من تابل)طلب


Recommended Posts

ابغى الباب مايتحرك الا اذا دخل شخص ماركر يعني الامر فوق والامر تحت ماتتنفذ الا اذا دخلت الماركر

  
local gate = createObject(3095, 2969.1999511719, -700.20001220703, 1.500, 0, 0, 0) 
function open() 
moveObject(gate, 10000, 2969.1999511719, -700.20001220703, 1.500, 0, 0, 0 ) 
end 
addCommandHandler("تحت", open) 
function close() 
moveObject(gate, 10000, 2970.1999511719, -691, 687.20001220703, 0, 0, 0 ) 
end 
addCommandHandler("فوق", close) 
  
  
  
  

Edited by Guest
Link to comment
-- # Server Side ! 
local marker = createMarker (         ............        ) 
  
addEventHandler("onMarkerHit",marker,function ( element ) 
if ( getElementType (element) == "player" and not isPedInVehicle(element) ) then 
addCommandHandler("فوق",function (  ) 
    moveObject(gate, 10000, 2969.1999511719, -700.20001220703, 1.500, 0, 0, 0 ) 
end) 
addCommandHandler("تحت",function (  ) 
    moveObject(gate, 10000, 2970.1999511719, -691, 687.20001220703, 0, 0, 0 ) 
end) 
end 
end) 
  

Link to comment

شوف الكود الي انا نزلتة الاول كل شيء صح وضبط اكتب في اف 8 وكل شيء شغال

انا حاط البوابة في السجن اذا قدني في المطعم وكتبت فوق ولا تحت تفح

ابغى اسوي ماركر اينفذ امر فوق وتحت الا اذا انا جوا ماركر جنب البوابة

Link to comment

الحين كودك كلينت ولا سيرفر؟

المفروض انه سيرفر

-- Server Side -- 
  
local gate = createObject(3095, 2969.1999511719, -700.20001220703, 1.500, 0, 0, 0) 
local marker = createMarker(...) -- هنا كمل الأرقمنت 
  
function open(player) 
    if isElementWithinMarker(player, marker) then -- التحقق ان اللاعب جوا الماركر 
        moveObject(gate, 10000, 2969.1999511719, -700.20001220703, 1.500, 0, 0, 0) 
    end 
end 
addCommandHandler("تحت", open) 
  
function close(player) 
    if isElementWithinMarker(player, marker) then -- التحقق ان اللاعب جوا الماركر 
        moveObject(gate, 10000, 2970.1999511719, -691, 687.20001220703, 0, 0, 0) 
    end 
end 
addCommandHandler("فوق", close) 

Link to comment
شوف الكود الي انا نزلتة الاول كل شيء صح وضبط اكتب في اف 8 وكل شيء شغال

انا حاط البوابة في السجن اذا قدني في المطعم وكتبت فوق ولا تحت تفح

ابغى اسوي ماركر اينفذ امر فوق وتحت الا اذا انا جوا ماركر جنب البوابة

* تم التعديل

خد كود تابل ذذ

Edited by Guest
Link to comment

جرب ورد خبر

local gate = createObject( id, x, y, z, 0, 0, 0) 
local marker = createMarker(        ........        ) 
  
addEventHandler("onMarkerHit", root, 
function open(player) 
    if isElementWithinMarker(player, marker) then 
        moveObject ( gate, time, x, y, z ) 
    end 
end 
addCommandHandler("اصعد", open) 
  
addEventHandler("onMarkerHit", root, 
function close(player) 
    if isElementWithinMarker(player, marker) then 
        moveObject ( gate, time, x, y, z ) 
    end 
end 
addCommandHandler("انزل", close) 
Edited by Guest
Link to comment
الي فوق وش تخربطون؟

ترا الكود حطيته بردي فوق من زمان ما يحتاج بعد تحاول تساعد و تحط هريس .___________.

الامر فوق والامر تحت ماتتنفذ الا اذا دخلت الماركر
Link to comment
الي فوق وش تخربطون؟

ترا الكود حطيته بردي فوق من زمان ما يحتاج بعد تحاول تساعد و تحط هريس .___________.

الامر فوق والامر تحت ماتتنفذ الا اذا دخلت الماركر

if isElementWithinMarker(player, marker) then

Link to comment
الي فوق وش تخربطون؟

ترا الكود حطيته بردي فوق من زمان ما يحتاج بعد تحاول تساعد و تحط هريس .___________.

الكود الي كنت انا حاطنه هو صح مو هريسة ولا سلطة ذذ

فقط قلت له يضيفه على كود ابوشنب . :lol:

Edited by Guest
Link to comment
الي فوق وش تخربطون؟

ترا الكود حطيته بردي فوق من زمان ما يحتاج بعد تحاول تساعد و تحط هريس .___________.

الامر فوق والامر تحت ماتتنفذ الا اذا دخلت الماركر

if isElementWithinMarker(player, marker) then

مانتبهت :x

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