Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Window.GetFrameTime is returning strange values  (Read 2011 times)

0 Members and 1 Guest are viewing this topic.

kurozael

  • Newbie
  • *
  • Posts: 11
    • View Profile
Window.GetFrameTime is returning strange values
« on: July 24, 2011, 01:46:19 pm »
I've recently upgraded SFML2 to the latest revision and now my simultation runs extremely fast and GetFrameTime returns "15" - "16" so when I calculate FPS by doing 1.0f / GetFrameTime() I'm getting "FPS" of 0.0666666667 so as you can tell something is seriously wrong.

I've still doing SetFramerateLimit(60.0f)

I have a project due in Tuesday at uni so I hope you can help!

Thanks!  :P

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6287
  • Thor Developer
    • View Profile
    • Bromeon
Window.GetFrameTime is returning strange values
« Reply #1 on: July 24, 2011, 01:53:43 pm »
SFML 2 now works with milliseconds instead of seconds. Sometimes it helps to look at the documentation ;)
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

kurozael

  • Newbie
  • *
  • Posts: 11
    • View Profile
Window.GetFrameTime is returning strange values
« Reply #2 on: July 24, 2011, 01:57:06 pm »
Sorry, this was an unexpected change! Thanks a lot man!

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6287
  • Thor Developer
    • View Profile
    • Bromeon
Window.GetFrameTime is returning strange values
« Reply #3 on: July 24, 2011, 02:18:38 pm »
There are also other changes that you might not expect, here is a list of them.
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development: