Jump to content
nkey

Task Force Arrowhead Radio

Recommended Posts

Is there a roadmap or plans about the future? Its been a while since the last version and i read much about what is beeing tought of for the future and so on ;)

 

Have plan to release new version. Could not say exact ETA - busy with another project (hope I'll able to announce it soon).

Share this post


Link to post
Share on other sites

 

player setVariable ["tf_receivingDistanceMultiplicator", 3, true];

player setVariable ["tf_sendingDistanceMultiplicator", 3, true];

 

don't seem to have a function right now. Is that intended?

 

#edit: I found out: player setVariable ["tf_sendingDistanceMultiplicator", 3, true]; does actually work. If setting "tf_receivingDistanceMultiplicator" to the same value as "tf_sendingDistanceMultiplicator", they seem to cancel each other out.

 

Thanks to this finding I present to you my relay-script:

/*
ADV_fnc_radioRelay - by Belbo (QA and approved by Nyaan)

This function turns a vehicle into a radio repeater for use with TFAR.
The distance multiplicator is applied to all units of the side provided if at least one radio repeater is up and running.
If a radio repeater is destroyed, damaged beyond 60% or descended below the given minimum height it will stop working as a radio repeater.
If the last radio repeater is deactivated, the distance multiplicator is removed for all units of the side provided.

Possible call - has to be executed on client and server:

in init.sqf:
[VEHICLE, west, 90] spawn ADV_fnc_radioRelay;
or
[VEHICLE, west, 90] spawn compile preprocessFileLineNumbers "fn_radioRelay";

or from a local client:
[VEHICLE, west, 90] remoteExec ["ADV_fnc_radioRelay",0];
or
{[VEHICLE, west, 90] spawn compile preprocessFileLineNumbers "fn_radioRelay";} remoteExec ["bis_fnc_spawn",0];
*/

params [
    ["_relay", objNull, [objNull]],
    ["_side", west, [west]],
    ["_minHeight", 10, [0]]
];

if !(isClass (configFile >> "CfgPatches" >> "task_force_radio")) exitWith {};

if (side player == _side) then {

    if ( isClass(configFile >> "CfgPatches" >> "ace_interact_menu") ) then {

        _ace_relayActionON = [
            "relayActionOn",
            ("<t color=""#00FF00"">" + ("ACTIVATE RADIO REPEATER") + "</t>"),
            "",
            { (_this select 0) setVariable [format ["adv_var_isRelay_%1",((_this select 2) select 0)],true,true]; systemChat "Radio repeater activated."; },
            { !((_this select 0) getVariable [format ["adv_var_isRelay_%1",(_this select 2) select 0],false]) && damage (_this select 0) < 0.4 },
            nil,[_side]
        ] call ace_interact_menu_fnc_createAction;
        
        _ace_relayActionOFF = [
            "relayActionOff",
            ("<t color=""#FF0000"">" + ("DEACTIVATE RADIO REPEATER") + "</t>"),
            "",
            { (_this select 0) setVariable [format ["adv_var_isRelay_%1",((_this select 2) select 0)],false,true]; systemChat "Radio repeater deactivated."; },
            { ((_this select 0) getVariable [format ["adv_var_isRelay_%1",(_this select 2) select 0],false]) && damage (_this select 0) < 0.6 },
            nil,[_side]
        ] call ace_interact_menu_fnc_createAction;
        
        [_relay , 0, ["ACE_MainActions"],_ace_relayActionON] call ace_interact_menu_fnc_addActionToObject;
        [_relay , 0, ["ACE_MainActions"],_ace_relayActionOFF] call ace_interact_menu_fnc_addActionToObject;
        
    } else {
    
        [_relay,_side] spawn {
            _relay = _this select 0;
            _side = _this select 1;
            
            while { alive _relay } do {
                waitUntil { sleep 1; (damage _relay) < 0.6 };
                _relay setVariable [format ["adv_var_isRelay_%1",_side],false,true];
            
                adv_handle_relayActionOn = _relay addAction [("<t color=""#00FF00"">" + ("Activate Radio Repeater") + "</t>"), {
                    (_this select 0) setVariable [format ["adv_var_isRelay_%1",((_this select 3) select 0)],true,true];
                    systemChat "Radio repeater activated.";
                    (_this select 0) removeAction (_this select 2);
                    adv_handle_relayActionOff = (_this select 0) addAction [("<t color=""#FF0000"">" + ("Deactivate Radio Repeater") + "</t>"), {
                        (_this select 0) setVariable [format ["adv_var_isRelay_%1",((_this select 3) select 0)],false,true];
                        systemChat "Radio repeater deactivated.";
                        (_this select 0) removeAction (_this select 2);
                    },_side,6,false,true,"","player distance _target <5"];
                },_side,6,false,true,"","player distance _target <5"];
                
                waitUntil { sleep 1; _relay getVariable (format ["adv_var_isRelay_%1",_side]) };
                waitUntil { sleep 1; ((damage _relay) > 0.6 || !alive _relay) || !(_relay getVariable (format ["adv_var_isRelay_%1",_side])) };
                if (!isNil "adv_handle_relayActionOff") then { _relay removeAction adv_handle_relayActionOff; };
            };
        };
    };
};

if (isServer) then {
    [_relay,_side,_minHeight] spawn {
        _relay = _this select 0;
        _side = _this select 1;
        _minHeight = _this select 2;
        while {alive _relay} do {
            waitUntil { sleep 1; damage _relay > 0.6 || !alive _relay || getTerrainHeightASL (getPos _relay) < _minHeight};
            _relay setVariable [format ["adv_var_isRelay_%1",_side],false,true];
            waitUntil { sleep 1; damage _relay < 0.4 || !alive _relay };
        };
    };
    if !( missionNamespace getVariable [format ["ADV_var_relayScriptHasRun_%1",_side],false] ) then {
        missionNamespace setVariable [format ["ADV_var_relayScriptHasRun_%1",_side],true,true];
        while {true} do {
            waitUntil { sleep 1; {_x getVariable [format ["adv_var_isRelay_%1",_side],false]} count (vehicles+allMissionObjects"Land_DataTerminal_01_F") > 0 };
            
            {
                if ( (side _x) == _side ) then {
                    _x setVariable ["tf_sendingDistanceMultiplicator", 2, true];
                };
            } forEach allPlayers;
            
            waitUntil { sleep 1; {_x getVariable [format ["adv_var_isRelay_%1",_side],false]} count (vehicles+allMissionObjects"Land_DataTerminal_01_F") == 0 };
            
            {
                if ( (side _x) == _side || (side _x) == sideEnemy ) then {
                    _x setVariable ["tf_sendingDistanceMultiplicator", 1, true];
                };
            } forEach allPlayers;
        };
    };
};

 

Cool ;)

 

