-
Notifications
You must be signed in to change notification settings - Fork 44
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
New changes #45
New changes #45
Conversation
Hi, @marceldev89. Can you pls take a look on this? |
Yep, I will take a look this weekend. :) |
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.
Like I said before, I can't really test this and it's been a long while since I've worked with C# so I'm not up to date and all that but it seems fine to me besides some API breaking changes. If they are reverted then I'll merge it in. :)
Also, I assume the Encoding 1252 nuget stuff is only required for the .NET Core side of things right?
BattleNET/BattlEyeCommand.cs
Outdated
@@ -105,7 +105,7 @@ public enum BattlEyeCommand | |||
/// loadEvents - (Re)load createvehicle.txt, remoteexec.txt and publicvariable.txt | |||
/// </summary> | |||
[Description("loadEvents")] | |||
loadEvents, | |||
LoadEvents, |
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.
Breaking API change
BattleNET/BattlEyeCommand.cs
Outdated
/// <summary> | ||
/// admins - Gets connected RCON clients. | ||
/// </summary> | ||
[Description("admins")] | ||
admins, | ||
Admins, |
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.
Breaking API change
About breaking change - .Net Standard 2 will not be compatible with .Net Framework less than .NET Framework 4.6.1 - this is very important to know. Also I had plans to add another very annoying breaking change - related to #34. Actually, this pull request and that commit - everything what I wanted to add - so if you want to have backward compatibility with old .NET FW and you dont want to fix typo in API - then no reason for me to create pull request at all. |
I have a different idea for the enum changes; instead of removing the lowercase entries, add the uppercase ones and mark the lowercased as obsolete with the ObsoleteAttribute. Then if there will ever be a 2.x version that justifies API changes they can be removed. I'm not too worried about the .NET Framework 4.6.1+ requirement, it's nearly 3 years old and anyone using the library that hasn't updated their tool in those 3 years will probably also not update the library. As for that commit related to #34, it's already part of this PR and I kinda missed that. I'm not sure what to do here, I do feel that the library should keep handling the recovery after a connection loss and not move that to the user. The stack overflow related to that must be fixed though. If you can remove this commit from the PR, at least for now, and if the above is fine with you then I'll do the merge. |
About enum - hmm, that make sense. I will do this. |
This reverts commit b2cc19e.
Take a look on this again pls. Seems I fixed all stuff which you asked. (added 2 new commits) |
Yep, nice. Thanks for the work, I'll take a look at the timer/recursion stuff at a later time. Maybe there are other solutions as well but I'll have to find some time and a server to test on. :) |
What was done:
regarding support. Keep in mind that according this
.NET Standard 2.0 is supported on the following platforms (source):
As result:
Need to keep in mind that for .NET Core 2 apps support for Encoding 1252 should be setted up manually (SO).
System.Text.Encoding.CodePages
needs to be installedEncoding.RegisterProvider(CodePagesEncodingProvider.Instance);