From my understanding, someone gets info about their ban length and reason once the ban is issued, so if the player is not online at that time, they will get the info the first time they try connecting again.
This is a system that should already be implemented and working.
What Flags did you set when Initializing insim, just ISF_LOCAL, or did you also set ISF_MSO_COLS?
Are you altering the NPL.PName or the MSO.Message at all before comparing them?
Are you using the InSimDotNet NuGet version or the last build from Github?
Maybe you can share some code if these hints don't help you in the right direction?
EDIT:
I've written a program that does lookup based on PName myself, this is what i do:
The class i store the user data in looks something like this:
class user{ public string Nickname {get;set;} public string CleanNickname => Clean(Nickname); //strips any escape characters left
private string Clean(string nickname) { Regex hashtag = new Regex(@"\^h"); //since the InSimDotNet NuGet version doesn't seem to catch this Regex cc = new Regex(@"\^\d"); //strip any color codes
And i guess your code for the message handling should look something like this.
private void OnMessage(InSim i, IS_MSO msg){ Regex moneySentQuery = new Regex(@"[/d/s/W]{1,3}has sent money to "); //should only hit on msgs with the matching string, any possible color codes are also handled string cleanMessage = msg.Msg.Substring(msg.TextStart); //we only want the text of the message
if(moneySentQuery.IsMatch(cleanMessage)){ //check if the MSO message has certain text string [] subStrings = moneySentQuery.Split(cleanMessage); //split message so we can extract users
//PlayerList is some List<user> you're maintaining somewhere in your program user FirstUser = PlayerList.SingleOrDefault(u=>u.CleanNickname == subStrings.First()); //should be Player A or null user SecondUser = PlayerList.SingleOrDefault(u=>u.CleanNickname == subStrings.Last()); //should be player B or null } }
It's pretty messy code, so I'm sure it has some false hits, or lack of hits, so it might need some altering to your specific use-case, but it should come close.
I hope this helps.
Last edited by kipieslim, .
Reason : added some example code
While trying 7E5, I've noticed that a mod that is out of limits is being reported in chat once, but subsequent pit leaves won't show the message again, I'm wondering if that's correct.
I've also noticed some mods that are published this week, that have both LOD2 and wheel warnings.
Is it possible to have a sound editor in the engine editor?
It's possible to load waves and eng files, but there's no way to test that sound without an export.
Would it be possible to add the shift+A settings, some sliders/buttons for throttle/rpm, engine load/clutch and maybe gear?