The online racing simulator
Quote from dougie-lampkin :Correct me if I'm wrong, but is there no packet handler thingy for IS_REPLY? I've enabled it's event by uncommenting it, but I can't for the life of me work out how to set up the method

IIRC, you need to receive IS_TINY, then you can check its subtype. I beleive its "SubT", but anyway, Im sure that works.
Then what's the point in having an event handler for IS_REPLY, if it comes in with IS_TINY?

It does come in with IS_TINY though, thanks
Attached images
IS.REPLY.jpg
Updated LFS External to version 1.1

Updates:
- Faster and more reliable connection to host
- Auto reconnect on connection failure
- Better error handling
- Example code for C# and VB.Net
- Used more descriptive method names
- Now supports multiple instances of InSimInterface
- Added documentation
- Lot of small things

This version is NOT compatible with any previous version of LFS External. This means you cannot upgrade by just replacing the dll file. You have to copy/paste the code from the old version to the new one.

You should really consider updating especially because the connection is much more stable and it has much better error handling.
Just wanted to spam a little and thank you for your work on LFS External T-RonX :up: You're one of many doing some very good work for the community!
Just converted some of my projects into the new version, I have to say it's incredibly tidy, everything is already set up, all I had to do was Copy + Paste

Gratz on the good job, it's very much appreciated by me, I use it for all my LFS projects
Updated LFS External to version 1.1.1

Updates
- Added support for OutSim and OutGauge

This update us fully compatible with version 1.1.0, you can replace the dll. I just added 2 new namespaces. LFS_External.OutSim and LFS_External.OutGauge.
I added a examples for C# and VB.NET too.

Hope you like it,
Ron
Good job T-RonX.

I have a problem, the problem is how to make a configuration file (Setup.txt for example) and the program read it, for the connection options.

Thanks
Obviously that is not a part of LFS External. You should google something like this.
Quote from T-RonX :Obviously that is not a part of LFS External. You should google something like this.

Ok, Thank you T-RonX. I have succeeded
why not put the configuration settings on the form1? like admin pass, ip address and port number?
Quote from vane :why not put the configuration settings on the form1? like admin pass, ip address and port number?

Because then if someone wants to edit a simple configuration setting, they will need to download and recompile the source. That's probably OK if you're a programmer who has the IDE and knows the language, but if you are giving you program away to, you know, normal people, then that would be insane. Would so many people use LFSLapper if they needed to recompile the source every time they wanted to change the admin password? No, they wouldn't. In my opinion it's a very good idea to put configuration settings in a separate file that's easy to edit. Or even better if your program is graphically based, write a special options dialogbox.
Quote from DarkTimes :Or even better if your program is graphically based, write a special options dialogbox.

I think that's what he meant

I prefer using the separate config file though, as the user doesn't have to re-adjust it every time
Quote from dougie-lampkin :I think that's what he meant

OK - I apologise, I misunderstood. I though he meant to hardcore them into the main form. Sorry.
Is there a bug with the SPX PLID? When I use:

Connections[GetConnIdx(Players[GetPlyIdx(SPX.PLID)].UniqueID)].Username

I get an IndexOutOfRange Exception...

Has anybody else come across this?
Quote from dougie-lampkin :Is there a bug with the SPX PLID? When I use:

Connections[GetConnIdx(Players[GetPlyIdx(SPX.PLID)].UniqueID)].Username

I get an IndexOutOfRange Exception...

Has anybody else come across this?

Alot of times... I had the problem every time i started my insim on a full server, some NCN packages got dropped.. so these players where in the Players list but not in the Connections list.. Fixed it with some threads on the NCN handler (to reduce the execution time)

Greetz Glenn
Glenn, Have you tried doing as i said here, Im sure its fixed in 1.1.0> but if your still using 1.0.4 then it isnt.

E: Making a new thread just to handle NCN isnt a good idea really, Use the backgroundWorker or the threadpool. Thats if you MUST use a thread, which IMO isnt needed.
This is using 1.1.0, and the SPX packet is the first time I've come across this. It happens no matter how many people are in the server...
when i opened the source for 1.1 up i got very confused it looks so different from the old one
how do you open the example outgauge thing? i am having trouble :s it says incorrect bind handle
Have you tried a different port yet?
-
(DarkTimes) DELETED by DarkTimes
oh it was just that i was trying to debug it but you cant is there any way you can speed up the packet transfer? so there is less lag between the stuff showing on the form and lfs?
change 'OutGauge Delay' to 1 in the lfs config.
i have tried that but it does not seem to make it any different, do you have to modify anything in the app?
Nope. But make sure you closed lfs before editing the config, else lfs will overwrite it with the old settings.

FGED GREDG RDFGDR GSFDG