Jump to content

Recommended Posts

Posted

Can the Time class get a delta time added to it please?

GetSpeed is really confusing, and isn't very useful.

Also, people transitioning from Unity would understand this a lot better.

 

It wouldn't be very difficult, you could just write a small function that returned:

1.0 / Time:UPS()

 

Then you could just go:

timer = timer + Time.deltaTime

 

and the time will count up in seconds, regardless of the frame rate

Posted

Just multiply your values by GetSpeed(). I'm not sure what's confusing about that?

 

If your PC is the "perfect" timing GetSpeed() returns 1 (so multiplying your value by this does nothing to change it)

If your PC is really fast GetSpeed() returns < 1 (so multiplying by this will reduce your value to slow it down)

If your PC is really slow GetSpeed() returns > 1 (so multiplying by this will increase your value to speed it up)

  • Upvote 1
Posted

I guess "makes sense" just depends on what you're used to smile.png, but seriously you use it the same you do delta don't you? You multiply your values by it.

Posted

I don't want to replace GetSpeed(), and I don't want to start an argument over what "makes more sense". I'd like to see both available, and for people to choose what they'd rather use.

Posted

You can always map GetSpeed to a DeltaTime variable in a custom script. I honestly doubt if Josh would change the API to this. Regardless of the argument I given, I think Josh would reply within the lines of: this is Leadwerks, not Unity.

  • Upvote 2

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...