Browse Source

Update taml_ScriptBinding.h

even simpler
marauder2k7 2 months ago
parent
commit
48680700ab
1 changed files with 3 additions and 13 deletions
  1. 3 13
      Engine/source/persistence/taml/taml_ScriptBinding.h

+ 3 - 13
Engine/source/persistence/taml/taml_ScriptBinding.h

@@ -252,20 +252,10 @@ DefineEngineFunction(TamlWrite, bool, (SimObject* simObject, const char* filenam
       taml.setAutoFormat(false);
    }
 
-   // should only be checking if compression if compressed is true.
-   if (compressed)
+   if (taml.getFormatMode() == Taml::BinaryFormat)
    {
-      // Yes, so is the format mode binary?
-      if (taml.getFormatMode() == Taml::BinaryFormat)
-      {
-         // Yes, so set binary compression.
-         taml.setBinaryCompression(compressed);
-      }
-      else
-      {
-         // No, so warn.
-         Con::warnf("TamlWrite() - Setting binary compression is only valid for BINARY format.");
-      }
+      // Yes, so set binary compression.
+      taml.setBinaryCompression(compressed);
    }
 
    // Write.