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

Movement speed client hacking #59

Open
gnibeda opened this issue Mar 25, 2022 · 1 comment
Open

Movement speed client hacking #59

gnibeda opened this issue Mar 25, 2022 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@gnibeda
Copy link

gnibeda commented Mar 25, 2022

Due to how movement implemented on client and server, there is possibility to hack movement speed by sending additional messages to the server. You can change client code adding loop to increase movement speed 20x times:

        // Send the action to the server
        for (let i = 0; i < 20; i++) {
          this.onActionSend(action);

          // Save the action for reconciliation        
          this.moveActions.push(action);
        }

Code can be simply moddified in chrome browser during runtime in devtools.

@halftheopposite
Copy link
Owner

Hi @gnibeda, thanks for pointing this out!

This is indeed a problem with the current architecture. A way to solve it would be to force a maximum number of movement actions per second or a minimum delay between actions and drop out the others. Since we are doing client-side prediction, we would also need to make sure they are dropped/ignored on the client as well.

I'll keep this issue open as a next to do.

@halftheopposite halftheopposite self-assigned this Apr 2, 2022
@halftheopposite halftheopposite added the bug Something isn't working label Apr 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants