Deltatiming
A lightweight library for handling deltatime.
Installation
pip install deltatiming
Usage
from deltatiming import Deltatime
dt = Deltatime()
dt.tick()
print('Estimated framerate: '+str(dt.get_framerate()))
Available functions
Deltatime.tick()
Needed to be called before Deltatime.get_delta() and Deltatime.get_framerate()
Deltatime.get_delta()
Gets time after last tick() call.
Deltatime.set_time_scale(value)
Sets time multiplier. Useful for speeding up/slowing down the whole script if the whole script uses deltatime.
Deltatime.get_time_scale()
Returns current time scale.
Deltatime.get_framerate(use_time_scale: bool)
Returns current framerate based on delta time. use_time_scale defaults to False
License
MIT
Metadata
Release files for deltatiming 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| deltatiming-0.1.3.tar.gz | 2.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| deltatiming-0.1.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 5.8 kB
Release files / deltatiming-0.1.3.tar.gz
| Download URL | deltatiming-0.1.3.tar.gz |
|---|---|
| Size | 2.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
39de57ea0349ccef26286fbcc72f091b1f2893b0680d87ea86a2a7afec123263
|
|
BLAKE2b-256 checksum How to use checksums |
2818f8745be9c5a950177d7b126d177b8e163c15a5f9724f0a120846da0f438c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.1
|
Release files / deltatiming-0.1.3-py3-none-any.whl
| Download URL | deltatiming-0.1.3-py3-none-any.whl |
|---|---|
| Size | 3.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
71bbaf276520f03374ea6fe1459c65ad5c7eb3680542fe0c5a9c9fbfcc43cccd
|
|
BLAKE2b-256 checksum How to use checksums |
3fb128f55c421947df98d4c4af0fac6294db2c955123256b90b81f9bc22fbb78
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.1
|