ArmaAchilles / Achilles

Achilles is a gameplay modification for Arma 3. It expands the Zeus real-time editor with many new additions as well as provides bug fixes.
Other
75 stars 54 forks source link

Improve mod-compability with Zeus waypoint definitions #491

Open kerckasha opened 5 years ago

kerckasha commented 5 years ago

Arma 3 Version: 1.92 (stable)
CBA Version: 3.11.2 (stable)
Achilles Version: 1.2.1 (stable)

Mods:

- CBA_A3
- Achilles

Description: BI shortsightedly hard coded the waypoint definitions for Zeus in the RscAttributeWaypointType dialog, and Achilles currently overrides this dialog to add extra waypoints. This is fine until another mod wants to add their own waypoints and a conflict occurs but I have found a solution.

+= was added to config based arrays awhile back and does work in the Zeus waypoint dialog but is reliant on other addons using it for it to continue working, so while in my test addon += works with just Vanilla A3, if I run achilles alongside it Achilles overrides it, unless I set Achilles in my required addon.

Here's an example of how i set it up for Iron Front

names[] += {"configFile >> 'cfgWaypoints' >> 'LIB' >> 'LIB_AmphibiousAssault'","configFile >> 'cfgWaypoints' >> 'LIB' >> 'LIB_StaticLine'"};
strings[] += {"$STR_LIB_DN_AMPHIBIOUS_ASSAULT","$STR_LIB_DN_WP_StaticLine"};
kerckasha commented 5 years ago

image Here's an ingame example after I made a quick change to Achilles (obviously the two 'land' arent desired, or some of them missing (that's just my bad removing stuff that I thought already existed))

CreepPork commented 5 years ago

I'm trying to look the config up in GitHub and I can't find it because of our terrible mod structure. As you have made some changes already to Achilles, can you create a PR? That'll be great.

kerckasha commented 5 years ago

I can but there's one issue, achilles replaces some of the default ones (Land) and I'm unsure how to handle that as += can only add to existing arrays, not change values.

\addons\ui_f\dialogs\Replacement\RscDisplayWaypointAttributes.hpp is the file in question

CreepPork commented 5 years ago

Thanks for the file. Yeah, I dunno about that one either. My only guess is you could create a separate PBO for compatibility and override Achilles?