Jump to content
giallustio

[MP] =BTC= Hearts and Minds

Recommended Posts

Hello,

1 hour ago, Bad_Dad said:

what files would need to be edited / added in order to add a side mission? 

 

Here is an example https://github.com/Vdauphin/HeartsAndMinds/blob/master/%3DBTC%3Dco%4030_Hearts_and_Minds.Altis/core/fnc/side/tower.sqf

Then you just need to add it here to the list https://github.com/Vdauphin/HeartsAndMinds/blob/master/%3DBTC%3Dco%4030_Hearts_and_Minds.Altis/core/def/mission.sqf#L229

 

Cheers

  • Like 1

Share this post


Link to post
Share on other sites
26 minutes ago, Vdauphin said:


does anything need to be done also with the compile.sqf? 

 

  //SIDE
    btc_side_fnc_create = compileScript ["core\fnc\side\create.sqf"];
    btc_side_fnc_get_city = compileScript ["core\fnc\side\get_city.sqf"];
    btc_side_fnc_mines = compileScript ["core\fnc\side\mines.sqf"];
    btc_side_fnc_supply = compileScript ["core\fnc\side\supply.sqf"];
    btc_side_fnc_vehicle = compileScript ["core\fnc\side\vehicle.sqf"];
    btc_side_fnc_civtreatment = compileScript ["core\fnc\side\civtreatment.sqf"];
    btc_side_fnc_tower = compileScript ["core\fnc\side\tower.sqf"];
    btc_side_fnc_checkpoint = compileScript ["core\fnc\side\checkpoint.sqf"];
    btc_side_fnc_civtreatment_boat = compileScript ["core\fnc\side\civtreatment_boat.sqf"];
    btc_side_fnc_underwater_generator= compileScript ["core\fnc\side\underwater_generator.sqf"];
    btc_side_fnc_convoy = compileScript ["core\fnc\side\convoy.sqf"];
    btc_side_fnc_rescue = compileScript ["core\fnc\side\rescue.sqf"];
    btc_side_fnc_capture_officer = compileScript ["core\fnc\side\capture_officer.sqf"];
    btc_side_fnc_hostage = compileScript ["core\fnc\side\hostage.sqf"];
    btc_side_fnc_hack = compileScript ["core\fnc\side\hack.sqf"];
    btc_side_fnc_kill = compileScript ["core\fnc\side\kill.sqf"];
    btc_side_fnc_chemicalLeak = compileScript ["core\fnc\side\chemicalLeak.sqf"];
    btc_side_fnc_EMP = compileScript ["core\fnc\side\EMP.sqf"];
    btc_side_fnc_removeRubbish = compileScript ["core\fnc\side\removeRubbish.sqf"];
    btc_side_fnc_pandemic = compileScript ["core\fnc\side\pandemic.sqf"];

 

Share this post


Link to post
Share on other sites
Just now, Bad_Dad said:

does anything need to be done also with the compile.sqf? 

Yes you need to add your new function

  • Thanks 1

Share this post


Link to post
Share on other sites
On 1/24/2024 at 1:55 PM, Vdauphin said:

Yes you need to add your new function


Hey, @Vdauphin

So i was able to get a new side mission working and requestable with the side mission request ace interact....
all works well... except there is a minor error that pops up and i am having a hell of a time figuring out how to rectify it...Here is my code and the error below
Any help would be appreciated!!! 

 

params [
    ["_taskID", "btc_side", [""]]
];

private _useful = values btc_city_all select {
    !((_x getVariable ["type", ""]) in ["NameLocal", "Hill", "NameMarine", "StrongpointArea"])
};
if (_useful isEqualTo []) then {_useful = values btc_city_all;};

private _city = selectRandom _useful;
private _pos = [getPos _city, 0, _city getVariable ["cachingRadius", 50], 10, false] call btc_fnc_findsafepos;
if (_pos select 2 > 50) exitWith {[] spawn btc_side_fnc_create;};

_city setVariable ["spawn_more", true];


