Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
boris

[GZDB plugin] Sound Propagation Mode

Recommended Posts

This plugin adds a two modes to GZDoom Builder.

Plugin: https://github.com/biwa/soundpropagationmode/releases/download/v1.0.0-rc1/SoundPropagation-v1.0.0-rc1.zip
Source repository: https://github.com/biwa/soundpropagationmode

Sound Propagation Mode

This mode shows how sound propagates from the currently highlighted sector
through the map.

Following colors are used:

  • dark green: the currently highlighted sector
  • light green: sounds can travel unhindered to these sectors
  • yellow: these sectors are behind a sound blocking line, but sound will still travel to this sector from the highlighted sector
  • gray: sounds from the highlighted sector will not travel to these sectors
  • red: these lines have the block sound flag set
Screenshot for the starting sector of Doom 2 map01:





ZDoom Sound Environment Mode

This mode shows the sound environments in ZDoom maps (both Hexen format and UDMF). The gray areas do not belong to a sound environment.

The mode also supplies a docker that supplies information about the sound environments. It will display the sound environments, the SoundEnvironment things belonging to them and also the lines that are limit the sound environments. Clicking on the sound environments, things or lines in the list will center the map view on those objects.

This mode can also help you find problems (i.e. behavior that you probably that you probably did not intend). If there are any problems with a sound environment a warning sign will displayed in the list at the affected thing or line (the icon will bubble up the tree to make it easier to find when the whole list is collapsed).

Following problems are detected:
  • One-sided lines that are set to be a sound zone boundary
  • Two-sided lines that are set to be a sound zone boundary, but the sectors on both sides belong to the same sound environment
  • Multiple non-dormant SoundEnivornment things
Note that the latter two can be caused by sound environments unintentionally bleeding into other sectors (i.e. not correctly sealed sound environments).

Screenshot of ZDCMP2:





Version History

1.0.0 (2015-xx-xx)
  • Changed the ways linedefs are drawn in both modes. They now ignore any special coloring (like line specials, 3D floors etc.), so it's easier to see the important information
  • Fixed a bug in Sound Environment Mode, where the map would zoom to the first sound environment, when the Sound Environment docker is not pinned and shown for the first time
  • Fixed problems when opening another map from the same WAD while being in Sound Propagation Mode or Sound Environment Mode
  • Discovering sound environments now works asynchronously. This does not increase performance, but the UI stays responsive while the map is processed. The mode also tries to process sound environments close to your current view first. Sound environments may have gaps in numbering. This is nothing to worry about, it's not missing any sound environments
  • In Sound Propagation Mode sectors are now combined into sound propagation domains (where sound will always be propagated freely). This is a big increase in performance for complex maps. Visually nothing changed
0.9.3 (2014-01-07)
  • Added ZDoom sound environment mode
  • Things that are in the affected sectors and don't have the deaf/ambush flag set (i.e. monsters that will come for the player when they hear him/her) are now displayed solidly
  • Thing filters are now taken into account
