Last active 8 months ago
Ah, seems like player logistics was commandeering my vehicles. I added "this setvariable ["ALiVE_SYS_LOGISTICS_DISABLE",true];" to their init and now they spawn on mission load as expected.
I’m having an odd problem that I can’t seem to get to the bottom of or find a good workaround. I have a mission I designed for SP with the player in command of a mechanized platoon using High Command. The platoon units are all editor placed and consist of two rifles squads and a few APCs. My problem is that the APCs appear to be affected by persistence in an unwanted way when saving. My goal was for the platoon to respawn whenever I reloaded the mission so the player would always start with full support. However if the APCs get destroyed, when I start the mission I have a crew with no vehicle that spawns where the APC died.
I confirmed that infantry groups work as intended. I can kill off an entire friendly squad but when loading the mission they are right back at base. I’ve tried various methods of respawning the vehicles before save and exit with no change in outcome. I tried turning off the garbage collector but that didn’t help either. The vehicles are definitely no sync’d to the virtual AI module and the module is set to virtualize only sync’d units. If I just order the unit to move, but don’t let it get destroyed, it properly spawns at base. Only a destroyed (or damaged enough to get the crew to bail out) vehicle fails to respawn. I would’ve thought that all editor placed units would spawn in as if starting the mission fresh, but ALiVE definitely seems to be doing something to these vehicle based units.
Anyone have thoughts on how to keep these vehicles from being logged by the save function or any better way to get them to spawn at base when loading the mission?
Alright managed to answer the first question just by putting the call line in my mission end trigger and it worked perfectly. So that’s settled. I’ve come up with a couple more questions:
I created a copy of the AAF with new group compositions (got rid of 2 man groups and the large AA teams in mechanized units). First issue was when I tried to export the faction, I kept getting an error message. I worked around this by just renaming AAF in the orbat creator and that worked. They spawn appropriately and the debug radio messages refer to them by my new faction identifier so that’s all good. But how can I get them to show up in C2ISTAR menu? In the module placement in editor I can specify them for auto generated tasks, which works. But in game I can’t manually generate a task against them because they don’t appear in the C2ISTAR menu. I changed the faction name, plus I don’t see AAF twice so i don’t think they’re just showing up as AAF in the menu.
Hey all, I’m very new to scripting in ArmA and have a few questions about using Alive functions and where to put code snippets. All of the following pertain to a local SP mission with local saving:
1)Is there a way to call playerNameSpaceClear outside of the debug console? I’d like to have it happen with my endmission trigger so that next time I play the mission after completing it, it starts over.
2) How can I preserve a task state in persistence? I’ve seen threads about making variables that are saved so I guess I could save a variable and activate the task via trigger, but I’m not sure where to put the code for saving or getting the variable state when the mission starts.
3) Is there a way to save editor placed units in persistence without profiling? My mission gives you control of a Mechanized platoon and i want to save their status but don’t want OPCOM take over their control. I assume editor placed units will respawn when I launch the mission so that’s not so bad, but saving their location would be nice.
I've been toying with getting an alive campaign made. My vision is a large conventional invasion CTI style campaign. Basically the original Operation Flashpoint campaign set on Altis. But combined with the dynamic SP campaigns that people made for OFP back in the day. In my head I have this great idea of it being episodic so it's small enough to save. There are hub missions where you can get smaller tasks assigned while waiting for the next offensive push mission. Combined arms ops and using high command to put you in charge of a platoon while there are other forces alongside taking other objectives.
I'm not really requesting this. Just getting the idea out there as I think ALiVE provides a great engine for making these campaigns without having to micromanage all the units...
Just wanted to add that I'm having the same issue packing and loading pbos when copying a faction. I'm trying to create a copy of the default CSAT with different group compositions. I copy the faction, change the groups, then export both the faction and copy it in to autogen.hpp. I do the same with cfgpatches. When I try to pack the pbo with the BI tools packer I get a "Error in config.cpp" and it fails. I can pack it with a 3rd party packer or by unchecking the binarize box. But then when I try to load the addon in Arma I get a similar error citing the CargoTurret class of the taru helicopters. Very reproducible by trying to make a copy of CSAT faction. I should add I'm not changing any of the units or using any addon units. Just a straight copy of the vanilla faction. (Speaking of changing units, I'm not able to edit load outs of units in a copied faction, only if I open a default faction in the 'Unit Editor' and import from config am I able to edit their loadouts...)