Pārlūkot izejas kodu

Update JsonDetail.cpp

Added video file existence check
Macron1Robot 11 gadi atpakaļ
vecāks
revīzija
9494c6d335
1 mainītis faili ar 7 papildinājumiem un 0 dzēšanām
  1. 7 0
      lib/JsonDetail.cpp

+ 7 - 0
lib/JsonDetail.cpp

@@ -949,6 +949,12 @@ namespace
 		{
 			return testAnimation(node.String(), node.meta);
 		}
+		
+		std::string videoFile(const JsonNode & node)
+		{
+			TEST_FILE(node.meta, "Video/", node.String(), EResType::VIDEO);
+			return "Video file \"" + node.String() + "\" was not found";
+		}
 
 		std::string imageFile(const JsonNode & node)
 		{
@@ -1040,6 +1046,7 @@ namespace
 		ret["soundFile"]     = Formats::soundFile;
 		ret["defFile"]       = Formats::defFile;
 		ret["animationFile"] = Formats::animationFile;
+		ret["videoFile"]     = Formats::videoFile;
 		ret["imageFile"]     = Formats::imageFile;
 
 		return ret;