Jump to content

طلب تغير الكاميرا


Recommended Posts

ممكن توضح لانك اما ما فهمت اللي ابيه او انا ما فهمت على الكود

شوف الويكي ,

This function gets the position of the camera and the position of the point it is facing.

هاذا الكود يقوم بأحضار احداثيات الكاميرا ,

ياليت توضح لنا وش تبي بالضبط , عشان نعرف نساعدك ,

Link to comment

# وعليكم السلأم ...

setCameraMatrix:

This function sets the camera's position and direction. The first three arguments are the point at which the camera lies, the last three are the point the camera faces (or the point it "looks at").

Note: Calling this function takes the camera's focus away from the player and sets the camera in a fixed position and rotation. The camera's focus can be brought back to the player using the setCameraTarget function.

Client Syntax

bool setCameraMatrix ( float positionX, float positionY, float positionZ [, float lookAtX, float lookAtY, float lookAtZ, float roll = 0, float fov = 70 ] ) 

# ببساطة فائدة الفنكشن انه يحط لك الكميرا بـ احداثيات محدةة ..

كيف اقدر اجيب الاحداثيات او الارقمنات المطلوبة .

x, y, z اول 3 ارقمنات معروفة

getCameraMatrix الـ 3 اللي بعدها تجيبهم عن طريق فنكشن

ويمديك تجيب اول 6 ارقمنات من ذا الفنكشن

مثال بسيط كيف تجيب الاحداثيات : ...

addCommandHandler( "GetCameraPos", function ( ) 
       local x, y, z, xl, yl, zl = getCameraMatrix(  ) 
       if ( x == 0 or y == 0 or z == 0 ) then return end 
       setClipboard(" "..x..", "..y..", "..z..", "..xl..", "..yl..", "..zl.." ") 
end ) 

setCameraMatrix وبتنسخ لك الاحداثيات كاملة بس عليك تحطها بـ GetCameraPos تقوم بـ كتابة الأمر

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