More Weapon Slots

Started by W3aPoN^, Jul 22, 2016, 09:11 AM

Previous topic - Next topic

W3aPoN^

Hello Guys I Want to Add 9 Weapon Slots In My AddClass Is It Possible If yes Then How I Can Add 9 Weapon Slots I Make This But This Is crashing My Server See AddClass( 1, RGB( 153, 76, 0 ) ,1, Vector( 397.260, -471.909, 11.076 ), 0, anyweapon, 500 ,anyweapon, 500, anyweapon, 500, anyweapon, 500, anyweapon, 500, anyweapon, 500, anyweapon, 500, anyweapon, 500, anyweapon, 500 ); Please HELP ME

KAKAN

don't do that. Use this technique:-
function onPlayerSpawn( player )
{
  local s = player.SetWeapon;
  s( 21, 999 );
  s( 22, 999 );
}
And if you set in sequence, use a for loop.
And the best way, use an array and a foreach loop, that will make things easier.
oh no

RW

Bring them in onPlayerSpawn
player.SetWeapon(weapon id,ammo);

W3aPoN^

KAKAN Where Are You From?

DizzasTeR

Quote from: KAKAN on Jul 22, 2016, 09:16 AMlocal s = player.SetWeapon;

Is it really that necessary to store the function into a local variable and then use it? Guess not, just pointing it out because this lowers the standard of your examples

KAKAN

Quote from: Doom_Kill3R on Jul 22, 2016, 10:18 AM
Quote from: KAKAN on Jul 22, 2016, 09:16 AMlocal s = player.SetWeapon;

Is it really that necessary to store the function into a local variable and then use it? Guess not, just pointing it out because this lowers the standard of your examples
I was at phone, and you know, typing from phone feels really shit :p
oh no

W3aPoN^

Thanks PROBLEM Solved!!! Thanks KAKAN and THANKS [F.B.I]RW

RW

Quote from: razacharan on Jul 22, 2016, 10:27 AMThanks PROBLEM Solved!!! Thanks KAKAN and THANKS [F.B.I]RW
You're welcome, guy. :D