Noise: Difference between revisions

From The Cataclysm: Dark Days Ahead Wiki
Jump to navigation Jump to search
 
(13 intermediate revisions by 5 users not shown)
Line 1: Line 1:
When the game calculates the volume level of a sound, it takes the "noise" and multiples it by 1.5 (for example, an unsilenced base [[G19]] using [[9mm]] ammo would have a noise of 20 + ⌊18 * .8⌋ = 34,  which would then be multiplied by 1.5 for a grand total volume rating of 51).
When the game calculates the volume level of a sound, it takes the "noise" and multiples it by 1.5 (for example, an unsilenced base [[G19]] using [[9mm]] ammo would have a noise of 20 + ⌊18 * .8⌋ = 34,  which would then be multiplied by 1.5 for a grand total volume rating of 51).
== Monsters' alertness ==
== Monsters' alertness ==
Volume generally is equal to distance in squares from which sound can be heard by non-[[deaf]] [[monsters]] with HEARS flag. Though their urge to investigate that sound is based on difference between volume and distance — monster will ignore<!-- I guess actually it will freeze and forget it's last target, because it's "urge to follow" will be reset, but hush --> 10 volume sound in 10 square range, but if it is in 5 square range monster will follow to its source for 5 turns, in 4 range - for 6 turns, etc. Also monsters ignore sounds in two-square radius, it is implying that they rely upon other senses here.
Volume is generally equal to the distance in squares from which the sound can be heard by non-[[deaf]] [[monsters]] with the HEARS flag, though their urge to investigate that sound is based on the difference between volume and distance — the monster will ignore<!-- I guess actually it will freeze and forget it's last target, because it's "urge to follow" will be reset, but hush --> a 10 volume sound in a 10 square range, but if it is within 5 square range of a 10 volume sound the monster will follow to its source for 5 turns, in 4 range - for 6 turns, etc. Also, monsters ignore sounds in a two-square radius, implying that they rely upon other senses here.


Other things are monsters with additional GOODHEARING flag. They hear sounds at two times larger distance, follow to its source six times longer and they never ever ignore nearby sounds.
One thing to note are monsters with the GOODHEARING flag. They hear sounds at twice the distance, follow sounds to their source six times longer, and never ignore nearby sounds.


Some enemies can be scared with loud enough sounds, others to the contrary, angered more.
Some [[enemies|enemies]] can be scared with loud sounds, such as certain wildlife like [[black bear]]s, while others are angered more by loud sounds.
 
== Spawn boost ==
Zombies spawn in waves over a time function. Extremely loud sounds reduce the spawn timer for the next wave, in addition to drawing in all of the already spawned zombies littering the area. Note that spawn times and spawn amounts are directly proportional. This means that if you spawn and draw a lot of zombies, and slaughter them quickly, you will get a small break before more zombies are spawned in (This can be magnified by killing the "wave" with silent weapons). You can easily, however, get almost infinite zombies spawning if you choose to eliminate "waves" with a loud weapon. Any volume above 60 lowers the spawn timer by a formula based on how much over 60 the volume is.
 
<!--
// Loud sounds make the next spawn sooner!
int spawn_range = int(MAPSIZE / 2) * SEEX;
if (vol >= spawn_range) {
  int max = (vol - spawn_range);
  int min = int(max / 6);
  if (max > spawn_range * 4)
  max = spawn_range * 4; // 48
  if (min > spawn_range * 4)
  min = spawn_range * 4;
  int change = rng(min, max);
  if (nextspawn < change)
  nextspawn = 0;
  else
  nextspawn -= change;
}
-->
<!--
// Next, display the sound as the player hears it
if (description == "")
  return; // No description (e.g., footsteps)
if (u.has_disease(DI_DEAF))
  return; // We're deaf, can't hear it


if (u.has_bionic(bio_ears))
  vol *= 3.5;
if (u.has_trait(PF_BADHEARING))
  vol *= .5;
if (u.has_trait(PF_CANINE_EARS))
  vol *= 1.5;
int dist = rl_dist(x, y, u.posx, u.posy);
if (dist > vol)
  return; // Too far away, we didn't hear it!
if (u.has_disease(DI_SLEEP) &&
    ((!u.has_trait(PF_HEAVYSLEEPER) && dice(2, 20) < vol - dist) ||
      ( u.has_trait(PF_HEAVYSLEEPER) && dice(3, 20) < vol - dist)  )) {
  u.rem_disease(DI_SLEEP);
  add_msg("You're woken up by a noise.");
  return;
}
cancel_activity_query("Heard a noise!");
// We need to figure out where it was coming from, relative to the player
int dx = x - u.posx;
int dy = y - u.posy;
// If it came from us, don't print a direction
if (dx == 0 && dy == 0) {
  if (description[0] >= 'a' && description[0] <= 'z')
  description[0] += 'A' - 'a'; // Capitalize the sound
  add_msg("%s", description.c_str());
  return;
}
std::string direction = direction_name(direction_from(u.posx, u.posy, x, y));
add_msg("From the %s you hear %s", direction.c_str(), description.c_str());
}
-->
== Common sources of noise ==
== Common sources of noise ==
* [[Character]]'s footsteps. By default moving creates 6 volume noise. It can be decreased to 2 with [[Light Step]] trait, and with [[leg tentacles]] mutation movement is completely silent.
* [[Character]]'s footsteps. By default moving creates 6 volume noise.  
** [[Light Step]] trait decreases noise to 2.
** Wearing active [[RM13 combat armor|RM13 armor]] decreases noise to 2.
** [[Leg tentacles]] mutation makes movement completely silent.
** [[Clumsy]] trait increases noise to 10
** [[Squeaky Ankles]] CBM increases it to 12.
* Size influences the noise made while moving. Tiny beings are totally silent, small ones reduce noise to 33% of normal. Large creatures increase it by 50%, and huge ones double the sound made. Loud monsters (the LOUDMOVES flag) increase sound made by an additional 6. This is important if you mount a [[Horse|horse]] or something similar.
* {{k|s}}mashing things.
* {{k|s}}mashing things.
* [[Firearms]]. Their noisiness is based on [[ammunition]] damage ("Noise" volume = ammo_damage * 0.8, +20 if result is greater than 5, plus [[gunmods]] modifiers). With exception of [[batteries]], [[plutonium cell]]s, [[fusion pack]]s, [[40mm grenade]]s (they create noise with fixed 8 volume) and [[gasoline]] (4 volume). And [[bolts]], [[arrows]], [[pebble ammo|pebbles]] and [[darts]] are completely silent.
* [[Firearms]]. Their noisiness is based on [[ammunition]] damage ("Noise" volume = ammo_damage * 0.8, +20 if result is greater than 5, plus [[gunmods]] modifiers). With exception of [[battery|batteries]], [[plutonium cell]]s, [[fusion pack]]s, [[40mm grenade]]s (they create noise with fixed 8 volume) and [[gasoline]] (4 volume). [[bolts]], [[arrows]], and [[pebble ammo|pebbles]] are completely silent.
* [[Vehicles]] (generate noise upon thrusting). Vehicle noise is equal to 0.25 * engine power, 0.25 * 0.4 * engine power if a [[muffler]] is installed.
* [[Vehicles]] (generate noise upon accelerating). Vehicle noise is equal to 0.25 * engine power, 0.25 * 0.4 * engine power if a [[muffler]] is installed.
* [[Explosions]] create noise with volume ten times bigger than the explosion power.
* [[Explosions]] create noise with volume ten times bigger than the explosion power.
* [[Throw]]ing items causes noise if they hit the ground, either 16 for glass breaking, or 8 "thud" for everything else.
* [[Throw]]ing items causes noise if they hit the ground, either 16 for glass breaking, or 8 "thud" for everything else.
* {{k|C}}: Yelling, if you don't cover your mouth. Mouth encumbrance muffles the noise you make by yelling.


