Jump to content

no shot when no aim


Annas

Recommended Posts

Can any one help me please ?

i need (no shot when not aim) , for no lag.

i try to do this:

SERVER SIDE

addEventHandler ( "onResourceStart", root, 
    function ( ) 
        for _,weaponSkill in ipairs({"poor","std","pro"}) do   
            setWeaponProperty("Combat Shotgun", weaponSkill, "flags", 0x000001)  
        end 
    end 
) 

it's not work ..

I NEED TO DISABLE : when a player have weapon, + he dont aim; he can shot without aiming !

PLEASE I NEED UR HELP!

Link to comment

try

  
addEventHandler('onClientRender',root, 
   function( ) 
        if not getPedControlState(localPlayer, "aim_weapon") and getPedWeapon(localPlayer) > 15 then 
            toggleControl('fire',false) 
        else 
            toggleControl('fire',true) 
        end 
   end 
) 

edit: well it looks like you cant cancel onClientPlayerWeaponFire so i redid the script so this works

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