diff --git a/direct/src/deadrec/config_deadrec.cxx b/direct/src/deadrec/config_deadrec.cxx index fe1dc47a56..320735c369 100644 --- a/direct/src/deadrec/config_deadrec.cxx +++ b/direct/src/deadrec/config_deadrec.cxx @@ -23,6 +23,11 @@ ConfigureFn(config_deadrec) { init_libdeadrec(); } +ConfigVariableBool accept_clock_skew +("accept-clock-skew", false, + PRC_DESC("This controls the default value of " + "SmoothMover::get_accept_clock_skew().")); + //////////////////////////////////////////////////////////////////// // Function: init_libdeadrec diff --git a/direct/src/deadrec/config_deadrec.h b/direct/src/deadrec/config_deadrec.h index d2101c0efa..47e4502b81 100644 --- a/direct/src/deadrec/config_deadrec.h +++ b/direct/src/deadrec/config_deadrec.h @@ -17,9 +17,12 @@ #include "directbase.h" #include "notifyCategoryProxy.h" +#include "configVariableBool.h" NotifyCategoryDecl(deadrec, EXPCL_DIRECT, EXPTP_DIRECT); +extern ConfigVariableBool accept_clock_skew; + extern EXPCL_DIRECT void init_libdeadrec(); #endif diff --git a/direct/src/deadrec/smoothMover.cxx b/direct/src/deadrec/smoothMover.cxx index de66d65d52..ed43a7c9ce 100644 --- a/direct/src/deadrec/smoothMover.cxx +++ b/direct/src/deadrec/smoothMover.cxx @@ -15,6 +15,7 @@ #include "smoothMover.h" #include "pnotify.h" #include "compose_matrix.h" +#include "config_deadrec.h" //////////////////////////////////////////////////////////////////// // Function: SmoothMover::Constructor @@ -57,7 +58,7 @@ SmoothMover() { _smooth_mode = SM_off; _prediction_mode = PM_off; _delay = 0.2; - _accept_clock_skew = true; + _accept_clock_skew = accept_clock_skew; _directional_velocity = true; _default_to_standing_still = true; _max_position_age = 0.25;