Wulf2k / DaS-PC-MPChan

77 stars 30 forks source link

[Suggestion] Client Can Disconnect Specific Node #12

Closed CatboyPrincess closed 8 years ago

CatboyPrincess commented 8 years ago

Presently, DSCM allows the user to double-left-click a player in the Favourites or Recent (or DSCMNet as well? haven't tried or verified) to quickly attempt a connection and it works.

Now, I suggest that there be some other similar mouse-input (e.g. right-cilck for context menu that contains "Disconnect From This Node") whose function is to disconnect the DkS client from a specific node.

Having done a rough search of the source for the token "disconnect," I don't see anything like a function prototype or anything.

This feature/function prototype would be useful for:

Notes:


EDIT:

BTW I'm VERY excited about my first Github pull request. I really hope for the best and that my offering is somehow, in some form, accepted and merged with the master.

Praise the (Dark) Sun

Wulf2k commented 8 years ago

I have the disconnect ability in a private build, but won't be rolling it into the main build until the end, if ever.

Too controversial of a feature, so I'll wait until everything else is taken care of to consider the best way, if any, to implement it.

I'm going to look over your contribution now. If it all checks out, I'll be accepting it as-is and then immediately overwriting the minimum value again and submitting that. Being online with 0 max nodes has too much potential to cause problems for others trying to connect to you.

chronial showed a way to accept a partial submission, but the family's taking too much attention right now to go over it.

Chronial commented 8 years ago

Nice to hear :). While I totally agree that giving the player the option to manually remove is quite controversial, this has other more obviously beneficial applications.

We could for example remove "stale" nodes: Nodes that are not favorites, far away in the world and outside of our SL Range. This way we can clear up slots for more useful nodes, of which I think there will be a big selection, once the IRC feature is more mature.

CatboyPrincess commented 8 years ago

Sounds good, and thanks for accepting my contriubution!

It would be less likely to be abused if such a forced disconnect was only available, or only occurred, if DSPW detects a cheater and the player subsequently decides to ban the offender. In this case of the player deciding to press F1 to forcibly disconnect using DSPW, it could be used as a sign that it is safe for DSCM then to force a node disconnect.

CatboyPrincess commented 8 years ago

I'd like to bring up this issue again, but suggest that only the back-end code be implemented for disconnecting from a node (or all nodes), or that the front-end is accessible only in a Debug build, and that the Release build be provided to the public (or, that on release, the front-end for flushing nodes is disabled in some way, commenting, boolean flag, etc.). I'd like to be able to flush out all the nodes and restart collecting nodes so that I don't have to restart DkS constantly to achieve that effect. It would make testing filters and such a lot easier, to be able just to click a button and remove all nodes and start from 0 nodes.


EDIT: I'm also interested in working on that would replace stale nodes. Naturally, people come and go and eventually, there is no choice but to restart DkS because so many nodes are simply not where the player is. Additionally, the player jumping several levels at a time also skews things a fair bit.

Chronial commented 8 years ago

@Wulf2k Everything we want to implement about this is done, right? Can this be closed?

@hydra-chan sorry – I completely forgot about your interest in working on this and just implemented it myself :/. But please have a look at the current implementation and see if you find room for improvement – the algorithm is just what came to my head when I was coding, I'm sure it could be improved.

Wulf2k commented 8 years ago

I believe so.