config.cpp 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184
  1. #include "../RD501_main/config_macros.hpp"
  2. class CfgPatches
  3. {
  4. class macro_patch_name(stretcher)
  5. {
  6. requiredAddons[] = {
  7. macro_lvl2_req
  8. };
  9. requiredVersion = 0.1;
  10. units[] = {
  11. };
  12. weapons[] = {};
  13. };
  14. };
  15. class CfgVehicles
  16. {
  17. class Man;
  18. class StaticATWeapon;
  19. class ThingX;
  20. class car_f;
  21. class Kart_01_Base_F;
  22. class CAManBase: Man
  23. {
  24. class ACE_SelfActions
  25. {
  26. class ACE_Equipment
  27. {
  28. class RD501_Deploy_Stretcher
  29. {
  30. displayName = "Deploy Stretcher";
  31. condition = [player,macro_single_quote(macro_new_weapon(Stretcher,Item))] call ace_common_fnc_hasItem;
  32. statement = [player, macro_single_quote(macro_new_vehicle(Stretcher,MkII)), macro_single_quote(macro_new_weapon(Stretcher,Item))] call macro_fnc_name(deploy_stretcher);
  33. showDisabled = 0;
  34. priority = 2.5;
  35. };
  36. };
  37. };
  38. };
  39. class macro_new_vehicle(Stretcher,MkII): Kart_01_Base_F
  40. {
  41. forceInGarage=1;
  42. transportSoldier = 1;
  43. scope = 2;
  44. hasdriver = 0;
  45. slingLoadCargoMemoryPoints[] = {"SlingLoadCargo1","SlingLoadCargo2","SlingLoadCargo3","SlingLoadCargo4"};
  46. class Turrets{};
  47. class AnimationSources{};
  48. memoryPointsGetInCargo = "pos cargo";
  49. memoryPointsGetInCargoDir = "pos cargo dir";
  50. displayName = "Stretcher Mk.II";
  51. Model = "\501RDStretcher\model\501_Stretcher.p3d";
  52. cargoAction[] = {"passenger_injured_medevac_truck02"};
  53. ejectDeadCargo = 0;
  54. armor=100000;
  55. // Dragging
  56. ace_dragging_canDrag = 1; // Can be dragged (0-no, 1-yes)
  57. ace_dragging_dragPosition[] = {0, 1, 1}; // Offset of the model from the body while dragging (same as attachTo)
  58. ace_dragging_dragDirection = 0; // Model direction while dragging (same as setDir after attachTo)
  59. // Carrying
  60. ace_dragging_canCarry = 1; // Can be carried (0-no, 1-yes)
  61. ace_dragging_carryPosition[] = {0, 0, 0}; // Offset of the model from the body while dragging (same as attachTo)
  62. ace_dragging_carryDirection = 0; // Model direction while dragging (same as setDir after attachTo)
  63. class VehicleTransport
  64. {
  65. class Cargo
  66. {
  67. parachuteClass = "B_Parachute_02_F";
  68. parachuteHeightLimit = 5;
  69. canBeTransported = 1;
  70. dimensions[] = {"VTV_Cargo_Base","VTV_Cargo_Corner"};
  71. };
  72. };
  73. class ACE_Actions
  74. {
  75. class ACE_MainActions
  76. {
  77. selection = "ACE_Point";
  78. distance = 5;
  79. condition = "true";
  80. class RD501_Pick_Up_Stretcher
  81. {
  82. displayName = "Put Stretcher in backppack";
  83. distance = 5;
  84. condition = "((count (crew _target)) == 0) && (isNull attachedTo _target)";
  85. statement = [player,_target,macro_single_quote(macro_new_weapon(Stretcher,Item))] call macro_fnc_name(put_stretcher_in_backpack);
  86. showDisabled = 0;
  87. priority = 5;
  88. };
  89. class RD501_Transport_Stretcher
  90. {
  91. displayName = "Carry Stretcher";
  92. distance = 5;
  93. condition = "(isNull attachedTo _target)";
  94. statement = [player,_target] call macro_fnc_name(carry_stretcher);
  95. showDisabled = 0;
  96. priority = 5;
  97. };
  98. class RD501_Drop_Stretcher
  99. {
  100. displayName = "Stop Carrying Stretcher";
  101. distance = 5;
  102. condition = "!(isNull attachedTo _target)";
  103. statement = _target call macro_fnc_name(drop_stretcher);
  104. showDisabled = 0;
  105. priority = 5;
  106. };
  107. class ACE_Passengers
  108. {
  109. displayName = "$STR_ace_interaction_Passengers";
  110. condition = "alive _target";
  111. statement = "";
  112. exceptions[] = {"isNotSwimming"};
  113. insertChildren = "_this call ace_interaction_fnc_addPassengersActions";
  114. };
  115. };
  116. };
  117. class ACE_SelfActions
  118. {
  119. class ACE_Passengers
  120. {
  121. displayName = "$STR_ace_interaction_Passengers";
  122. condition = "alive _target";
  123. statement = "";
  124. insertChildren = "_this call ace_interaction_fnc_addPassengersActions";
  125. };
  126. };
  127. class Eventhandlers
  128. {
  129. init = "(_this select 0) allowdamage false;";
  130. };
  131. macro_new_config_prop(stretcher_item) = macro_new_weapon(Stretcher,Item);
  132. };
  133. };
  134. class CfgWeapons
  135. {
  136. class ItemCore;
  137. class InventoryItem_Base_F;
  138. class macro_new_weapon(Stretcher,Item_Base): ItemCore
  139. {
  140. type = 4096;
  141. detectRange = -1;
  142. simulation = "ItemMineDetector";
  143. scope = 0;
  144. cost = 1000;
  145. side = 3;
  146. author = "Namenai";
  147. };
  148. class macro_new_weapon(Stretcher,Item): macro_new_weapon(Stretcher,Item_Base)
  149. {
  150. displayName = "Republic Stretcher";
  151. scope = 2;
  152. author = "Namenai";
  153. picture = "\mcc_sandbox_mod\data\items\bandage.paa";
  154. model = "\A3\Structures_F_EPA\Items\Medical\Bandage_F.p3d";
  155. class ItemInfo: InventoryItem_Base_F
  156. {
  157. mass = 225;
  158. };
  159. };
  160. };
  161. // class Extended_Init_EventHandlers
  162. // {
  163. // //class name of the object
  164. // class macro_new_vehicle(Stretcher,MkII)
  165. // {
  166. // //doesnt matter wat this is
  167. // class init_Stretcher
  168. // {
  169. // init = [_this select 0] spawn macro_fnc_name(init_stretcher);
  170. // };
  171. // };
  172. // }