== Character's awareness ==
== Character's awareness ==
<!-- Character will not hear any sounds without description (e.g., footsteps) or while deaf -->
<!-- Character will not hear any sounds without description (e.g., footsteps) or while deaf -->
By default volume is equal to range for player as well; thus, the louder a sound, the farther away a player-character can be and still hear it.
By default, volume is equal to range for the player, as well; thus, the louder a sound, the farther away a player-character can be and still hear it.


[[Enhanced Hearing]] bionic multiplies sounds' initial volume by 3.5; the [[Canine Ears]] mutation multiplies it by 1.5, and [[Poor Hearing]] halves the initial volume.
* [[Enhanced Hearing]] bionic multiplies sounds' initial volume by 3.5.
* [[Canine Ears]] mutation multiplies it by 1.5.
* [[Ursine Ears]] and [[Feline Ears]] multiply it by 1.25.
* [[Lupine Ears]] multiply it by 1.75.
* [[Rodent Ears]] multiply it by 2.
* [[Poor Hearing]] halves the initial volume.
* [[Deaf]] characters are, well, deaf and can't hear anything at all.


There is a chance to become [[deaf|Deafened]] for up to 40 turns if a sound is loud and close enough. [[Enhanced Hearing]], as advertised, filters that out.
There is a chance to become [[deaf|deafened]] for up to 40 turns if a sound is loud and close enough. Be careful. Extreme and repeated sounds can cause extremely long deafness. Huge explosions and collapsing buildings are the likeliest to deafen you. [[Enhanced Hearing]], as advertised, filters that out.
<!--
if (!u.has_bionic(bio_ears) && rng( (vol - dist) / 2, (vol - dist) ) >= 150) {
  int duration = (vol - dist - 130) / 4;
  if (duration > 40)
  duration = 40;
  u.add_disease(DI_DEAF, duration, this);
}
-->


If the character is sleeping when a noise happens nearby, that has a chance to wake.  The noise's volume minus its distance must be bigger than a 2d20 roll (3d20 with [[Heavy Sleeper]]) to wake up the character. However, the character will not know what sound woke him or her up.
If the character is [[Sleep|sleeping]] when a noise happens nearby, they have a wake-up chance that depends on the sound's volume and [[Heavy Sleeper]] or [[Very Heavy Sleeper]] traits. However, the character will not know what sound awoke them.


If the character is busy performing a task when he hears a loud noise, the game will alert the player to the noise and ask whether you want to interrupt the activity. You are never interrupted for sounds that come from your position.
If the character is busy performing a task when he hears a loud noise, the game will alert the player to the noise and ask whether you want to interrupt the activity. You are never interrupted for sounds that come from your position.
=== Footsteps ===
=== Footsteps ===
Monster's footsteps do not produce any actual sound in contrast to character's footsteps, so they can be heard only by player and do not affect other monsters alertness. Moreover, footsteps of any volume can be detected by player from any distance. Volume and distance only affect the markers' precision.
Monsters' footsteps do not produce any actual sound, in contrast to the character's footsteps. These can be heard only by the player and do not attract other monsters' attention. Moreover, footsteps of any volume can be detected by the player from any distance. Volume and distance only affect the sound markers' precision.


Volume of footsteps is based on the critter's size; digging critters are much more noisy.
Footstep volume is based on a critter's size; digging critters are noisier.
<!--
<!--
base = 6
base = 6
Line 106: Line 51:
case MS_HUGE:  *= 2;
case MS_HUGE:  *= 2;
-->
-->
Tiny, flying and already visible enemies do not produce footsteps at all. Markers are never placed on visible tiles.
Tiny, flying, and already visible enemies do not produce footsteps at all. Markers are never placed on visible tiles.


