mirror of
https://github.com/flame-engine/flame.git
synced 2025-11-13 19:30:14 +08:00
Standardize on dt in update methods (#679)
* Standardize on dt in update methods * Update changelog entry * Update CHANGELOG.md Co-authored-by: Jochum van der Ploeg <jochum@vdploeg.net> Co-authored-by: Jochum van der Ploeg <jochum@vdploeg.net>
This commit is contained in:
@@ -37,9 +37,9 @@ class Square extends PositionComponent with HasGameRef<MyGame> {
|
||||
}
|
||||
|
||||
@override
|
||||
void update(double t) {
|
||||
super.update(t);
|
||||
angle += SPEED * t;
|
||||
void update(double dt) {
|
||||
super.update(dt);
|
||||
angle += SPEED * dt;
|
||||
angle %= 2 * math.pi;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user