Jump to content

opusfmspol

Member
  • Content count

    459
  • Joined

  • Last visited

  • Medals

Community Reputation

82 Excellent

3 Followers

About opusfmspol

  • Rank
    Gunnery Sergeant

Profile Information

  • Gender
    Not Telling

Recent Profile Visitors

1076 profile views
  1. It took painful tracking through the CBA and ACE addons. The short of it: 1. Review the wiki preprocessor commands, including its discussion page. As you've already seen, CBA and ACE use complex macros. You have to be familiar with the preprocessor commands to understand how the macros work. 2. Review the CBA_Main file script_macros_common.hpp. This is where the commonly used CBA macros get defined, with descriptions of their use. The authors are also identified within. 3. Review the files of CBA_Events PBO. It has various CBA function scripts, and each identify their authors. 4. Review ACE_sys_wounds file XEH_preInit.sqf. This is where various ACE Wounds variables, functions and events get defined. The steps taken and reasoning why; I'm hoping this was more clear than mud. I took the journey so I understand, I hope you also can. In your init.sqf try the following: Note: I didn't do extensive playtesting. This assumes ACE doesn't add any further blocks of code to the array during the mission. When in doubt: diag_log (CBA_eventHandlers getVariable "ace_sys_wounds_selleader"); and check the .rpt log.
  2. How to build planes

    The BIS Warfare missions in OA don't have planes available. I know of three ways to have planes available in Warfare missions, but in all cases it is done with a mission in the editor: Method 1. Add planes to the Aircraft Factories. Darren Brant shows one way to do it. A simpler way is to use Warfare's BIS_WF_AddUnitData function. The function can be used on the hangars too if method (2) or (3) is used. But adding to the Aircraft Factory might not be the best choice, most planes need runways to take off. Base could be anywhere. Method 2. Using A2 or Combined Ops (A2 + OA), place an Airport hangar and marker, then add the code which makes the hangar become an airport where planes are bought. The Chernarus mission "Superpowers" uses this method for players to buy planes. The hardest part is finding a good location for the hangar. But those who have OA only (no Arma 2) do not have the hangar listed in editor, so they cannot use this method. They have to use method (1) or (3). Method 3. Use a hangar that already exists on the map. This is done by placing an Airport game logic and marker there, add the code so it serves as an airport, and then do a custom Warfare init so that one of the scripts can identify the logic as an airport. The InitMission is added to the mission file sort of how Darren Brant shows, but a little different. Two scripts are copied from the Warfare module and get modified so the logic is identified as an airport.
  3. Found that (CBA_eventHandlers getVariable "ace_sys_wounds_selleader") returns the QGVAR(selLeader) code stored in an array. So I ran the following code using a radio trigger after mission start, and it worked. The hint was shown when a leader went unconscious: niv = [] spawn { waitUntil {!isNull CBA_eventHandlers}; waitUntil {!isNil {CBA_eventHandlers getVariable "ace_sys_wounds_selleader"}}; waitUntil {count (CBA_eventHandlers getVariable "ace_sys_wounds_selleader") > 0}; _newCode = {hint "New leader being selected"}; CBA_eventHandlers setVariable ["ace_sys_wounds_selleader",[_newCode],true]; }; Hopefully this can help you with changing the code to something that works for your mission.
  4. Someone with more CBA and ACE2 experience could probably help with this better than I could. I haven't used CBA handlers in scripts. An ACE extended event handler appears to control who takes leader when the leader goes unconscious. There might be a CBA function which could be used to replace the handler after preinit is done (i.e., during init.sqf or initJIPcompatible.sqf), but I wouldn't know what function or the params to call it properly. Observe this block in blackoutp.sqf (and the block in blackoutai.sqf is similar): It interprets as: "If player is group leader, identify a new leader (_newl); if _newl is not null, call a CBA globalevent using QGVAR(selLeader), and have each of the other group members doFollow." The code used by the global event to select leader can be found near the bottom of "XEH_preinit.sqf" in ACE_Wounds. Look for QGVAR(selLeader). Params from above are [_grp, _newl]. {if (local (leader (_this select 0))) then {(_this select 0) selectLeader (_this select 1)}} My thought is that you would want to revise/replace that handler code after it becomes set, so that generic groups would do the default but certain groups would selectLeader another way or not at all, however you decide. All I did was run a simple test for the ACE 'unconscious' variable state using a radio trigger.
  5. Now I remember why ACE and CBA scripts give me such a headache. <sigh> Looked into it a bit and seems ACE uses playActionNow and switchMove for the animations, and stored variables to track the state. I suspect the ACE unconscious state your seeking might be: (_unit getVariable "ace_sys_wounds_uncon"). Comes from this line: _unit setVariable [QGVAR(uncon), true]; QGVAR comes from CBA_main, it's the passed component as a string, with the (var) variable added to the end. In this case the component is "ace_sys_wounds". Where the ACE script uses QGVAR(uncon) it translates to "ace_sys_wounds_uncon" _unit setVariable [QGVAR(uncon), true]; translates to _unit setVariable ["ace_sys_wounds_uncon", true]; Be aware, it can return nil. When I tested, it returned false for player at mission start. But for AI it returned nil, until he got wounded. It then returned false, until he fell unconscious at which time it returned true.
  6. Haven't dug through ACE scripts, but I would suspect they use the setUnconscious command, and the status can be checked with the lifeState command. An observation on the handler you found, selectLeader would be the only line doing anything in A2 or OA. The params and setGroupOwner commands were introduced in Arma 3. If not stopping script or causing error, they would be ignored. For A2 or OA, one could use private as alternative to the params command: , but I don't think setGroupOwner has any alternative available in A2/OA, unless somebody else knows better. With selectLeader the group does have to be local for it to work. The local command can detect locality of a group in A3, but not in A2 or OA. I once sought an A2/OA alternative for that because GC (Garbage Collector module, runs on server) seems not to delete groups in queue when they're not local to server. But I could never find any alternative to detect locality of particular groups in A2/OA (i.e., which machine created the group, or now has locality, when not local to the server; see deleteGroup description).
  7. I've been playing A2 mission "07: Freedom Fighters" and in doing so discovered a Warfare issue in Teams config. It's also in OA warfare teams config. At bottom of Config_Teams.sqf is the Resistance AI Commander's preference for team types. These are the templates AI Commander assigns to teams at mission start : //AI commander preferences for AI teams. _t = ["InfantryFT"]; _t = _t + ["InfantryAT"]; _t = _t + ["MechanizedLight"]; <--- here _t = _t + ["TankLight"]; _t = _t + ["ReconLight"]; _t = _t + ["TankLight"]; _t = _t + ["ReconHeavy"]; _t = _t + ["SpecOps"]; ResistanceAITeamTemplates = _t; The problem is with "MechanizedLight" for Team 3. Resistance "MechanizedLight" is a V3S transport truck. The template consists of a single unit (V3S driver). Single unit template types should only be used for squads (i.e., infantry team + V3S = motorized infantry). And looking at the Resistance infantry squads one can see, that is how it gets used: The issue is that single-unit teams will never update or upgrade their template. It always remains a one man team. Player Commander can reassign the team as Infantry, SpecOps, etc., whatever, the team will never switch to another template (although it will switch type). It will always remain as the single-unit template. This is quickly observed launching "Freedom Fighters": - Launch mission. - Go to map, vote player as commander. Wait for player to assume command. - select "Teams" from diary. - On Teams panel, Team 3 displays quantity: 1 of 1 units (V3S leader as driver but no vehicle). - Select Team 3, select "Set Type". - Select Infantry or SpecOps, select "Set Type". - Select "Respawn". - Wait for leader to be alive. - Wait for the template to switch... and wait... and wait... and wait... and wait.... The template never switches because the template is a one-man team. The cause: So the AI commander preference "MechanizedLight" should be something else. Even in other A2 warfare missions, or Takistan map Warfare2_E mission "CTI 24 Mountain Warfare" (OA), the Resistance team 3 being "MechanizedLight" suffers from the exact same. It's just one lone leader running around or driving a V3S to capture points, and will never switch to another template. My suggestion would be "ReconLight", a pickup PK and offroad Dshkm. It's a four man team, which allows player commander to switch the team type when they have no factory available.
  8. Running current beta A2 and OA, I activated CBA and ShackTac Movement mods, and didn't have that message occur in .rpt log when launching those particular missions. It might be mod specific. Usual advice is deactivate all mods, then activate them one at a time until the issue occurs. Perhaps a mod is deleting one of the addons used by the mission or Warfare. Or a mod is using Call command in a config init event to activate addons. Or I'm wondering, 'downloadable content', might that be reference to ACR, BAF, or PMC? Running those two mods, in CO, the only issue I got was a pop-up error I reported months ago (not mod related). "Warning Message: 'iconStaticObject/' is not a class ( ' ' accessed)" occurs when player commander first deploys HQ, or first deploys a base structure after taking command from AI. Doesn't occur in A2. In A2, CBA gives me a pop-up at A2 launch, "Warning Message: Addon 'cba_xeh_oa' requires addon 'CA_CommunityConfigurationProject_E' ", but CBA still runs (logs .rpt errors). But no messages of that sort occurred when launching those missions in A2 or CO. Could you post the portion of your .rpt where it logs? In my experience those type messages should name what's missing. When evaluating what might be missing (if not listed in the log), maybe consider the mods being used, what they likely do, and compare that with the addons being used in the missions: Superpowers, addons listed in mission.sqm: When Diplomacy Fails, addons listed in mission.sqm: Warfare also uses the activateAddons command in scripts during initialization, which according to a note from UNN (emphasis added), "If executed from a configs init event with the call command, it will effectively override a missions required addons, preventing them from being activated (Appears to only happen in multi player). To activate the passed addons along with those defined in the mission.sqm, execute the command from a configs init event using spawn or execVM." The addons in Warfare scripts get called within an execVM from its cfg eventHandler. The execVM launches the scripts, which use activateAddons in Call commands. The execVM in config event would be preventing the override mentioned by UNN. Warfare2Vehicles.pbo, has the config init event: (Note: The Warfare module placed in editor map actually initializes Warfare2Vehicles.pbo, the Warfare2.pbo serves as repository for the scripts and addons used by Warfare.) Warfare2.pbo, in the Init.sqf: InitMission.sqf, to initialize clients and server: Init_Common.sqf, activates addons: Init_Server.sqf, activates addon:
  9. I find it odd also how action disappears when player gets attached. No idea why. Have you tried Norrin's attachTo scripts to see if they help? They use key presses for rotate or dismount. attachto template 1 - Scripted Ride On APC by norrin
  10. Not tested, but maybe try using blacklist checking. _item = "myMarkerName"; _newlist = []; // from ACM's blacklistArea function (BIS_ACM_blacklistAreaFunc), registering a blacklist marker area, // _tl and _br represent top-left and bottom-right positions of the marker: private ["_pos", "_size", "_tl", "_br"]; _pos = markerPos _item; _size = markerSize _item; _tl = [(_pos select 0) - (_size select 0), (_pos select 1) + (_size select 1)]; _br = [(_pos select 0) + (_size select 0), (_pos select 1) - (_size select 1)]; _newList = _newList + [[_tl, _br]]; // Should return true if object position is in the marker boundaries. _inArea = [(position _object), _newlist] call BIS_fnc_isPosBlacklisted;
  11. Hopefully these might have an answer, but don't know: Waypoint Waypoints Waypoint types 2D Editor: Waypoints
  12. The wiki instructions don't mention it, but set the UAV's "Special" field to 'Flying' so it will spawn in airborne at mission start. 'flyInHeight' just sets a cruising altitude once airborne.
  13. I was just preparing to post, have been receiving these new errors from Russian side in Warfare missions. Is this what is resolved? Error in HTML file Context 4 Warning Message: Cannot load material file corepatch\corepatch_vehicles\textures\brdm2_01_damage.rvmat. Cannot load material file corepatch\corepatch_vehicles\textures\brdm2_01_damage.rvmat Warning Message: Cannot load material file corepatch\corepatch_vehicles\textures\brdm2_01_destruct.rvmat. Cannot load material file corepatch\corepatch_vehicles\textures\brdm2_01_destruct.rvmat Warning Message: Cannot load material file corepatch\corepatch_vehicles\textures\brdm2_02_damage.rvmat. Cannot load material file corepatch\corepatch_vehicles\textures\brdm2_02_damage.rvmat Warning Message: Cannot load material file corepatch\corepatch_vehicles\textures\brdm2_02_destruct.rvmat. Cannot load material file corepatch\corepatch_vehicles\textures\brdm2_02_destruct.rvmat Also have noticed that with latest update, the lag on first SOM SecOp is resolved using current beta A2 & CO. yay! Thank You so much!!
  14. Not the Alice module itself, but in Warfare (of both A2\Addons and OA\Expansion), towards the end of the Init_Server, it creates only "AliceManager". Would probably be good if it created the correct Alice based on the Warfare module used, A2 or OA. I'm unaware of any of the distributed missions it would negatively impact. For my own OA missions, I've been replacing this: with this: and have been getting OA civilians walking or running about and driving cars in Warfare missions, where before there would be none.
  15. They're not the same. I was running A2 stable. Switched A2 back to beta, and received the update to missions, modules and warfare. So test them, yes. What I see so far, the 'Bear Rising' airport issue is resolved in A2 and OA. The SOM lag on first SecOp has been resolved for standalone OA but still occurs in A2 and CO, the A2\Addons SOM hasn't yet gotten the init.sqf that the OA\Common SOM updated with. A2\Addons isn't showing update to languages and languagemissions pbo's, but OA\Expansion does. --edit: Also Silvie error in A2 from using an OA command is resolved. RU faction in Warfare builds "KORD_high" defense where config had "DSHKM_RU" before. -- Not seen in game, but found the Warfare2 squads config in the example missions have a bad 'for-do' count resolved. The same error in Warfare2_e squads config is not yet corrected. An OA squads config in Warfare2 is used which has the correction, so the Warfare2_e squads config has been redundant, but is an issue when mission makers have a custom init compiling squads from the Warfare2_e config. Which could be the case where they copied an older WF Init_Common.sqf and used it in their mission. Would be good if the Warfare2_e squads config gets corrected too. (Basically replacing the squads config of Warfare2_e with a copy of the corrected one in Warfare2 'OA' folder. Then the corrected config would run whether mission makers copied an older or newer Init_Common.)
×