Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 2299


Ignore:
Timestamp:
Nov 30, 2008, 12:29:17 PM (16 years ago)
Author:
rgrieder
Message:

Applied ugliest hack ever: When ticking the objects (code position of this is already a big hack) and dt is larger than 1.0f, we assume that the level was just loaded before and set dt = 0.
The problem is that usually, after loading, dt is for instance about 3s for my debug version. That translates all entities by a huge amount.

To actually solve this problem correctly, we will have some very intensive discussions about certain subjects..

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/physics/src/orxonox/gamestates/GSGraphics.cc

    r2103 r2299  
    244244        /*** HACK *** HACK ***/
    245245        // Call the Tickable objects
     246        float leveldt = dt;
     247        if (dt > 1.0f)
     248        {
     249            // just loaded
     250            leveldt = 0.0f;
     251        }
    246252        for (ObjectList<Tickable>::iterator it = ObjectList<Tickable>::begin(); it; ++it)
    247             it->tick(time.getDeltaTime());
     253            it->tick(leveldt);
    248254        /*** HACK *** HACK ***/
    249255
Note: See TracChangeset for help on using the changeset viewer.