Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Start games without loading screen if assets are ready before half the fade-in #6025

Merged
merged 5 commits into from
Dec 7, 2023

Conversation

D8H
Copy link
Collaborator

@D8H D8H commented Dec 6, 2023

No description provided.

@D8H D8H requested a review from 4ian as a code owner December 6, 2023 19:51
this.setPercent(100);

const fadeInDuration = Math.min(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm really struggling to understand this logic, had to read it multiple times.
Could we split each side of the Math.min into named variables like fadeInDurationIfShowingGDevelopSplash and fadeInDurationIfUsingBackgroundColor ?

Also, I don't understand the Positive_infinity. Will this make a fade_in infinite if no splash or background color?

if (
remainingTime <= 0 ||
!this._isFirstLayout ||
(this._isWatermarkEnabled && totalElapsedTime < fadeInDuration / 2)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a comment explaining what we do here

Copy link
Collaborator

@ClementPasteau ClementPasteau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@D8H D8H merged commit be813a0 into master Dec 7, 2023
6 checks passed
@D8H D8H deleted the fast-reload branch December 7, 2023 14:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants