The online racing simulator
Player / Team name control
Ok, so here's my question ...

Would it be possible to make an app capable of doing actions depending on players names?

My idea would be the following ... if player connects, and his/her display name has, say, the letters SPTR within it, the app checks a list of team members, if the name is a valid members name, the app does nothing, if the name is not a valid member, the app displays a message explaining that you need to be authorised to use the team name, and asks you politely to change your display name. The app then checks again, say, 1 minute later, and if the name is still present, the player gets kicked. It would be good if the app could check multiple servers, one after the other, say, every 1 minute. By display name, I literally mean display name, not the s2 username, as I'd like it to work in demo, s1 and s2.

I know it's not a bullet proof solution, but we often get people on our servers using our team name when they're not supposed to, thinking they can become members by just using the name, this would help guide them when an admin is not online, and also people pretending to be admins, like today we had a guy calling himself SPTR Stevo, bossing people around claiming to be an admin and generally being a pain in the arse for everybody, and giving our real [SPTR] Stevo! a bad reputation with our players. It's a real pain in the ass trying to monitor this, so the app I had in mind would at least prevent the real noobs from being on the servers for long ...

It sounds like a simple idea to me, and it might or might not be, certainly I'd be able to make such functions in php, but I have no idea how that would interface with LFS. I know bugger all about proper programming, and I don't want to spend years learning how to. If somebody could make such an app for me, I would be eternally grateful, and if there was anything I could do in return, I would, that is, of course, if it is possible to make such an app ...

Sorry for the long post ...
Ok, First off i love the idea! But i can see some issues with it! Such as would it limit just one team tag? And would there have to be a "database" to hold all names to check from? Aswell as would it bann or kick, Becuase you dont want them too come back , but you want them to change name and aloud to come back! But thats just a few things! Love the things it can do! ...And the one tag thing, i mean ONLY sptr or does it heve all tags used by all teams it might be a bit large!
Having a multi team databse, whilst it might sound good, would be too cumbersome, and would only lead to problems with people complaining about you bossing other teams around on your servers. I'm only interested in my own team, on my own servers, in that respect.

As for the name tags and members names, simply stock them in a .txt / .cfg file or something.

For example ...

/tag=SPTR

/members=[SPTR] Dan!, [SPTR] Stevo!, etc.

That way anybody could use it on their server for their team.
You don't need to complicate life, keep it simple and functional.
OK , we agree that the multi tag is out..Hehe ok now how would you get it to recognize the tag?? (idk) but id think that tag/....w.e... / Might confuss the computer when a member often uses diff tags and names when they fool around or what not! Would it kick an admin for swithing his tag? aswell how would it identify a tag by itsself and not the wholemember name!?
It's simply a string of characters to search in the players name.

Members list :

[SPTR] Dan!
[SPTR] Stevo!

String to look for :

SPTR (for example)

Result when players are checked :

Greg = does not have SPTR string, so ok, do nothing
SPTR Greg = has SPTR sting, doesn't match member list, so notice, then kick
[SPTR] Greg! = has SPTR sting, doesn't match member list, so notice, then kick
[SPTR] Dan! = has SPTR sting, matches member list, so ok, do nothing

If the app checks all the players every minute :

If I change my name in game from [SPTR] Dan! to Silly, no SPTR, so fine.
If I change my name in game from Silly to [SPTR] Dan!, in member list, so fine.
If I change my name in game from Silly to [SPTR] Greg!, fail, so notice then kick.

The longest you can stay on the server using the team tag is 2 minutes.
And you'll get the notice within the first minute ...

So anybody pretending to be an admin, will get called out eventually ...
It's more of an aid than a prevention system, as I said ...
Ahh ok that made it more clear. Thank you!
Well, that's the idea anyway ... now all it needs is for somebody to make it actually work ...
It can be a General app so all teams and servers can use it so i bet someone is willing to make it, Good luck!
Would it not be better to check for the tag string, and then check against a list of usernames? So that if your members mess around with their names, they can have any name? Either way its very do-able. I could make one, but it wouldn't be able to connect to multiple servers, it would stay connected to one. Do your servers have any insim apps running at the moment?
Well if you could set the string to check as a variable, you could set it to check either the sheer text or the full tag, depending on personal preference. But checking the full tag would then miss people like I said above, using SPTR and not [SPTR]. Whilst that is obviously a failed attempt from out side, other players might not know the difference and still be fooled. Also, in SPTR, once you've chosen your name tag, you stick with it. But as I said, if it was variable, you could set it to check as you wish. As for insim connections, my servers are running LFSLapper, that's all. It's not a huge deal for the app to be able to check multiple servers, as long as I can run a copy of the app for each server.
If I was doing it, it would be through insim. I don't think it would work alongside lapper...someone more talented then me could maybe check that?
Quote from dougie-lampkin :If I was doing it, it would be through insim. I don't think it would work alongside lapper...someone more talented then me could maybe check that?

I believe up to 8 independent insim clients can be attached to a host, so I see no problem with this. And the required application is very simple to do too.
Ah well that's good

I was thinking...if all of the servers are run off one IP, how can you tell insim which one to connect to? I've only ever used 127.0.0.1 to connect to a single server...
What about teams that use more than one tag for their team? Also are enough people pretending to be in [SPTR] to need this?
Why in the world would you use more then one tag?????
Quote from dougie-lampkin :Ah well that's good

I was thinking...if all of the servers are run off one IP, how can you tell insim which one to connect to? I've only ever used 127.0.0.1 to connect to a single server...

Every server has a unique IP address, as does every computer which connects to the internet. The IP address 127.0.0.1 is a special 'loopback' address, which means your program is connecting to another program which is on the same machine. Connecting to 127.0.0.1, also known as 'localhost', means that you are connecting to your own computer... If you want to connect to a remote computer, you will need to know its unique IP. LFS can distinguish between different InSim programs at the same address because they each connect on different ports.
Quote from dougie-lampkin :how can you tell insim which one to connect to?

Quote from DarkTimes :they each connect on different ports.

Yup, it's fairly simple really, as an example ...

127.0.0.1:29901
127.0.0.1:29902
127.0.0.1:29903

... and so on. 127.0.0.1 being the local computer, and 299** being each LFS servers unique insim port number.

Quote from greg_slideways :Why in the world would you use more then one tag?????

I agree, how can one team use more than one tag?
If you're using more than one tag, you're not the same team, surely?

Quote from flymike91 :are enough people pretending to be in [SPTR] to need this?

I'd say on average we catch about 6 or 7 a week at it, mostly harmless people who just want to join us and don't know how to, or who simply don't realise that they have to tryout, and about 1 a week who really is a totally malicious idiot. That's the people we catch doing it, who knows when we're not there.

I'm requesting this app because I feel it would be very usefull for me, and may help one or two other people with similar problems. The app will guide the people who wish to join us by displaying a notice informing them of how to do so, as we are not on the servers 24/7 (yes, we all have jobs/school etc.), this is a great way to help people who are genuinely interested in the team, but never cross a real member, and to help prevent fakers. It also saves displaying huge amounts of text and rules when players connect to the server.
Yes i hate large amount of text when opening server! And surely I want to ask will you implement it on every server you run! That will be alot of copys of the app?
How the app is run depends on how the app is coded, if it's multi server or not.
Whichever way, it's not a problem, it's not like I'm lacking in server power ...
And yes, it will be run on all of the Silly Project LFS servers ...
LFS Lapper (in its first instance) used to include a feature were you can tell it to recognise different players. It now uses licence names I believe. Ive not used lapper for a very long time, so I cannot be sure, but I remember some used to use it to give team members.. functions within servers etc..

Might be useful information to read/download lfs lapper..
Thanks for the IP info, I've only ever ran insim apps from my pc, where the host was running aswell...I shall look into coding an app like this tomorrow (which is technically today I suppose ) and report back...
Quote from mkinnov8 :Might be useful information to read/download lfs lapper..

I need it to work in demo, s1 and s2, so something that uses players licence names is useless (for demo servers anyway, and demo is where the main problem is). My servers already run LFSLapper anyway, and I've seen no way of making LFSLapper doing what I described further up, unless I'm totally missing something ...

Quote from dougie-lampkin :I shall look into coding an app like this tomorrow (which is technically today I suppose ) and report back...

Thanks dougie, much appreciated!
OK, at the moment I have it done (keep in mind it's only alpha testing) so that when an admin types !add NAME, a new file is created with that name. If someone connects with the string SPTR in their name, it searches for a file named after their name. If its found, it does nothing, if its not found, it tells them to change it.

I haven't done timers or anything yet, but at least the basic idea works...

Also, when a dedi host is running off a remote server, what path is it in? I don't need to know for this program, but are all the dedis running off the one path (eg. C:\dedi or C:\ or whatever drive letter...) ? I've often wondered this...

EDIT: I've just thought of a problem...A player can still connect to the server with the name of one of your players (eg. a valid [SPTR] name) and it will appear as though they are a proper member...perhaps the file should contain the username of the SPTR member?
Quote from dougie-lampkin :
EDIT: I've just thought of a problem...A player can still connect to the server with the name of one of your players (eg. a valid [SPTR] name) and it will appear as though they are a proper member...perhaps the file should contain the username of the SPTR member?

Why not store playernames in the txt file and make a password box come up with LFS buttons, the pass is correct, tag is ok, pass is bad, kick...
What I have is that when an admin types "!add NAME", a new file is made, which is named the NAME typed in the command...that's harder to explain than I thought... When someone connects with SPTR in their name, the program searches for a file called their name...if you follow me...if its there, it does nothing, the tag is allowed, if its not there, it tells them to change it...

I was then going to have it so that the only line of text in the player's file is their username, so that they can be checked...and if it's not the same username.../ban time
1

FGED GREDG RDFGDR GSFDG