public static void SaveGame(Ui_menu_control canvas) { string path = Application.persistentDataPath + "/Save.vsf"; BinaryFormatter formatter = new BinaryFormatter(); FileStream stream = new FileStream(path, FileMode.Create); GameData data = new GameData(canvas); formatter.Serialize(stream, data); stream.Close(); }
public GameData(Ui_menu_control canvas) { slider_value = canvas.slider_value; vignette = canvas.vignette; motionBlur = canvas.motionBlur; colorGrading = canvas.colorGrading; ambietOcclusion = canvas.ambietOcclusion; bloom = canvas.bloom; launge = canvas.launge; type_control = canvas.type_control; }