]> git.mxchange.org Git - flightgear.git/blobdiff - src/Instrumentation/marker_beacon.cxx
Vivian MEAZZA:
[flightgear.git] / src / Instrumentation / marker_beacon.cxx
index 175eac49b82d201a834aad1e8ebd287b1dcad7b0..018d5baf7e4c2d62247b5ed1cd9067b0d904d3a9 100644 (file)
@@ -46,7 +46,8 @@ FGMarkerBeacon::FGMarkerBeacon(SGPropertyNode *node) :
     middle_blink(false),
     inner_blink(false),
     name("marker-beacon"),
-    num(0)
+    num(0),
+    _time_before_search_sec(0.0)
 {
     SGPath path( globals->get_fg_root() );
     SGPath term = path;
@@ -97,6 +98,7 @@ FGMarkerBeacon::init ()
 
     SGPropertyNode *node = fgGetNode(branch.c_str(), num, true );
     // Inputs
+    sound_pause = fgGetNode("/sim/sound/pause", false);
     lon_node = fgGetNode("/position/longitude-deg", true);
     lat_node = fgGetNode("/position/latitude-deg", true);
     alt_node = fgGetNode("/position/altitude-ft", true);
@@ -150,7 +152,8 @@ FGMarkerBeacon::update(double dt)
 {
     need_update = false;
 
-    if ( has_power() && serviceable->getBoolValue() ) {
+    if ( has_power() && serviceable->getBoolValue()
+            && !sound_pause->getBoolValue()) {
 
        // On timeout, scan again
        _time_before_search_sec -= dt;