From 7f661ce362f43e18d1fddc72a8a8c373c3ac484a Mon Sep 17 00:00:00 2001 From: Regalis Date: Sun, 5 Feb 2017 18:42:17 +0200 Subject: [PATCH] Fixed a brainfart in property saving (i.e. saveable but non-editable properties not being saved) --- Subsurface/Source/Properties.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Subsurface/Source/Properties.cs b/Subsurface/Source/Properties.cs index a5aa106a2..738f83951 100644 --- a/Subsurface/Source/Properties.cs +++ b/Subsurface/Source/Properties.cs @@ -259,11 +259,11 @@ namespace Barotrauma { //only save // - if the attribute is saveable and it's different from the default value - // - or can be changed in the editor + // - or can be changed in-game or in the editor bool save = false; foreach (var attribute in property.Attributes.OfType()) { - if ((!attribute.isSaveable && !attribute.defaultValue.Equals(value)) || + if ((attribute.isSaveable && !attribute.defaultValue.Equals(value)) || property.Attributes.OfType().Any()) { save = true;