Fix the ts map importer saving default values for Health and Facing
This commit is contained in:
@@ -527,11 +527,15 @@ namespace OpenRA.Mods.Cnc.UtilityCommands
|
|||||||
var ar = new ActorReference(name)
|
var ar = new ActorReference(name)
|
||||||
{
|
{
|
||||||
new LocationInit(cell),
|
new LocationInit(cell),
|
||||||
new OwnerInit("Neutral"),
|
new OwnerInit("Neutral")
|
||||||
new HealthInit(100 * health / 256),
|
|
||||||
new FacingInit(facing),
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if (health != 256)
|
||||||
|
ar.Add(new HealthInit(100 * health / 256));
|
||||||
|
|
||||||
|
if (facing != 96)
|
||||||
|
ar.Add(new FacingInit(facing));
|
||||||
|
|
||||||
if (isDeployed)
|
if (isDeployed)
|
||||||
ar.Add(new DeployStateInit(DeployState.Deployed));
|
ar.Add(new DeployStateInit(DeployState.Deployed));
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user