Panda3D
waitInterval.cxx
1 // Filename: waitInterval.cxx
2 // Created by: drose (12Sep02)
3 //
4 ////////////////////////////////////////////////////////////////////
5 //
6 // PANDA 3D SOFTWARE
7 // Copyright (c) Carnegie Mellon University. All rights reserved.
8 //
9 // All use of this software is subject to the terms of the revised BSD
10 // license. You should have received a copy of this license along
11 // with this source code in a file named "LICENSE."
12 //
13 ////////////////////////////////////////////////////////////////////
14 
15 #include "waitInterval.h"
16 #include "config_interval.h"
17 
18 TypeHandle WaitInterval::_type_handle;
19 
20 ////////////////////////////////////////////////////////////////////
21 // Function: WaitInterval::priv_step
22 // Access: Published, Virtual
23 // Description: Advances the time on the interval. The time may
24 // either increase (the normal case) or decrease
25 // (e.g. if the interval is being played by a slider).
26 ////////////////////////////////////////////////////////////////////
27 void WaitInterval::
28 priv_step(double t) {
29  // The WaitInterval is normally not run directly; it just fills up
30  // time when constructing a MetaInterval (specifically, a Sequence).
31 #ifndef NDEBUG
32  if (verify_intervals) {
33  interval_cat.info()
34  << "running WaitInterval. Intentional?\n";
35  }
36 #endif
37  check_started(get_class_type(), "priv_step");
38  _state = S_started;
39  _curr_t = t;
40 }
virtual void priv_step(double t)
Advances the time on the interval.
TypeHandle is the identifier used to differentiate C++ class types.
Definition: typeHandle.h:85