private void skipFramesInExcessTime()
    {
        int skips = 0;
        while ((excessTime > desiredUpdateTime) && (skips < maxFrameSkips))
        {
            excessTime -= desiredUpdateTime;
            game.processLogics();
            skips++;
        }
    }