Reading the delta time

Discussion and feedback on Construct 2

Post » Wed Feb 26, 2014 8:30 am

Hello,

i'w set this little text box:
"DT: "& dt
on my project in order to see the delta time and i must say that it behaves a bit strange.
on my desktop (cca 58-60 fps) shows 0.016/0.015 but every second or so it peaks to some 0.03x
Can anyone explain me why is this?
(i use deltatime as a multiplier for my physics gravity so that slower devices have more gravitiy in order to run the game the same way).

Thanx!
B
31
S
13
G
2
Posts: 752
Reputation: 5,541

Post » Wed Feb 26, 2014 11:18 am

@Ashley

Ashley... can you please comment on this?
B
31
S
13
G
2
Posts: 752
Reputation: 5,541

Post » Wed Feb 26, 2014 11:23 am

Probably just missed v-syncs. It's still correctly measuring delta-time.
Scirra Founder
B
403
S
238
G
89
Posts: 24,654
Reputation: 196,155

Post » Wed Feb 26, 2014 4:04 pm

@Ashley

but since i use that number in my formula it's kinda troubling me...
is there a way to have more steady numbers?

tnx!
B
31
S
13
G
2
Posts: 752
Reputation: 5,541

Post » Thu Feb 27, 2014 12:38 pm

No, it is working correctly and if you are using it properly you'll still get a steady and smooth result.
Scirra Founder
B
403
S
238
G
89
Posts: 24,654
Reputation: 196,155

Post » Thu Feb 27, 2014 4:05 pm

ok, thank you!
B
31
S
13
G
2
Posts: 752
Reputation: 5,541


Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 12 guests