private _burning = selectRandom ["MetalBarrel_burning_F","FirePlace_burning_F","Campfire_burning_F"];
private _camo = selectRandom ["CamoNet_OPFOR_F","CamoNet_INDP_F"];
private _boombox = selectRandom ["Box_East_AmmoOrd_F","Box_IND_AmmoOrd_F","Box_EAF_AmmoOrd_F"];
private _btc_composition_hideout = [
    [_burning,0,[-2.30957,3.02979,0]],
	[_camo,121.331,[0.675781,-1.52539,0]],
	["Land_PlasticBucket_01_closed_F",121.331,[0.675781,-1.52539,0]],
	["Land_WoodenTable_large_F",121.331,[0.675781,-1.52539,0]],
		["Land_MultiMeter_F",121.331,[0.675781,-1.52539,1]],
		["Land_Pliers_F",121.331,[0.61,-1.72539,1]],
		["Land_DuctTape_F",101.331,[0.91,-1.22539,1]],
		["AluminiumFoil_01_F",0,[0,-1.52539,1]],
    [selectRandom btc_type_seat,90,[-4.08203,3.99795,0]],
    [selectRandom btc_type_seat,279.689,[-4.52783,2.76416,0]],
    [_boombox,36.4913,[2,0,0.25]]

];


private _closest = [_city, values btc_city_all select {!(_x getVariable ["active", false])}, false] call btc_fnc_find_closecity;
for "_i" from 1 to (round random 2) do {
    [btc_mil_fnc_send, [_closest, _pos, 1, selectRandom btc_type_motorized]] call CBA_fnc_directCall;
};


private _btc_composition = [_pos, selectRandom [0, 90, 180, 270], _btc_composition_hideout] call btc_fnc_create_composition;
private _IEDcache = _btc_composition select ((_btc_composition apply {typeOf _x}) find _boombox);

[_taskID, 42, _IEDcache, [_city getVariable "name", _boombox]] call btc_task_fnc_create;

waitUntil {sleep 5;
    !alive _IEDcache ||
    _taskID call BIS_fnc_taskCompleted
};

[[], _btc_composition] call btc_fnc_delete;

if (_taskID call BIS_fnc_taskState isEqualTo "CANCELED") exitWith {};

30 call btc_rep_fnc_change;

[_taskID, "SUCCEEDED"] call BIS_fnc_taskSetState;

qR8ORTa.png

Share this post


Link to post
Share on other sites
5 hours ago, Bad_Dad said:


Hey, @Vdauphin

So i was able to get a new side mission working and requestable with the side mission request ace interact....
all works well... except there is a minor error that pops up and i am having a hell of a time figuring out how to rectify it...Here is my code and the error below
Any help would be appreciated!!! 

 


params [
    ["_taskID", "btc_side", [""]]
];

private _useful = values btc_city_all select {
    !((_x getVariable ["type", ""]) in ["NameLocal", "Hill", "NameMarine", "StrongpointArea"])
};
if (_useful isEqualTo []) then {_useful = values btc_city_all;};

private _city = selectRandom _useful;
private _pos = [getPos _city, 0, _city getVariable ["cachingRadius", 50], 10, false] call btc_fnc_findsafepos;
if (_pos select 2 > 50) exitWith {[] spawn btc_side_fnc_create;};

_city setVariable ["spawn_more", true];


private _burning = selectRandom ["MetalBarrel_burning_F","FirePlace_burning_F","Campfire_burning_F"];
private _camo = selectRandom ["CamoNet_OPFOR_F","CamoNet_INDP_F"];
private _boombox = selectRandom ["Box_East_AmmoOrd_F","Box_IND_AmmoOrd_F","Box_EAF_AmmoOrd_F"];
private _btc_composition_hideout = [
    [_burning,0,[-2.30957,3.02979,0]],
	[_camo,121.331,[0.675781,-1.52539,0]],
	["Land_PlasticBucket_01_closed_F",121.331,[0.675781,-1.52539,0]],
	["Land_WoodenTable_large_F",121.331,[0.675781,-1.52539,0]],
		["Land_MultiMeter_F",121.331,[0.675781,-1.52539,1]],
		["Land_Pliers_F",121.331,[0.61,-1.72539,1]],
		["Land_DuctTape_F",101.331,[0.91,-1.22539,1]],
		["AluminiumFoil_01_F",0,[0,-1.52539,1]],
    [selectRandom btc_type_seat,90,[-4.08203,3.99795,0]],
    [selectRandom btc_type_seat,279.689,[-4.52783,2.76416,0]],
    [_boombox,36.4913,[2,0,0.25]]

];


private _closest = [_city, values btc_city_all select {!(_x getVariable ["active", false])}, false] call btc_fnc_find_closecity;
for "_i" from 1 to (round random 2) do {
    [btc_mil_fnc_send, [_closest, _pos, 1, selectRandom btc_type_motorized]] call CBA_fnc_directCall;
};


