User Tools

Site Tools


ofp:missions:savestatus

OFP saveStatus

OFP Forum, OFP Home, OFP File Formats, OFP Tools, OFP Missions, OFP 3D Modeling, OFP Terrain

Operation Flashpoint (OFP) aka ArmA: Cold War Assault (CWA)

Syntax: object saveStatus name

Example:

player saveStatus "playerstate";

This command saves the units status, weapons and equipment he carries, his health status and identity (setIdentity: face type and name set previously in description.ext).

More examples:

x = PMC_sf1 saveStatus "sf1_02";
x = PMC_sf2 saveStatus "sf2_02";
x = PMC_sf3 saveStatus "sf3_02";
x = PMC_sf4 saveStatus "sf4_02";

loadStatus

Syntax: object loadStatus name

Example:

player loadStatus "playerstate";

This command loads the units status, weapons and equipment he carries, his health status and identity (setIdentity: face type and name set previously in description.ext). However these must have been first saved with the above saveStatus command.

More examples:

PMC_sf1 loadStatus "sf1_02"; PMC_sf1 setdammage 0;
PMC_sf2 loadStatus "sf2_02";
PMC_sf3 loadStatus "sf3_02";
PMC_sf4 loadStatus "sf4_02";

{ if (!alive _x) then { deletevehicle _x }; _x setdammage 0 } foreach [PMC_sf2,PMC_sf3,PMC_sf4];

Notice that there is certain degree of problems if units are damaged in the previous mission, as they start that way in the next one too. Unless the mission specificly is “out in the field” type and not in homebase, you should use the above script to restore the health of the units so they wont start the mission injured.

ofp/missions/savestatus.txt · Last modified: 2024/07/31 15:11 by snakeman

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki

All PMC web site download services are temporarily suspended until web site yearly fees have been recovered, want to download addons/mods? Then Support PMC.

If you are grateful for all the work PMC has done in the past 25 years, use Support PMC page.