Without the [[Enhanced Hearing]] bionic, footstep marks will be inaccurate by at least one tile (it depends on distance), though the bionic's overall effect is fairly small.  (Its bonus is the same size as the penalty for [[Poor Hearing]].)
Without the [[Enhanced Hearing]] bionic, footstep marks will be inaccurate by at least one tile (depends on distance), although the bionic's overall effect is fairly small.  Its bonus is the same size as the penalty for [[Poor Hearing]].
<!--
<!--
  int err_offset;
  int err_offset;

Latest revision as of 16:58, 21 April 2022

When the game calculates the volume level of a sound, it takes the "noise" and multiples it by 1.5 (for example, an unsilenced base G19 using 9mm ammo would have a noise of 20 + ⌊18 * .8⌋ = 34, which would then be multiplied by 1.5 for a grand total volume rating of 51).

Monsters' alertness

Volume is generally equal to the distance in squares from which the sound can be heard by non-deaf monsters with the HEARS flag, though their urge to investigate that sound is based on the difference between volume and distance — the monster will ignore a 10 volume sound in a 10 square range, but if it is within 5 square range of a 10 volume sound the monster will follow to its source for 5 turns, in 4 range - for 6 turns, etc. Also, monsters ignore sounds in a two-square radius, implying that they rely upon other senses here.

One thing to note are monsters with the GOODHEARING flag. They hear sounds at twice the distance, follow sounds to their source six times longer, and never ignore nearby sounds.

Some enemies can be scared with loud sounds, such as certain wildlife like black bears, while others are angered more by loud sounds.

Common sources of noise

  • Character's footsteps. By default moving creates 6 volume noise.
  • Size influences the noise made while moving. Tiny beings are totally silent, small ones reduce noise to 33% of normal. Large creatures increase it by 50%, and huge ones double the sound made. Loud monsters (the LOUDMOVES flag) increase sound made by an additional 6. This is important if you mount a horse or something similar.
  • smashing things.
  • Firearms. Their noisiness is based on ammunition damage ("Noise" volume = ammo_damage * 0.8, +20 if result is greater than 5, plus gunmods modifiers). With exception of batteries, plutonium cells, fusion packs, 40mm grenades (they create noise with fixed 8 volume) and gasoline (4 volume). bolts, arrows, and pebbles are completely silent.
  • Vehicles (generate noise upon accelerating). Vehicle noise is equal to 0.25 * engine power, 0.25 * 0.4 * engine power if a muffler is installed.
  • Explosions create noise with volume ten times bigger than the explosion power.
  • Throwing items causes noise if they hit the ground, either 16 for glass breaking, or 8 "thud" for everything else.
  • C: Yelling, if you don't cover your mouth. Mouth encumbrance muffles the noise you make by yelling.

Character's awareness

By default, volume is equal to range for the player, as well; thus, the louder a sound, the farther away a player-character can be and still hear it.

There is a chance to become deafened for up to 40 turns if a sound is loud and close enough. Be careful. Extreme and repeated sounds can cause extremely long deafness. Huge explosions and collapsing buildings are the likeliest to deafen you. Enhanced Hearing, as advertised, filters that out.

If the character is sleeping when a noise happens nearby, they have a wake-up chance that depends on the sound's volume and Heavy Sleeper or Very Heavy Sleeper traits. However, the character will not know what sound awoke them.

If the character is busy performing a task when he hears a loud noise, the game will alert the player to the noise and ask whether you want to interrupt the activity. You are never interrupted for sounds that come from your position.

Footsteps

Monsters' footsteps do not produce any actual sound, in contrast to the character's footsteps. These can be heard only by the player and do not attract other monsters' attention. Moreover, footsteps of any volume can be detected by the player from any distance. Volume and distance only affect the sound markers' precision.

Footstep volume is based on a critter's size; digging critters are noisier. Tiny, flying, and already visible enemies do not produce footsteps at all. Markers are never placed on visible tiles.

Without the Enhanced Hearing bionic, footstep marks will be inaccurate by at least one tile (depends on distance), although the bionic's overall effect is fairly small. Its bonus is the same size as the penalty for Poor Hearing.