Skip to content
This repository has been archived by the owner on Oct 12, 2023. It is now read-only.

Improve sentence: We’ve also added if GameRunning then condition... #17

Open
michaliskambi opened this issue Mar 22, 2021 · 0 comments

Comments

@michaliskambi
Copy link
Collaborator

This was spotted by @and3md . I'm submitting an issue before I forget :)

The sentence:

""""
We’ve also added if GameRunning then condition to avoid possible rare bug in case two popups will fire simultaneously.
""""

seems too alarming. It may suggest that there's a mysterious bug in game code/engine code. Especially if reading this sentence "on its own", without previously reading explanation about what GameRunning does ("... The game starts running and stops after "Game Over" "). What "possible rare bug" do they mean?

As far as I understand, the point is just that you detect "game over" in each Update, and the point is illustrated by the code snippet right above the sentence with

if GameRunning then
  TUiState.Push(StateGameOver);
GameRunning := false;

I propose to change the sentence to:

"""
We’ve also added if GameRunning then condition to avoid showing the "game over" popup repeatedly in each Update after the game ended. The line TUiState.Push(StateGameOver) should execute only once per game, not in every Update call.
"""

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant