altmp / altv-issues

Issues and roadmap for alt:V project
93 stars 16 forks source link

beforeConnect - To Prevent Limbo Connections #967

Closed Stuyk closed 3 years ago

Stuyk commented 3 years ago

Suggestion An event like beforeConnect that has a list of ip, hwid, etc. of the incoming connection and you can return false to prevent the connection and that will allow them to continue browsing servers.

Use cases

Describe the solution you'd like An event like beforeConnect that has a list of ip, hwid, etc. of the incoming connection and you can return false to prevent the connection and that will allow them to continue browsing servers.

Describe alternatives you've considered Kicking through the playerConnect event if a boolean is true. If the client is not in debug mode they get stuck in the limbo between not being able to reconnect and not being able to rejoin without restarting their client. It's not a good solution and it needs to be something with better control.

Stuyk commented 3 years ago

This was discussed in an internal development channel.

zziger commented 3 years ago

Would be also nice if there would be any possibility to provide custom "disconnect" message to the user

mrgharabaghi commented 3 years ago

Player.socialID could be one of the main elements that beforeConnect event can returns.

FabianTerhorst commented 3 years ago

Added in next release.

FabianTerhorst commented 3 years ago

But the user can only go back to main menu when the server isn't using early auth.

ThePawlow commented 3 years ago

Wuhuuu