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

[newserv] [Feature Request] Setting to disallow login with the same account twice or more #511

Open
nolrinale opened this issue Jun 1, 2024 · 3 comments

Comments

@nolrinale
Copy link
Contributor

Currently is possible to login in the game twice with 2 clients, you can have the same copy of your current character playing with you in your party sharing/dropping items, I think this is a vector for very dangerous situations in-game including item duping, quest flag malfunction, cmode/bmode conflicts or player data corruption.

I would like to have a setting via config.json that disallows this behavior entirely because im not sure if its useful for older versions such as GC or DC

@fuzziqersoftware
Copy link
Owner

This is not actually dangerous; the server has only one copy of the player data in memory and it is shared between the two clients. This means that items cannot be duplicated, for example, since if both players attempt to drop the same item, the second one will already be missing the item when they try to drop it and will be disconnected instead. In the case of challenge/battle records, one of the clients will "win" and update the records in the player data, and the other update will simply be lost. Since records are always updated in their entirety, there's no way to get into an inconsistent state.

I will still fix this, since it leads to unexpected/unintuitive behaviors, but it's not a critical or dangerous issue.

@nolrinale
Copy link
Contributor Author

I must be very old school but what is the problem with showing a simple "This account/SNAK is already in use" error box?

I think is something that would benefit you as you wont have to manually keep track of every single client-server interaction no matter how small/big it is to avoid unintended effects in-game. Which in turn is less bugs for you to fix.

But you do you it's your project
Feel free to close this one as invalid if you wish

@fuzziqersoftware
Copy link
Owner

Please re-read my comment. I said I would fix it, and I will. It's not a high priority for me right now, but I will get to it at some point.

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

No branches or pull requests

2 participants