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

Likely flaw in the entity kill flow #14

Open
awilsoncs opened this issue Nov 10, 2022 · 0 comments
Open

Likely flaw in the entity kill flow #14

awilsoncs opened this issue Nov 10, 2022 · 0 comments
Labels
server-side This issue applies the server side. tech debt Code improvements not including features or perf

Comments

@awilsoncs
Copy link
Owner

I haven't found a way to produce an issue related to this flaw, but it follows from the analysis.

When an entity is killed, it should not be properly deleted until the end of the game update. This is to prevent the entities collection from being changed during iteration.

However, the game logic isn't aware that an entity has died or been disabled in some way. This can lead to a situation where the killed entity affects the game state after its death:

Entity A kills Entity B
Entity B (not properly removed) attacks Entity A during its turn

This should not be possible given a correct flow.

@awilsoncs awilsoncs added the tech debt Code improvements not including features or perf label Nov 10, 2022
@awilsoncs awilsoncs added this to the Unscheduled Tech Debt milestone Nov 11, 2022
@awilsoncs awilsoncs added the server-side This issue applies the server side. label Nov 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
server-side This issue applies the server side. tech debt Code improvements not including features or perf
Projects
None yet
Development

No branches or pull requests

1 participant