Put 3 to sending and 0.333 to receiving.

Share this post


Link to post
Share on other sites

My radio have a weird bug.When i hold caps-lock , right side down monitor, it show me the radio working and channel hint.Working in single player fine but in multi player the radio not working at all.

I reinstalled the mod, plugin, team speak few times, no luck.Also changed my arma profile name. 

I reinstalled CBA mod too.Executed teamspeak as run as administrator, still not working radio.Anyone have this problem?

 

Any errors in logs?

Share this post


Link to post
Share on other sites

So can anyone confirm problem with TFAR when there is 30+ people on the channel ? we have issues that people are cut out, or we don't hear other people talk on the radios. We can hear the 'beep' at start and the end but sometimes we just can't hear anyone talk. I heard that TFAR can't handle lots of people on one channel, is that true ? 

 

We are playing with 100+ players in one channel without issues.

 

Could you test to just move all players into one TS channel (without TFAR) and talk?

Share this post


Link to post
Share on other sites

Cool ;)

 

Put 3 to sending and 0.333 to receiving.

Is there a logic behind that? Something like (sending) x (receiving/3) = normal range?

Share this post


Link to post
Share on other sites

Any errors in logs?

Well, problem fixed.CBA was the problem.Used uploaded cba with radio mod and all fine now.

Share this post


Link to post
Share on other sites

Is there a logic behind that? Something like (sending) x (receiving/3) = normal range?

 

Sending - your transmit randge multiplied

Receviing - range your receiving from multiplied

Share this post


Link to post
Share on other sites

Sending - your transmit randge multiplied

Receviing - range your receiving from multiplied

Yeah, I thought so. But I found that raising the receivingDM proportionally to the sendingDM wouldn't have any effect. Only if the receivingDM was lower than the sendingDM I would be able to hear and be heard over a wider range (given that both the transmitter and the receiver had the same values for both variables).

Share this post


Link to post
Share on other sites

 

Thanks for the response! Since I'm a total function noob, how would I go about using this function? I figured it wouldn't work, but to set frequency to 70.0 and speakers on I already tried:

[(call TFAR_fnc_activeLrRadio) select 0, (call TFAR_fnc_activeLrRadio) select 1, "70.00"] call TFAR_fnc_setLrFrequency; [(call TFAR_fnc_activeLrRadio) select 0, (call TFAR_fnc_activeLrRadio) select 1] call TFAR_fnc_setLrSpeakers;

I saw you responded to something similar earlier in the thread, so instead I'm guessing it would have to look something like this?

[_vehicleObject, "driver_radio_settings"] call TFAR_fnc_setLrSpeakers;

What would I need to change to make setLrFrequency and setLrSpeakers to work with a LR backpack placed in the editor?

Share this post


Link to post
Share on other sites

Thanks for the response! Since I'm a total function noob, how would I go about using this function? I figured it wouldn't work, but to set frequency to 70.0 and speakers on I already tried:

[(call TFAR_fnc_activeLrRadio) select 0, (call TFAR_fnc_activeLrRadio) select 1, "70.00"] call TFAR_fnc_setLrFrequency; [(call TFAR_fnc_activeLrRadio) select 0, (call TFAR_fnc_activeLrRadio) select 1] call TFAR_fnc_setLrSpeakers;

I saw you responded to something similar earlier in the thread, so instead I'm guessing it would have to look something like this?

[_vehicleObject, "driver_radio_settings"] call TFAR_fnc_setLrSpeakers;

What would I need to change to make setLrFrequency and setLrSpeakers to work with a LR backpack placed in the editor?

 

Oh.. It is not so easy... You need to put backpack in editor this some name and then use this name in scripts.

 

But as far as I remember backpack will wrapped into GroundWeaponHolder, so you will need to run everyBackpack function to get backpack object.

 

and then

 

[_x, "radio_settings", "70.00"] call TFAR_fnc_setLrFrequency;
[_x, "radio_settings"] call TFAR_fnc_setLrSpeakers;
 
where _x is backpack object.
 
Check fn_processSpeakerRadios.sqf in github repo for references.

Share this post


Link to post
Share on other sites

 

Oh.. It is not so easy... You need to put backpack in editor this some name and then use this name in scripts.

 

 

Thanks! I'm not having much luck with it at the moment, but I guess I'll just have to read up more on scripting. Thanks for helping and creating TFAR :)

Share this post


Link to post
Share on other sites

With 1.56 about to bring some pretty decent mod support to the 'vanilla' game, it would be nice to see TFAR on the steam workshop. I know there were concerns about whether or not you could add arbitrary loose files (especially the critical *.dll plugins) to a Steam workshop mods and yes, you now can. There's obviously no auto-install like there is with PwS or A3Sync but the files will be there, ready for users to manually move them to TS. It would be great to see an official TFAR release on Steam Workshop before 1.56 comes out, the publishing process is surprisingly painless! :)

Share this post


Link to post
Share on other sites