0.9.2 (2015-01-04)
  • Fixed dates in SoundPropagation.txt file (to YYYY-MM-DD)
  • Added color configuration dialog (accessible from the tool bar when in Sound Propagation Mode
  • Removed some unused code
0.9.1 (2015-01-03)
  • Fixed a typo in SoundPropagation.txt
  • Fixed a bug where sound would propagate through sectors even though their heights should not allow it
0.9.0 (2015-01-03)
  • First release

Share this post


Link to post

I want to make sure and ask this ASAP while you're still thinking about this: is it possible to change the colors? I, like 10% or so of dudes, am red-green color blind, and (0,128,0) and (128,128,0) are very difficult for me to distinguish at a glance. (0,128,0) and (0,96,0) aren't super easy for me either. I would really appreciate it if you could change dark green to more like (0,48,0) and yellow to more like (200,200,0) so I can easily tell the difference in intensity.

Share this post


Link to post

Awesome. This will come in very handy.

Suggestion (if it isn't already in or supported): Can this be extended (or might need a different plugin) to support ZDoom Sound Environment (#9048) propagation, blocked by lines flagged as "Sound Zone Boundary"?

Share this post


Link to post
Linguica said:

I want to make sure and ask this ASAP while you're still thinking about this: is it possible to change the colors? I, like 10% or so of dudes, am red-green color blind, and (0,128,0) and (128,128,0) are very difficult for me to distinguish at a glance. (0,128,0) and (0,96,0) aren't super easy for me either. I would really appreciate it if you could change dark green to more like (0,48,0) and yellow to more like (200,200,0) so I can easily tell the difference in intensity.

I put up a new release with configurable colors: https://github.com/biwa/soundpropagationmode/releases/download/v0.9.2/SoundPropagation-v0-9-2.zip

When you enter Sound Propagation Mode a new icon is added to the tool bar, from which you can access the dialog to change the colors:


MTrop said:

Suggestion (if it isn't already in or supported): Can this be extended (or might need a different plugin) to support ZDoom Sound Environment (#9048) propagation, blocked by lines flagged as "Sound Zone Boundary"?

Sounds interesting, but rather out of scope of this plugin. Does anybody actually use this feature?

Share this post


Link to post
boris said:

Sounds interesting, but rather out of scope of this plugin. Does anybody actually use this feature?

Yes.

Share this post


Link to post

Could you possibly make a version that is compatible with Doom Builder 2? Attempting to load the plugin into DB2 causes the program to crash at start up. I'd really like to try using this with my vanilla map projects.

Share this post


Link to post

^Maybe you don't know that GZDB can be very well used to make vanilla or Boom maps. The "GZDoom" in its name might be misleading, but it only implies support for advanced editor features that come in handy when mapping (not only) for GZDoom, but it does not mean rejection of basic map formats. Either way - I agree with you, I'd like to use this in DB2 too, if only it was possible. Would it be possible, boris?

Share this post


Link to post
boris said:

Sounds interesting, but rather out of scope of this plugin. Does anybody actually use this feature?


Absolutely. It's used extensively in Square.

And I'm actually hoping that MORE mappers start using it. Used properly, it really helps sell a fictional world.


Maybe add a way to arbitrarily define start/end zones? Like, what linedef flag or sector attributes slow/stop propagation?

Sound Propagation is "slowed" by one "block sound" line, and "stopped" by a second "block sound" line or a linedef whose sector references have overlapping ceiling/floor height (floor >= ceiling).

Sound Environment is stopped dead by "Sound Zone Boundary" linedef flags.

Both can propagate from the current-selected sector, so it isn't a major stretch, but then again, I'm not sure how GZDB's plugin interface works. :/

Share this post


Link to post

It's actually quite different. Sound propagation is dynamic, recalculated from the currently highlighted sector. ZDoom sound environments are static, for them it really only makes sense to show all of them at the same moment. Like this:

Share this post


Link to post

Interactive in what way? Right now it's just for displaying, and for that it's better to see where all the sound environment domains are, and not just display them when you happen to highlight one of the right sectors by chance.

Share this post


Link to post

I meant, "mouse over a sector and it highlights the whole region," but I think your implementation's fine.

Does it highlight the affecting Environment Thing as well? Those things can get pretty hidden.

Share this post


Link to post
MTrop said:

I meant, "mouse over a sector and it highlights the whole region," but I think your implementation's fine.

Does it highlight the affecting Environment Thing as well? Those things can get pretty hidden.

Additionaly highlighting is just a small step from where it is now.

The SoundEnironment things are displayed without alpha (compared to the other things, which show like in sectors mode). But that doesn't really help much. They are pretty small to begin with, and them being of light gray color doesn't make it any better. Or can you spot the SoundEnvironment things in the purple area in the screenshot I posted earlier? ;)
My idea is to add a docker (those things on the right side, like "Undo/Redo") to display some info about the sound environments, including the things.

Share this post


Link to post
boris said:

The SoundEnironment things are displayed without alpha (compared to the other things, which show like in sectors mode). But that doesn't really help much. They are pretty small to begin with, and them being of light gray color doesn't make it any better.


Can you increase their scale so that they're drawn bigger in that mode?

Share this post


Link to post
Gez said:

Can you increase their scale so that they're drawn bigger in that mode?

Or mark each of them with a red X.

Share this post


Link to post

That'd be all pretty clumsy and not really necessary with the docker:



Clicking on one of the sound environments in the tree will zoom the view to this sound environment, clicking on the things or linedefs will zoom to them.

Share this post


Link to post

I hope next plugin is "show the area the monster sees". Often it's hard to tell if a monster will notice the player at a certain spot.

Share this post


Link to post

New release with the sound environment mode is available: https://github.com/biwa/soundpropagationmode/releases/download/v0.9.3/SoundPropagation-v0-9-3.zip

ZDoom Sound Environment Mode

This mode shows the sound environments in ZDoom maps (both Hexen format and UDMF). The gray areas do not belong to a sound environment.

The mode also supplies a docker that supplies information about the sound environments. It will display the sound environments, the SoundEnvironment things belonging to them and also the lines that are limit the sound environments. Clicking on the sound environments, things or lines in the list will center the map view on those objects.

This mode can also help you find problems (i.e. behavior that you probably that you probably did not intend). If there are any problems with a sound environment a warning sign will displayed in the list at the affected thing or line (the icon will bubble up the tree to make it easier to find when the whole list is collapsed).

Following problems are detected:

  • One-sided lines that are set to be a sound zone boundary
  • Two-sided lines that are set to be a sound zone boundary, but the sectors on both sides belong to the same sound environment
  • Multiple non-dormant SoundEnivornment things
Note that the latter two can be caused by sound environments unintentionally bleeding into other sectors (i.e. not correctly sealed sound environments).

Screenshot of ZDCMP2:

Share this post


Link to post

New version: https://github.com/biwa/soundpropagationmode/releases/download/v1.0.0-rc1/SoundPropagation-v1.0.0-rc1.zip

This is RC1 for version 1.0.0. Changes:

  • Changed the ways linedefs are drawn in both modes. They now ignore any special coloring (like line specials, 3D floors etc.), so it's easier to see the important information
  • Fixed a bug in Sound Environment Mode, where the map would zoom to the first sound environment, when the Sound Environment docker is not pinned and shown for the first time
  • Fixed problems when opening another map from the same WAD while being in Sound Propagation Mode or Sound Environment Mode
  • Discovering sound environments now works asynchronously. This does not increase performance, but the UI stays responsive while the map is processed. The mode also tries to process sound environments close to your current view first. Sound environments may have gaps in numbering. This is nothing to worry about, it's not missing any sound environments
  • In Sound Propagation Mode sectors are now combined into sound propagation domains (where sound will always be propagated freely). This is a big increase in performance for complex maps. Visually nothing changed
If there are no bug reports that's pretty much it for the time being.

Share this post


Link to post

The plugin is now bundled with GZDoom Builder, with following changes since 1.0.0 RC1:
1. Sound Propagation Mode: you can now click on doublesided linedefs to toggle sound blocking flag.
2. Sound Environment Mode: you can now click on doublesided linedefs to toggle sound zone boundary flag.
3. Sound Propagation Mode: reimplemented the highlighting of non-deaf things. Things are now highlighted using selection color.
4. Removed "Show tooltips" checkbox. Tooltips are now always enabled.
5. Fixed, Sound Environment Mode: thing tooltip about multiple active sound environment things was shown even when there was only one active sound environment thing.
6. Fixed, Sound Environment Mode: "Configure colors" toolbar button was not working because of missing action.
7. Fixed, cosmetic: "Configure colors" toolbar icon was missing a tooltip.
8. Fixed, cosmetic: display was not redrawn after changing colors using "Color configuration" window.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×