Blitzen88 16 Posted September 8, 2020 Greetings, I'm having an issue hiding "forgotten" units with the Military Symbols Module (aka Marta). The module correctly assigns military symbols to enemy units which have been identified but does not remove the symbol when that unit has lost contact with friendly forces. In other words, once a unit is identified, the Marta symbol stays with that unit until its death. Is there any way to fix this issue? I have tried both changing both of the following values: BIS_marta_mainscope setVariable ["delay", 0.1]; BIS_marta_mainscope setVariable ["duration", 600]; However neither command seems to work. If it is not possible to implement this by changing values, then is it possible to fix it via a script? Something sort of loop along the lines of: If player side does not know about enemygroup, then Marta_hide foreach unknown group...? I cant seem to figure it out and any help would be appreciated Share this post Link to post Share on other sites
RafaDombras 24 Posted September 8, 2020 Hi! I had the same issue, but instead of solving it, I chose to disable markers in difficulty menu and use a custom marker script... If you find out how to, will be very useful! Share this post Link to post Share on other sites
Blitzen88 16 Posted September 8, 2020 7 minutes ago, RafaDombras said: Hi! I had the same issue, but instead of solving it, I chose to disable markers in difficulty menu and use a custom marker script... If you find out how to, will be very useful! Just as a backup do you mind sharing your marker script? 1 Share this post Link to post Share on other sites
RafaDombras 24 Posted September 9, 2020 I made a script to see only your group units on the map, you can use it to have some ideas... Units marked as triangles, changes angle to fit units actual direction, changes color when selected, changes icon when dead, then disappears. /////////////////////////////////////////////////////////////////////////// /// -=+++=-- Marker_unity.sqf -=+++=-- by:RAFADOMBRAS /// /////////////////////////////////////////////////////////////////////////// private ["_unit","_marker","_cnt","_markertype","_selectedUnits","_markercolor","_markertypedead","_grp"]; _unit = _this select 0; _markertype = _this select 1; _markertypedead = _this select 2; _grp = group _unit; while {true} do { if (!alive _unit) exitWith {}; if ( side _unit != side player ) exitWith {}; if (_markertype == "NOMARKER") exitWith {}; _marker = createMarker [ format ["%1", _unit] , getpos _unit]; _marker setMarkerType _markertype; if (side _unit == west) then {_markercolor = "ColorRed"; }; // change color here if (side _unit == east) then {_markercolor = "ColorYelow"; }; if (side _unit == independent) then {_markercolor = "ColorBlue"; }; while {alive _unit} do { _marker setMarkerPos getpos _unit; _marker setMarkerDir getDir _unit; _selectedUnits = groupSelectedUnits _unit; _cnt = {_x == _unit} count _selectedUnits; if (_cnt > 0) then {_marker setMarkerColor "ColorGreen"} else {_marker setMarkerColor _markercolor}; if ( side _unit != side player ) exitWith {}; sleep 0.1; }; if (!alive _unit) then {_marker setMarkerType _markertypedead}; if (!alive _unit) then {_marker setMarkerDir 0}; if (!alive _unit) then {sleep 10}; deleteMarker _marker; }; You can start the script on player init: {[ _x, "mil_triangle", "loc_Church" ] execVM "Marker_unity.sqf";} foreach units group player; Maybe I can do a script to show spotted enemy units, that disappears a few seconds after lose contact... I use triangle, but you can choose any marker when loading the script... Share this post Link to post Share on other sites
pierremgi 4740 Posted September 10, 2020 That looks like this post. Share this post Link to post Share on other sites
Blitzen88 16 Posted September 10, 2020 7 hours ago, pierremgi said: That looks like this post. Trust me, I have been looking a loooottt at that post. The original poster in that thread actually asks, at the end, how to set the “duration” setting for Marta and seems to indicate that it was not working. Share this post Link to post Share on other sites
pierremgi 4740 Posted September 10, 2020 Based on the link, I give you this solution: In initPlayerLocal.sqf: setGroupIconsVisible [true,false]; [] spawn { while {true} do { uiSleep 2; player setVariable [ "MARTA_REVEAL", allGroups select {units _x findIf {group player knowsAbout _x > 1.5}>-1}]; player setVariable [ "MARTA_HIDE", allGroups select {units _x findIf {group player knowsAbout _x > 1.5}==-1}]; } }; Share this post Link to post Share on other sites
Blitzen88 16 Posted September 11, 2020 8 hours ago, pierremgi said: Based on the link, I give you this solution: In initPlayerLocal.sqf: setGroupIconsVisible [true,false]; [] spawn { while {true} do { uiSleep 2; player setVariable [ "MARTA_REVEAL", allGroups select {units _x findIf {group player knowsAbout _x > 1.5}>-1}]; player setVariable [ "MARTA_HIDE", allGroups select {units _x findIf {group player knowsAbout _x > 1.5}==-1}]; } }; I tried this and it didnt seem to work. Here is what I did: Copied and pasted the code into init.sqf Identified a CSAT unit and then ran to the other side of the map The CSAT marker remained visible even when the unit was on the other side of the map. I suppose this test is based off of the assumption that the unit will no longer know about a target after a certain distance Is there any way to use BIS_Marta_getVisibleGroups to get a list of id'd groups, filter that list down to a selection of enemy groups, and then run that list of enemy groups to see if the players side knows about that particular unit? If not, then get rid of the marker(s)? If this is possible, then I dont believe you could use Marta_Hide because there is a chance that enemy unit could be re-identified after its initial identification Also, just out of curiosity, what does this part of the script do/mean: >-1}]; ==-1}]; Thank you for your help Share this post Link to post Share on other sites
pierremgi 4740 Posted September 11, 2020 The code is tested and works. You need to wait for any unit of the group player with a "knowsAbout" to zero (less than 1.5 but you will not see the difference in this way) on any unit of the marked group. That can take several minutes (at least 2). The code is in initPlayerLocal.sqf. Player doesn't mean anything on dedicated server. The loop shouldn't be necessary, but for some reason (loops in FSM's module in fact) MARTA_REVEAL can update new detected group but MARTA_HIDE can't forget them. So, the loop. If you have another solution feel free to share it! Without condition, the marta module is triggering for a knowsAbout > 3.3 (why not). The knowsAbout is also limited by view distance on its own. In module codes, there are several cases (rules) but they are poorly scripted and this module is a little bit... short or even abandoned. As you can see, there is no parameter on it. For you curiosity, refer to BIKI: findIf NOTE: you can add any condition you want. The knowsAbout is what is commonly used for "forgotten" units. 1 Share this post Link to post Share on other sites