Jump to content

مساعدة: CreateWeapon


Recommended Posts

السلام عليكم

ذي الفنكشن

createWeapon 

https://wiki.multitheftauto.com/wiki/CreateWeapon

تسوي سلاح حاولت بذا الكود اسوي السلاح يجي مع اللاعب

addEventHandler( "onClientRender", getRootElement(  ),  
        function() 
            x, y, z = getElementPosition( getLocalPlayer() ) 
        end 
) 
  
  
  
function createMinigunWeapon() 
  
    x, y, z = getElementPosition( getLocalPlayer() ) 
  
    weapon = createWeapon("minigun", x, y, z + 3 ) 
  
    setWeaponClipAmmo(weapon, 99999) 
    setWeaponState(weapon, "firing") 
  
    setWeaponProperty(weapon, "fire_rotation", 0, -30, 0) 
end 
  

بس في طريقة اخلي السلاح يدور مع زاوية دوران اللاعب ؟

جربت

getElementRotation

ما نجحت

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