private _btc_composition = [_pos, selectRandom [0, 90, 180, 270], _btc_composition_hideout] call btc_fnc_create_composition;
private _IEDcache = _btc_composition select ((_btc_composition apply {typeOf _x}) find _boombox);

[_taskID, 42, _IEDcache, [_city getVariable "name", _boombox]] call btc_task_fnc_create;

waitUntil {sleep 5;
    !alive _IEDcache ||
    _taskID call BIS_fnc_taskCompleted
};

[[], _btc_composition] call btc_fnc_delete;

if (_taskID call BIS_fnc_taskState isEqualTo "CANCELED") exitWith {};

30 call btc_rep_fnc_change;

[_taskID, "SUCCEEDED"] call BIS_fnc_taskSetState;

qR8ORTa.png

Hello,

Hard to say, you need to update the description of your task https://github.com/Vdauphin/HeartsAndMinds/blob/master/%3DBTC%3Dco%4030_Hearts_and_Minds.Altis/core/fnc/task/setDescription.sqf

Cheers

Share this post


Link to post
Share on other sites

@Vdauphin

did that too already 

case 42 : {
        _description = [
            (localize "STR_BTC_HAM_SIDE_IEDfactory_DESC") + ([_location] call btc_fnc_typeOfPreview),
            localize "STR_BTC_HAM_SIDE_IEDfactory_TITLE",
            localize "STR_BTC_HAM_SIDE_IEDfactory_TITLE"
        ];
        _type = "search";
    };

and added it to the stringtable 
 

Share this post


Link to post
Share on other sites
Just now, Bad_Dad said:

@Vdauphin

did that too already 


case 42 : {
        _description = [
            (localize "STR_BTC_HAM_SIDE_IEDfactory_DESC") + ([_location] call btc_fnc_typeOfPreview),
            localize "STR_BTC_HAM_SIDE_IEDfactory_TITLE",
            localize "STR_BTC_HAM_SIDE_IEDfactory_TITLE"
        ];
        _type = "search";
    };

and added it to the stringtable 
 

Then you need to check what is in _location, the error come from here

Share this post


Link to post
Share on other sites
1 minute ago, Vdauphin said:

Then you need to check what is in _location, the error come from here

ah ok i think i see my issue!!! thanks 

  • Like 1

Share this post


Link to post
Share on other sites

@Vdauphin We would like to remove the killfeed/info icons that pop-up in the right corner, every time someone is doing good/bad stuff. .. is this possible? If so, how?

Share this post


Link to post
Share on other sites
26 minutes ago, bodybaq said:

killfeed/info

Hello,

There is no killfeed in H&M and intel info can't be disable, it is the perpose of the mission...

Cheers

  • Sad 1

Share this post


Link to post
Share on other sites

@Vdauphin really appreciate your help.... 

 i was able to make 3 new side missions after you lead me to the right files

  1. Destroy IED factory - you have to blow up a cache that is surrounded by APmines 
  2. Destroy the mortar camp - you have to destroy the mortar tubes and the mortar cache
  3. Destroy the AA camp - you have to destroy the AA gun and weapon cache

@bodybaq i can share the files if you want them ... 

just so you are aware these side missions have mod requirements for JBAD and CUP terrains core cause i used assets from them to make the compositions

 

  • Thanks 1

Share this post


Link to post
Share on other sites

Hey @Vdauphin 

Would you be cool with me posting the 4 Extra side missions I made for H&M in this thread?

  1. Destroy IED factory - Search for and destroy the IED factory. (Use one M112 explosive to destroy the IED Cache).
  2. Destroy the mortar camp -Search for and destroy the Mortar Camp. (Destroy the Mortar Cache and mortar tubes with explosives).
  3. Destroy the AA camp - Search for and destroy the Anti-Air Camp. (Destroy the Anti-Air guns at the site with explosives).
  4. Plane Crash Site -  A plane carrying a secure data terminal has gone down... your objective is to secure the crash site and retrieve the data.

Share this post


Link to post
Share on other sites
17 hours ago, Bad_Dad said:

Hey @Vdauphin 

Would you be cool with me posting the 4 Extra side missions I made for H&M in this thread?

  1. Destroy IED factory - Search for and destroy the IED factory. (Use one M112 explosive to destroy the IED Cache).
  2. Destroy the mortar camp -Search for and destroy the Mortar Camp. (Destroy the Mortar Cache and mortar tubes with explosives).
  3. Destroy the AA camp - Search for and destroy the Anti-Air Camp. (Destroy the Anti-Air guns at the site with explosives).
  4. Plane Crash Site -  A plane carrying a secure data terminal has gone down... your objective is to secure the crash site and retrieve the data.

