config.cpp 9.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373
  1. //Get this addons macro
  2. //get the macro for the air subaddon
  3. //get generlized macros
  4. #include "../../../RD501_main/config_macros.hpp"
  5. //General name of the vehicle
  6. #define vehicle_addon LAAT
  7. #define patch_name MODNAME##vehicle_addon##_Patches
  8. #define vehicle_classname MODNAME##_##vehicle_addon
  9. #define macro_new_vehicle(laat,name) vehicle_classname##_##name
  10. #define reskined_laat_mk3(classname,displayname,texturebody,texturewing)\
  11. class macro_new_vehicle(laat,classname):macro_new_vehicle(laat,Mk3)\
  12. {\
  13. forceInGarage = 0;\
  14. displayName=LAAT/I MK.III - ('##displayname##') ;\
  15. hiddenSelectionsTextures[]={macro_vehicle_textures##\LAAT\##texturebody,macro_vehicle_textures##\LAAT\##texturewing};\
  16. };
  17. #define reskined_laat_mk4_full_path(classname,displayname,texturebody,texturewing)\
  18. class macro_new_vehicle(laat,classname):macro_new_vehicle(laat,Mk4)\
  19. {\
  20. forceInGarage = 0;\
  21. displayName=LAAT/I MK.IV - ('##displayname##') ;\
  22. hiddenSelectionsTextures[]={texturebody,texturewing};\
  23. };
  24. class CfgPatches
  25. {
  26. class macro_patch_name(LAAT)
  27. {
  28. addonRootClass=macro_patch_name(vehicles)
  29. requiredAddons[]=
  30. {
  31. macro_patch_name(vehicles),
  32. "3AS_LAAT"
  33. };
  34. requiredVersion=0.1;
  35. units[]=
  36. {
  37. macro_new_vehicle(laat,Mk1),
  38. macro_new_vehicle(laat,Mk1_lights),
  39. macro_new_vehicle(laat,Mk2),
  40. macro_new_vehicle(laat,Mk2_lights),
  41. macro_new_vehicle(laat,LE)
  42. };
  43. weapons[]=
  44. {
  45. };
  46. };
  47. };
  48. #include "../../common/sensor_templates.hpp"
  49. class DefaultEventhandlers;
  50. class CfgVehicles
  51. {
  52. #include "inheritance.hpp"
  53. class macro_new_vehicle(laat,Mk1):3as_LAAT_Mk1
  54. {
  55. displayName="LAAT/I MK.I";
  56. #include "common_stuff_tcw.hpp"
  57. RD501_magclamp_small_1[] = {0.0,1.0,-1.0};
  58. class UserActions: UserActions
  59. {
  60. #include "user_action.hpp"
  61. };
  62. hiddenSelectionsTextures[]=
  63. {
  64. "RD501_Vehicles\textures\LAAT\laat_wings_doors_basecolor.paa",
  65. "RD501_Vehicles\textures\LAAT\laat_base_basecolor.paa"
  66. };
  67. class Turrets: Turrets
  68. {
  69. class Gunner: Copilot
  70. {
  71. minelev=-60;
  72. minturn=-240;
  73. maxelev=40;
  74. maxturn=-120;
  75. #include "../../common/common_optics.hpp"
  76. weapons[]=
  77. {
  78. macro_new_weapon(generic,republic_aircraft_cannon),
  79. "Laserdesignator_pilotCamera"
  80. };
  81. magazines[]=
  82. {
  83. "Laserbatteries",
  84. macro_new_mag(generic_aircraft_gun_green,1000),
  85. macro_new_mag(generic_aircraft_gun_green,1000),
  86. macro_new_mag(generic_aircraft_gun_green,1000)
  87. };
  88. #include "../../common/common_optics.hpp"
  89. memorypointgunneroptics="FIXME";
  90. };
  91. class LeftDoorgun: LeftDoorgun
  92. {
  93. weapons[]=
  94. {
  95. macro_new_weapon(turret,laat_ball_beam_l),
  96. "Laserdesignator_pilotCamera"
  97. };
  98. magazines[]=
  99. {
  100. "Laserbatteries",
  101. macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),
  102. macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),
  103. macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300)
  104. };
  105. #include "../../common/common_optics.hpp"
  106. memorypointgunneroptics="FIXME";
  107. };
  108. class RightDoorGun: RightDoorGun
  109. {
  110. weapons[]=
  111. {
  112. macro_new_weapon(turret,laat_ball_beam_r),
  113. "Laserdesignator_pilotCamera"
  114. };
  115. magazines[]=
  116. {
  117. "Laserbatteries",
  118. macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),
  119. macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),
  120. macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300),macro_new_mag(laat_ball_beam,300)
  121. };
  122. #include "../../common/common_optics.hpp"
  123. memorypointgunneroptics="FIXME";
  124. };
  125. class CargoTurret_01: CargoTurret_01{};
  126. class CargoTurret_02: CargoTurret_02{};
  127. class CargoTurret_03: CargoTurret_03{};
  128. class CargoTurret_04: CargoTurret_04{};
  129. class CargoTurret_05: CargoTurret_05{};
  130. class CargoTurret_06: CargoTurret_06{};
  131. };
  132. };
  133. class macro_new_vehicle(laat,Mk1_lights):3as_LAAT_Mk1Lights
  134. {
  135. displayName="LAAT/I MK.I (Lights)";
  136. #include "common_stuff_tcw.hpp"
  137. RD501_magclamp_small_1[] = {0.0,1.0,-1.0};
  138. class UserActions: UserActions
  139. {
  140. #include "user_action.hpp"
  141. };
  142. hiddenSelectionsTextures[]=
  143. {
  144. "RD501_Vehicles\textures\LAAT\laat_wings_doors_basecolor.paa",
  145. "RD501_Vehicles\textures\LAAT\laat_base_basecolor.paa"
  146. };
  147. class Turrets: Turrets
  148. {
  149. class Gunner: Copilot
  150. {
  151. minelev=-60;
  152. minturn=-240;
  153. maxelev=40;
  154. maxturn=-120;
  155. weapons[]=
  156. {
  157. macro_new_weapon(generic,republic_aircraft_cannon),
  158. "Laserdesignator_pilotCamera"
  159. };
  160. magazines[]=
  161. {
  162. "Laserbatteries",
  163. macro_new_mag(generic_aircraft_gun_green,1000),
  164. macro_new_mag(generic_aircraft_gun_green,1000),
  165. macro_new_mag(generic_aircraft_gun_green,1000)
  166. };
  167. #include "../../common/common_optics.hpp"
  168. };
  169. class CargoTurret_01: CargoTurret_01{};
  170. class CargoTurret_02: CargoTurret_02{};
  171. class CargoTurret_03: CargoTurret_03{};
  172. class CargoTurret_04: CargoTurret_04{};
  173. class CargoTurret_05: CargoTurret_05{};
  174. class CargoTurret_06: CargoTurret_06{};
  175. };
  176. };
  177. class macro_new_vehicle(laat,Mk2):3as_LAAT_Mk2
  178. {
  179. displayName="LAAT/I MK.II";
  180. #include "common_stuff_tcw.hpp"
  181. RD501_magclamp_small_1[] = {0.0,1.0,-1.0};
  182. class UserActions: UserActions
  183. {
  184. #include "user_action.hpp"
  185. };
  186. hiddenSelectionsTextures[]=
  187. {
  188. "RD501_Vehicles\textures\LAAT\laat_wings_doors_basecolor.paa",
  189. "RD501_Vehicles\textures\LAAT\laat_base_basecolor.paa"
  190. };
  191. class Turrets: Turrets
  192. {
  193. class Gunner: Copilot
  194. {
  195. minelev=-60;
  196. minturn=-240;
  197. maxelev=40;
  198. maxturn=-120;
  199. weapons[]=
  200. {
  201. macro_new_weapon(generic,republic_aircraft_cannon),
  202. "Laserdesignator_pilotCamera"
  203. };
  204. magazines[]=
  205. {
  206. "Laserbatteries",
  207. macro_new_mag(generic_aircraft_gun_green,1000),
  208. macro_new_mag(generic_aircraft_gun_green,1000),
  209. macro_new_mag(generic_aircraft_gun_green,1000)
  210. };
  211. #include "../../common/common_optics.hpp"
  212. };
  213. class CargoTurret_01: CargoTurret_01{};
  214. class CargoTurret_02: CargoTurret_02{};
  215. };
  216. };
  217. class macro_new_vehicle(laat,Mk2_lights):3as_LAAT_Mk2Lights
  218. {
  219. displayName="LAAT/I MK.II (Lights)";
  220. #include "common_stuff_tcw.hpp"
  221. RD501_magclamp_small_1[] = {0.0,1.0,-1.0};
  222. class UserActions: UserActions
  223. {
  224. #include "user_action.hpp"
  225. };
  226. hiddenSelectionsTextures[]=
  227. {
  228. "RD501_Vehicles\textures\LAAT\laat_wings_doors_basecolor.paa",
  229. "RD501_Vehicles\textures\LAAT\laat_base_basecolor.paa"
  230. };
  231. class Turrets: Turrets
  232. {
  233. class Gunner: Copilot
  234. {
  235. minelev=-60;
  236. minturn=-240;
  237. maxelev=40;
  238. maxturn=-120;
  239. weapons[]=
  240. {
  241. macro_new_weapon(generic,republic_aircraft_cannon),
  242. "Laserdesignator_pilotCamera"
  243. };
  244. magazines[]=
  245. {
  246. "Laserbatteries",
  247. macro_new_mag(generic_aircraft_gun_green,1000),
  248. macro_new_mag(generic_aircraft_gun_green,1000),
  249. macro_new_mag(generic_aircraft_gun_green,1000)
  250. };
  251. #include "../../common/common_optics.hpp"
  252. };
  253. class CargoTurret_01: CargoTurret_01{};
  254. class CargoTurret_02: CargoTurret_02{};
  255. };
  256. };
  257. class macro_new_vehicle(laat,LE):3AS_Patrol_LAAT_Republic
  258. {
  259. displayName="Republic LAAT/LE";
  260. scope=2;
  261. author="RD501";
  262. forceInGarage = 1;
  263. RD501_magclamp_large_offset[] = {0.0, 0.0, -3.5};
  264. RD501_magclamp_small_offset[] = {0.0, 0.0, -3.5};
  265. faction = macro_republic_faction
  266. editorSubcategory = macro_editor_cat_air(Republic_heli)
  267. vehicleClass = macro_editor_vehicle_type_air(Republic)
  268. transportSoldier=14;
  269. class UserActions
  270. {
  271. class ThrusterEngage
  272. {
  273. displayName = "";
  274. displayNameDefault = "";
  275. textToolTip = "";
  276. position = "pilotview";
  277. radius = 20;
  278. priority = 0;
  279. onlyForPlayer = 1;
  280. condition = "((player == driver this) AND (alive this))";
  281. statement = "this execVM ""\RD501_Main\functions\impulse\fnc_impulseIncrease_LE.sqf""";
  282. shortcut="User19"
  283. };
  284. class ThrusterDisengage: ThrusterEngage
  285. {
  286. priority = 0;
  287. displayName = "";
  288. displayNameDefault = "";
  289. textToolTip = "";
  290. condition = "((player == driver this) AND (alive this))";
  291. statement = "this execVM ""\RD501_Main\functions\impulse\fnc_impulseDecrease_LE.sqf""";
  292. shortcut="User20"
  293. };
  294. };
  295. RD501_magclamp_small_1[] = {0.0,1.0,-1.0};
  296. enableManualFire=1;
  297. weapons[]=
  298. {
  299. macro_new_weapon(generic,republic_aircraft_cannon),
  300. "Bomb_Leaflets",
  301. macro_new_weapon(wynd,ugm),
  302. "Laserdesignator_pilotCamera"
  303. };
  304. magazines[]=
  305. {
  306. "Laserbatteries",
  307. "1Rnd_Leaflets_Civ_F",
  308. "1Rnd_Leaflets_Civ_F",
  309. "1Rnd_Leaflets_Civ_F",
  310. "1Rnd_Leaflets_Civ_F",
  311. macro_new_mag(ugm,10),
  312. macro_new_mag(generic_aircraft_gun_green,1000)
  313. };
  314. class Turrets: Turrets
  315. {
  316. class Gunner: Copilot
  317. {
  318. outGunnerMayFire=1;
  319. commanding=-1;
  320. primaryGunner=1;
  321. weapons[]=
  322. {
  323. macro_new_weapon(generic,republic_aircraft_cannon),
  324. "Laserdesignator_pilotCamera"
  325. };
  326. magazines[]=
  327. {
  328. "Laserbatteries",
  329. macro_new_mag(generic_aircraft_gun_green,1000)
  330. };
  331. #include "../../common/common_optics.hpp"
  332. };
  333. };
  334. };
  335. };