undefined Posted July 11, 2014 Share Posted July 11, 2014 Hi guys. How to use setWeaponProperty function for per player? Thanks... Link to comment
undefined Posted July 12, 2014 Author Share Posted July 12, 2014 Huh? Why So is there anything else I can do this function? Im find the this code on the pastebin. But i can't understand this. What does this code? addEventHandler( "onResourceStart", resourceRoot, function() local aWeaponSkills = { [ 30 ] = { "poor:1", "poor:2", "poor:3" }; [ 31 ] = { "poor:1" }; }; local WeaponsStats = { [ 31 ] = { [ "poor:1" ] = - { { "damage", 100 }; { "accuracy", 0.9 }; }; }; [ 30 ] = { [ "poor:1" ] = { { "damage", 10 }; { "accuracy", 0.1 }; { "maximum_clip_amm", 30 }; }; [ "poor:2" ] = { { "damage", 15 }; { "accuracy", 0.3 }; { "maximum_clip_amm", 30 }; }; [ "poor:3" ] = { { "damage", 50 }; { "accuracy", 0.4 }; { "maximum_clip_amm", 45 }; }; }; }; for iID, aSkills in ipairs( aWeaponSkills ) do for i, v in ipairs( aSkills ) do addWeaponSkill( iID, v ); end end for iID, aSkills in pairs( WeaponsStats ) do for sLvl, aSettins in pairs( aSkills ) do for i, v in ipairs( aSettins ) do setWeaponProperty( iID, sLvl, unpack( v ) ); end end end end ); Link to comment
Chronic Posted July 12, 2014 Share Posted July 12, 2014 Quick unrelated question, why do you use hashtags in your topic names? This isn't twitter Link to comment
undefined Posted July 12, 2014 Author Share Posted July 12, 2014 Quick unrelated question, why do you use hashtags in your topic names? This isn't twitter I like it Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now