Jump to content
NotMyActualName

MK6 Mortar disappears

Recommended Posts

I transported a disassembled MK6 mortar from one location to another.

Then I assembled it and used it.

 

I moved a few hundret meters away from the spot where I placed it and when I returned after about ten minutes it was gone.

 

 

Is this "normal"?

And if so, how can I prevent this from happening?

 

If it matters:

This happened in a custom made singleplayer scenario.

The MK6 was placed into the world in the disassembled state (the two "backpacks").

Share this post


Link to post
Share on other sites

Garbage collector cleaned it up? Or similar cleanup script in the scenario?

  • Like 1

Share this post


Link to post
Share on other sites
35 minutes ago, Harzach said:

Garbage collector cleaned it up? Or similar cleanup script in the scenario?

 

I don't think so.

 

I made the scenario myself and I did not add any scripts like that.

  • Like 1

Share this post


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

 

I don't think so.

 

I made the scenario myself and I did not add any scripts like that.

As Harzach mentioned in their post, maybe the garbage collector, which I believe is on by default, deleted it.

 

For more information on the garbage collector you can have a look at the BIKI under the section Corpse & Wreck Management.

 

If you need further assistance (for example a demo description.ext file showcasing a possible solution) please don't hesitate to post again.

 

---------------------------------------------------------------------------------- EDIT ----------------------------------------------------------------------------------

You could also have a look at this post in the forums.

Edited by ZaellixA
Added information
  • Like 1

Share this post


Link to post
Share on other sites

It still makes no sense to me.

The "garbage collector" only seems to care about wrecks and corpses.

 

And the mortar is neither one of those.

 

Is there a way to exclude "objects placed by the player during the game" (static weapons like mortars, HMGs, ...) from garbage collection?

Share this post


Link to post
Share on other sites
3 hours ago, NotMyActualName said:

Is there a way to exclude "objects placed by the player during the game" (static weapons like mortars, HMGs, ...) from garbage collection?

Yes. You can use removeFromRemainsCollector, or you could just possibly check whether it is in the garbage/remains collector with isInRemainsCollector. See the following snippet as an example, where I assume the mortar object is valid in the scope the snippet will be called and it is called _mortar.

if (isInRemainsCollector _mortar) then {
	systemChat "Mortar is set to be collected";
	removeFromRemainsCollector _mortar;
	systemChat "Mortar is not to be collected anymore";
};

Of course you could skip all the systemChats but I believe you should at least have one in the if-statement's scope to see whether it was called or not (or you can just print the result of isInRemainsCollector command).

 

Please let us know if this worked for you or not.

Share this post


Link to post
Share on other sites
On 1/3/2022 at 10:46 PM, ZaellixA said:

Yes. You can use removeFromRemainsCollector, or you could just possibly check whether it is in the garbage/remains collector with isInRemainsCollector. See the following snippet as an example, where I assume the mortar object is valid in the scope the snippet will be called and it is called _mortar.


if (isInRemainsCollector _mortar) then {
	systemChat "Mortar is set to be collected";
	removeFromRemainsCollector _mortar;
	systemChat "Mortar is not to be collected anymore";
};

Of course you could skip all the systemChats but I believe you should at least have one in the if-statement's scope to see whether it was called or not (or you can just print the result of isInRemainsCollector command).

 

Please let us know if this worked for you or not.

Theoretically that would work, but given the circumstances of the mortar not being placed in the editor and it being "built" from two backpacks, you'd also need some sort of wizardry to "find" the mortar and recognise it...

  • Like 1

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

×