Hello,

Yes sure, you can also share it here: https://github.com/Vdauphin/HeartsAndMinds/discussions

Or make a pull request so everyone will enjoy it

Cheers

  • Thanks 1

Share this post


Link to post
Share on other sites

@Vdauphin cool thanks... im not too familiar with pull requests or github... maybe i will check it out 

 

  • Thanks 1

Share this post


Link to post
Share on other sites

Hello,

 

I am trying to figure out a way to have the Spectator mode be activated when you die and you are entirely out of tickets, but have the simple respawn countdown be activated when you do have tickets. This way, the players that are dead and can't respawn can see what is going on and don't have to leave the mission when they have no tickets. 

 

 

Share this post


Link to post
Share on other sites

 

13 hours ago, keIIy said:

 

I am trying to figure out a way to have the Spectator mode be activated when you die and you are entirely out of tickets, but have the simple respawn countdown be activated when you do have tickets. This way, the players that are dead and can't respawn can see what is going on and don't have to leave the mission when they have no tickets. 

Hello

Previously it was enable, just undo this pull request: https://github.com/Vdauphin/HeartsAndMinds/pull/1369/files

But player may get stuck with the view from his dead body

Cheers

Share this post


Link to post
Share on other sites
9 hours ago, Vdauphin said:

 

Hello

Previously it was enable, just undo this pull request: https://github.com/Vdauphin/HeartsAndMinds/pull/1369/files

But player may get stuck with the view from his dead body

Cheers

 

Yes, I enabled it and did get stuck on the dead body. I am not sure how to proceed.

 

EDIT: Using ace_specator instead of Spectator in respawn templates negates the camera being stuck, and spectator works as it should. However, now you use the spectator camera anytime you die, when I just want it to be when you're out of tickets. Having the spectator mode before being out of tickets gives respawning players an unfair advantage since they can see all the enemies and immediately go back and begin fighting them.

 

Share this post


Link to post
Share on other sites
14 hours ago, keIIy said:

Yes, I enabled it and did get stuck on the dead body. I am not sure how to proceed.

By default you can only spectate your side: https://github.com/Vdauphin/HeartsAndMinds/blob/master/%3DBTC%3Dco%4030_Hearts_and_Minds.Altis/define_mod.sqf#L12-L19

 

14 hours ago, keIIy said:

However, now you use the spectator camera anytime you die, when I just want it to be when you're out of tickets. Having the spectator mode before being out of tickets gives respawning players an unfair advantage since they can see all the enemies and immediately go back and begin fighting them.

Check the wiki: https://ace3.acemod.org/wiki/framework/spectator-framework

There are some function to enable disable on the fly, also only show your side etc

  • Like 1

Share this post


Link to post
Share on other sites

I managed to add a few ACE Virtual Spectator slots and this fixes our issue. Players who are killed have the respawn counter, then when we run out of tickets, they back out to the lobby and choose a spectator slot so they can watch what happens instead of being forced to wait or get off for the night. Thanks for your help.

 

On another note, is there any chance of ACE mines or explosives, such as anti tank mines and UXO bomblets from cluster munitions, saving with persistence? That is the only thing I have noticed doesn't save and it would really be awesome if they did. 

Share this post


Link to post
Share on other sites

Hello,

On 2/8/2024 at 10:54 PM, keIIy said:

On another note, is there any chance of ACE mines or explosives, such as anti tank mines and UXO bomblets from cluster munitions, saving with persistence? That is the only thing I have noticed doesn't save and it would really be awesome if they did. 

Well not for now

Cheers

Share this post


Link to post
Share on other sites

Hello!

 

The Hearts and Minds mission 1.23.6 hotfix is here!

Now H&M requires CBA and ACE3 only.

 

Changelog :

  • Mission.sqm/Param.hpp not changed.
  • FIX: Custom locations without side mission (@Vdauphin).
  • FIX: Remove comment about turn off option for auto restart (@Vdauphin).

Have fun!!!

 

 

Share this post


Link to post
Share on other sites

Hello,

On 2/8/2024 at 10:54 PM, keIIy said:

On another note, is there any chance of ACE mines or explosives, such as anti tank mines and UXO bomblets from cluster munitions, saving with persistence? That is the only thing I have noticed doesn't save and it would really be awesome if they did. 

Actually I did try some stuff this weekend, see https://github.com/Vdauphin/HeartsAndMinds/pull/1583

Cheers

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

×