The online racing simulator
Automatic Licence Check
(16 posts, started )
Automatic Licence Check
Hey,
Im creating a program in VB2008 (.NET) and using LFS_External.dll to allow me to implement a license check, I have it working perfect but, I have to manually type /insim 29999 ingame...

Is there a way to automatically connect? A default port or...

Cheers,
David
InSim isn't enabled by default - the only way that it starts is if you start LFS with /insim portnumber argument, or if the user manually starts InSim (/insim portnumber in chat).
Ahh, oh well.

Thanks
put the /insim command in your server's .cfg file.

you might be able to do the same on the client-side, never tried.
I got around this by launching LFS with commandline from the program.

Thanks!
-Tiger
You can also add the line
/insim 29999
to lfs/data/script/autoexec.lfs I believe

(or maybe not - I dunno if scripting works in the demo)

edit: this will only work on the client though.
#7 - Silox
Quote from bunder9999 :put the /insim command in your server's .cfg file.

you might be able to do the same on the client-side, never tried.

^ Best & easiest solution.
Sorry for the bump, but I'm looking for license check code for C#, preferably without insim. I'm already using MemEditClass, so if that's an option, I'm all for it.

Thanks
Did you ever get code for this? I'm pondering playing about with some coding myself...
You'll have to query LFSWorld Stats... but thats as much as I can say, I think (Verbal NDA:shrug
Quote from DavidTiger :You'll have to query LFSWorld Stats... but thats as much as I can say, I think (Verbal NDA:shrug

Oh boy, I had been imagining that there would be a better way? (Sounds like you mean a check for any recorded races on non-demo combos...)

Thanks though
There are better ways but one problem is that they are never secure, at least to a semi-experienced user...

You could use InSim or as I said to query lfsworld..

I'm posting from my pda just now. So if you want some example code I can post some tomorrow (if no one had already done so)
Ahh, thanks.

I haven't attempted any tweaks yet, so perhaps I'm just totally missing the point. But in my head, the problem is immediately "fixable" with a modicum of help from the devs... in that the game already has what I imagine must qualify as a secure licence check before you can use e.g. an FZR. Why can't the game provide an in-built check before allowing other user-tweaked stuff?

Like I say, the fact that I'm thinking this is probably an indication that I've missed the point entirely. So if there are any docs about this stuff (didn't spot any so far, maybe didn't look hard enough though) then I'd really appreciate a link
Yea, LFS (correct me if im wrong) would use a similar way of online checking from lfsworld that seems to be secure enough..
I only know two ways of checking the users licence, VIA InSim and it gives a packet containing the licence info (DEMO, S1,S2) which makes it extremely easy to use as a check
Plus the other way via LFSWorld, which I was told I would have to use if I were to release any sort of tweak that could give more, better content.. I would suggest to do it that way, or maybe even both? because its really simple to compare a Demo's stats to that of one S1, S2 stats..
But that may cause problems for a small % of licenced racers as there may well be some racers who had never used a certain car, track? Unlikley but very possible

InSim, More Info Here: Clicky Linky
Its open source so that makes it very unsecure to someone with little knowledge of programming Maybe other ways to use the insi method but thats what I used originally..

LFSWorld, More Info Here: Clicky Linky
More secure than InSim, Probably the recommended way by the Mods, as Bob Smith told me to use that way in my tweak app before I could release here

Hope Some of that helps
-David
Thanks for the links - had a look and saw that EQ Worry has been asking for licence-info from LFSW for some time with no joy

It's almost as if Victor and Bob aren't on the same page on this issue - it seems like it ought to be a no-brainer to allow LFSW (via pubstats) to supply the licence status of a username. Plus, Bob wants mods to use that route rather than Insim. And yet Victor has upgraded pubstats a number of times and NOT added the presumably trivial bit of code to do the licence reporting.
So I must infer I'm missing something about why

Ah well. It's all moot I guess until I've actually written a mod, eh?
I think the trouble with the InSim method, is that if someone ran the app off a cracked LFS, it would report it as being S2.

The LFSWorld method is the safest, but could probably be cheated again by using a proxy to spoof the response the app expects from LFSWorld. The chances of your average demo user (or even someone running a cracked LFS) being able to do this are fairly low though, I'd imagine. You could query for PBs or fuel usage for the user, and parse the car name from each line, and examine it to see if only the demo cars are listed. It's probably safe enough to assume that this user is a demo user then, but there will be false negatives until the license status is added to pubstat...

Automatic Licence Check
(16 posts, started )
FGED GREDG RDFGDR GSFDG