void FixedUpdate() { if (debug_CraftToSave != null) { debug_CraftBlueprint = CraftBlueprint.GetBlueprintFromCraft(debug_CraftToSave); debug_CraftToSave = null; } if (debug_CraftBlueprint != null) { if (debug_SaveCraftBlueprint) { debug_SaveCraftBlueprint = false; CraftBlueprint.SaveToFile(debug_CraftBlueprint); } if (debug_LoadCraftBlueprint) { debug_LoadCraftBlueprint = false; debug_CraftBlueprint = CraftBlueprint.LoadFromFileByName(debug_LoadCraftBlueprintFileName); } if (debug_SpawnCraftBlueprint) { CraftBlueprint.SpawnCraftFromBlueprint(debug_CraftBlueprint, Vector3.up * 10f, Vector3.zero); debug_SpawnCraftBlueprint = false; } if (debug_ForgetCraftBlueprint) { debug_ForgetCraftBlueprint = false; debug_CraftBlueprint = null; } } }
public void SaveCurrCraft() { if (currCraft == null) { return; } CraftBlueprint.SaveToFile(GetBlueprintFromCurrCraft()); }