mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-01 17:35:34 -04:00
respect min_dt even in non-real-time mode
This commit is contained in:
parent
23f4c72116
commit
220c028394
@ -156,6 +156,9 @@ get_net_frame_rate() const {
|
||||
////////////////////////////////////////////////////////////////////
|
||||
INLINE double ClockObject::
|
||||
get_dt() const {
|
||||
if (_max_dt > 0.0) {
|
||||
return min(_max_dt, _dt);
|
||||
}
|
||||
return _dt;
|
||||
}
|
||||
|
||||
|
@ -139,9 +139,6 @@ tick() {
|
||||
case M_normal:
|
||||
// Time runs as it will; we simply report time elapsing.
|
||||
_dt = _actual_frame_time - old_time;
|
||||
if (_max_dt > 0.0) {
|
||||
_dt = min(_max_dt, _dt);
|
||||
}
|
||||
_reported_frame_time = _actual_frame_time;
|
||||
break;
|
||||
|
||||
@ -176,9 +173,6 @@ tick() {
|
||||
_reported_frame_time = _actual_frame_time;
|
||||
}
|
||||
|
||||
if (_max_dt > 0.0) {
|
||||
_dt = min(_max_dt, _dt);
|
||||
}
|
||||
break;
|
||||
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user