From 578135cad4380fc0dee526e090ab524934bb3a2a Mon Sep 17 00:00:00 2001 From: MaxED Date: Tue, 24 May 2016 22:11:29 +0000 Subject: [PATCH] Added SNDINFO parser. Currently only the "$ambient" command is parsed. The values are used to update the titles of "Ambient Sound NN" things and to populate "ambient_sounds" Game Configuration enum. Fixed, DECORATE parser: actors, which used "replaces" keyword and didn't have DoomEdNum were ignored. Updated documentation ("(G)ZDoom text lumps support" page). --- Build/Configurations/Includes/ZDoom_misc.cfg | 11 ++ .../Configurations/Includes/ZDoom_things.cfg | 11 +- Help/gzdb/text_lumps.html | 6 +- Source/Core/Builder.csproj | 1 + Source/Core/Config/ScriptConfiguration.cs | 1 + Source/Core/Config/ThingTypeInfo.cs | 7 +- Source/Core/Data/DataManager.cs | 103 ++++++++++++++++-- Source/Core/Data/DataReader.cs | 25 +++-- Source/Core/Data/PK3StructuredReader.cs | 22 ++++ Source/Core/Data/WADReader.cs | 7 ++ Source/Core/ZDoom/ActorStructure.cs | 2 +- Source/Core/ZDoom/SndInfoParser.cs | 94 ++++++++++++++++ 12 files changed, 260 insertions(+), 30 deletions(-) create mode 100644 Source/Core/ZDoom/SndInfoParser.cs diff --git a/Build/Configurations/Includes/ZDoom_misc.cfg b/Build/Configurations/Includes/ZDoom_misc.cfg index e3331977..e9214876 100644 --- a/Build/Configurations/Includes/ZDoom_misc.cfg +++ b/Build/Configurations/Includes/ZDoom_misc.cfg @@ -861,6 +861,17 @@ enums 75 = "75%"; 100 = "100%"; } + + ambient_sounds + { + 0 = "None"; + } + + sound_sequences + { + 0 = "None"; + 255 = "Default"; + } setadd { diff --git a/Build/Configurations/Includes/ZDoom_things.cfg b/Build/Configurations/Includes/ZDoom_things.cfg index 041385cb..13740cdc 100644 --- a/Build/Configurations/Includes/ZDoom_things.cfg +++ b/Build/Configurations/Includes/ZDoom_things.cfg @@ -114,10 +114,7 @@ zdoom { title = "Sound Sequence Index"; type = 11; - enum - { - 255 = "Default"; - } + enum = "sound_sequences"; } } @@ -193,6 +190,8 @@ zdoom arg0 { title = "Ambient Sound Index"; + type = 11; + enum = "ambient_sounds"; } arg1 { @@ -221,6 +220,8 @@ zdoom arg0 { title = "Sound Sequence Index"; + type = 11; + enum = "sound_sequences"; } arg1 { @@ -235,6 +236,8 @@ zdoom arg0 { title = "Ambient Sound Index"; + type = 11; + enum = "ambient_sounds"; } arg1 { diff --git a/Help/gzdb/text_lumps.html b/Help/gzdb/text_lumps.html index 25817d50..d1157263 100644 --- a/Help/gzdb/text_lumps.html +++ b/Help/gzdb/text_lumps.html @@ -38,7 +38,8 @@ Both new and old MAPINFO definition styles are supported.
You can use "//$GZDB_SKIP" special comment to abort parsing of the current file.
DoomEdNum overrides are supported.
- SpawnNums overrides are supported. The values are used to update "spawnthing" Game Configuration enum.

+ SpawnNums overrides are supported. The values are used to update "spawnthing" Game Configuration enum.
+
In addition, following values from (Z)MAPINFO are supported by Visual mode: