laatClaymore.sqf 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. weaponsList=[
  2. ["1000Rnd_Laser_Cannon_LAAT","Cannon_LAAT",2,[-1]],
  3. ["4Rnd_LG_Jian","missiles_Jian",8,[-1]],
  4. ["magazine_Missile_rim116_x21","weapon_rim116Launcher",1,[0]],
  5. ["SmokeLauncherMag","SmokeLauncher",10,[-1,0]],
  6. ["300Rnd_CMFlare_Chaff_Magazine","CMFlareLauncher",10,[-1,0]],
  7. ["400Rnd_Pomehi_Mag","PomehiLauncherXT",10,[-1,0]],
  8. ["10Rnd_FAST_Cannon_TIE","Cannon_TIE_FAST",100,[1,2]],
  9. ["Laserbatteries","Laserdesignator_pilotCamera",1,[-1,0]]
  10. ];
  11. comment "remove torpedos";
  12. for [{_i=0}, {_i<2}, {_i=_i+1}] do
  13. {
  14. _this removeMagazineTurret ["laat_proton_torpedo" ,[-1]];
  15. _this removeWeaponTurret["laat_proton_torpedo_launcher", [-1]];
  16. };
  17. comment "adds the weapons";
  18. comment "goes through each weapon";
  19. for [{_i=0}, {_i<(count weaponsList)}, {_i=_i+1}] do
  20. {
  21. itemList = (weaponsList select _i);
  22. itemWeap= (itemList select 1);
  23. itemMag= (itemList select 0);
  24. itemCount= (itemList select 2);
  25. itemSeat= (itemList select 3);
  26. comment "goes through each mag count,aka add magz";
  27. for [{_j=0}, {_j<itemCount}, {_j=_j+1}] do
  28. {
  29. comment "goes through each seat,aka add 1 mag to each seat";
  30. for [{_k=0}, {_k<(count itemSeat)}, {_k=_k+1}] do
  31. {
  32. _this addMagazineTurret [itemMag ,[itemSeat select _k]];
  33. _this addWeaponTurret[itemWeap, [itemSeat select _k]];
  34. };
  35. };
  36. };
  37. comment "gets health";
  38. _this addAction ["<t color='#00FF00'>Damage Report</t>",
  39. {
  40. hint parseText format["<t color='#0099FF'> Damage status is :%1</t>",((1-(damage (_this select 0)))*100)];
  41. },[1],0,false,true,""," driver _target == _this "];