More people willing to play on servers that use TFAR?  Instead of just going to a vanilla server because they can't hassle with it?

  • Like 1

Share this post


Link to post
Share on other sites

With 1.56 about to bring some pretty decent mod support to the 'vanilla' game, it would be nice to see TFAR on the steam workshop. I know there were concerns about whether or not you could add arbitrary loose files (especially the critical *.dll plugins) to a Steam workshop mods and yes, you now can. There's obviously no auto-install like there is with PwS or A3Sync but the files will be there, ready for users to manually move them to TS. It would be great to see an official TFAR release on Steam Workshop before 1.56 comes out, the publishing process is surprisingly painless! :)

 

I'm sure nkey is aware of the benefits but given various people's actions I'm quite sure he's decided not to. It's his mod, he can do as he sees fit.

 

More people willing to play on servers that use TFAR?  Instead of just going to a vanilla server because they can't hassle with it?

 

I hang out sometimes on the TF Warhorse (or a lot depending on what's really going on) and I like going on the TFAR channel as sometimes I'm there, I monitor, but I don't play with other people because Il like the 3D sound effect, so nobody is bothering me while I play. Nothing wrong with some people but pub servers sometimes i just like to do my own thing and be left somewhat alone. And I like to use the radio when needed.

Share this post


Link to post
Share on other sites

This is one mod my group misses using. We have moved exclusively to using steamwortks for our mods and this is probably the only mod that isn't on there that I miss.

Share this post


Link to post
Share on other sites

Hello.

 

Myself and my Arma 3 unit is having some problems with TFAR.

 

For some reason whenever we start a mission, we spawn with no short range radios, even though the scripts are correct (it worked during singleplayer testing and LAN server testing). However the Long range radios work perfectly.

I've been doing some research on this problem and I believe that it could be due to use updating our CBAs. IS this the problem? If not what else could be the problem?

 

Now I also have my own problem, whenever I join the server it does not move me into the TFAR TS channel, and if I try to move myself it does not work.

Share this post


Link to post
Share on other sites

With 1.56 about to bring some pretty decent mod support to the 'vanilla' game, it would be nice to see TFAR on the steam workshop. I know there were concerns about whether or not you could add arbitrary loose files (especially the critical *.dll plugins) to a Steam workshop mods and yes, you now can. There's obviously no auto-install like there is with PwS or A3Sync but the files will be there, ready for users to manually move them to TS. It would be great to see an official TFAR release on Steam Workshop before 1.56 comes out, the publishing process is surprisingly painless! :)

 

yep, just need to strip out userconfig somehow.. (as I know it is not supported)

Share this post


Link to post
Share on other sites

Hello.

 

Myself and my Arma 3 unit is having some problems with TFAR.

 

For some reason whenever we start a mission, we spawn with no short range radios, even though the scripts are correct (it worked during singleplayer testing and LAN server testing). However the Long range radios work perfectly.

I've been doing some research on this problem and I believe that it could be due to use updating our CBAs. IS this the problem? If not what else could be the problem?

 

Now I also have my own problem, whenever I join the server it does not move me into the TFAR TS channel, and if I try to move myself it does not work.

 

Check your server logs for errors.

Share this post


Link to post
Share on other sites

So far the only issue I've noticed is that it automatically put on the Long Range Rucks, and so far that's it. Honestly that's my only nitpick and it substituted my personal radios for the PRC-148. Otherwise seemed to work okay. Although in all honesty I did revert back to the Armaholic version so I'd have control over the radio stuff.

Share this post


Link to post
Share on other sites
Hi,

 

Is it possible to spawn a unit without any radio?

Looking for a long time, but I can't find a way.

Share this post


Link to post
Share on other sites

Open the radio_settings.hpp in the userconfig/task_force_radio folder and it has the various settings and you can disable/enable them.

Share this post


Link to post
Share on other sites

I already try, it does not work.

The soldier always keeps a radio.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×