-
Notifications
You must be signed in to change notification settings - Fork 129
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
Add a PLAYER_LEFT event #288
Add a PLAYER_LEFT event #288
Conversation
In certain cases we do not much Unetclosed or it is missing from the log, however channel seams to always be called
Linking to player Left Event because this may fix the issue brought up there. |
PR needs testing to see if this is still valid. |
Have been using the regex change here for a long time on my squadjs and have had no issues. This is still valid. |
There are parts of the code that is not always the case:
I have sample lines here that says so:
|
well i can tell you right now i am using the the regex provided to track player times based on log events for the player join and leave and have had no issues with extraneous leave events or missed leave events. while those other lines do seem to happen they are not associated with a player disconnecting from the server and/or a proper disconnect log line happened for that player at another time during the log, in which case we don't want to catch those events anyways. I have been using this regex for 6 months now without issues. If you believe otherwise i would advise some testing and real-world scenarios/examples that these log lines come from along with checking for similar log lines from those same events that do match the regex change. |
This is not exact, Squad isn't the best game to have clear and meaningful logs, and this is a good example. However, some mods use custom PlayerControllers, a better regex to match those would be |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some mods use custom PlayerControllers, a better regex to match those would be [^ ]+PlayerController_C_[0-9]+
, tested with GC and MEE mod so far.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good to me, this extends support to custom player controllers used by mods, even if it's not possible to guarantee it will match ALL the mods on the workshop due to the nature of a custom controller, which may not follow this naming convention.
Approved as the changes have been tested on custom player controllers used by GC and MEE mods.
This works too, and it's cleaner, a different way to write the same thing. |
Are you able to test this change on Node 14 just to make sure? I'll do it tomorrow if you can't do it |
In certain cases we do not match on Unetclosed or it is missing from the log, however channel seams to always be called