The online racing simulator
I found the bug.
It return wrong pit work.

LFS_External.InSim.Flags.PitWorkFlags
PSE_RI_RE_DAM = 4094,

maybe fixed :
PSE_RI_RE_DAM = 4096,

sorry, my bad english
Quote from T-RonX :I'm working on version 1.3 which is based on version 1.2 (which i never released because of a bug i couldn't fix) and rewrote the core of it.

Obviously it will be Z25 compatible and will have some very nice features like requesting a packet directly instead of calling an event. All flags will be pre-parsed, and finally it will have UTF-8 support.

Excuse the bump but I was wondering if you managed to update for z25, z28 etc ??
Im using this in VS2008 and doesnt have the updated OutGuage bits...

Could you update and release the 1.3 version, or maybe release the source

Cheers
-David
Can you please update this? Would only take 2 minutes

Do I have to decompile and edit it myself?? Seems no-one cares about this anymore
Quote from DavidTiger :Can you please update this? Would only take 2 minutes

Do I have to decompile and edit it myself?? Seems no-one cares about this anymore

Would be nice to have an update indeed

OutSim only updates when I'm in certain "views" (cockpit view for instance, but no follow view). Is that an issue related to the lack of update too?
Quote from Shagrathx :OutSim only updates when I'm in certain "views" (cockpit view for instance, but no follow view). Is that an issue related to the lack of update too?

No that's a part of the OutSim protocol by design.

Quote from InSim.txt :// OutSim - MOTION SIMULATOR SUPPORT
// ======

// The user's car in multiplayer or the viewed car in single player or
// single player replay can output information to a motion system while
// viewed from an internal view.

Quote from DarkTimes :No that's a part of the OutSim protocol by design.

Oh I see, thanks for the explaining

Got a new question tho; does anyone have a VB.NET kit that works with VS.Net 2008?
As the latest version available (OP) needs conversion when I open it, resulting in a billion errors, as usual.

Please pretty please? anyone?
I find that the Visual Studio conversion process works pretty well actually. What errors are you getting when you try to convert it? In my experience once you've converted a project, you then need to build it before the errors and warnings will go away. Many of the errors you see are just a result of Visual Studio looking for .NET references and assemblies which haven't been built yet.
Quote from DarkTimes :I find that the Visual Studio conversion process works pretty well actually. What errors are you getting when you try to convert it? In my experience once you've converted a project, you then need to build it before the errors and warnings will go away. Many of the errors you see are just a result of Visual Studio looking for .NET references and assemblies which haven't been built yet.

Here's a screenie of what I get. Seems like it fails to find all references.. ?
I thought this would be a good practice for my rusty VB.NET skills, but you wouldn't believe the hours I've spent on this forum trying to find ANY insim/outsim tutorials, SDK Libs, examples... that is at least a bit up to date, or even just works at all

I don't have the time to work out everything from scratch... and there are plenty of out-dated tools, examples, tutorials etc. etc. so there must be something that still works? Right? Am I really missing something obvious? (wouldn't be the first time ^^)
If there's any useful VB.NET stuff for InSim (or C#, PHP, hell even C++ if I have to), I beg you to put an end to my suffering.
Attached images
flawless_conversion.jpg
OK - the first error listed there says:

- Could not locate the assembly 'LFS_External'. Check to make sure this assembly exists on disk

So... the problem is that the compiler is being told to use the LFS_External library, but it doesn't know where to find it. A reference to that library has not been added to the project yet. All of the other errors on that screenshot are just a result of it not being able to find that one library. It actually warns you those errors might happen!

- You may get compilation errors

Now, I don't know VB.NET at all, but you should be able to right-click on the project in the solution explorer and select 'add reference'. On the references dialog, select the 'browse' tab and then find the LFS_External.dll which should have been included in the zip file you downloaded from this thread.

I believe that once the reference to the library has been added, you should be able to build the project without any problems.
Quote from DarkTimes :OK - the first error listed there says:

- Could not locate the assembly 'LFS_External'. Check to make sure this assembly exists on disk

So... the problem is that the compiler is being told to use the LFS_External library, but it doesn't know where to find it. A reference to that library has not been added to the project yet. All of the other errors on that screenshot are just a result of it not being able to find that one library. It actually warns you those errors might happen!

- You may get compilation errors

Now, I don't know VB.NET at all, but you should be able to right-click on the project in the solution explorer and select 'add reference'. On the references dialog, select the 'browse' tab and then find the LFS_External.dll which should have been included in the zip file you downloaded from this thread.

I believe that once the reference to the library has been added, you should be able to build the project without any problems.

It was a bit more complicated than that, but I got it working just now.
I'm now testing it on my server and I succesfully made a form with a button that can be clicked.
Mentioned button then throws a simple messagebox with a snapshot of some basic info about Players.ToArray(0) like used car etc etc.

Would there be any documentation/tutorials available for this VB.NET SDK lib?
As it is totally awesome, even after just 2 minutes experience with it, but it's a challenge to find out everything on my own.
Right now I'm trying to create a button or something in LFS (through the external app... or... well...)

My goal is to make an InSim app for my server, a bit like the cruise systems that we all know (no physical access to the machine tho).
Is this possible with this?

Yes, I'm a total n00b
Quote from Shagrathx :It was a bit more complicated than that, but I got it working just now.

You might want to enumerate on how you got it working, as it's likely other people will have the same problem in the future.
Feature request
Hi!

This lib is very useful. Thank you for your work.
Here is a feature request:
it would be nice if the PType would be a FlagsAttribute field in the IS_NPL packet struct.

Cheers, pezia.
#413 - Jsm
I was just wondering, does this still work (I assume it does)? Mainly the OutGauge stuff, as I don't seem to get any sort of OutGauge packet at all and I'm not sure if I am just setting it up wrong or if it doesn't work. I tried both setting it in the cfg file and connecting via InSim and attempting to start OutGauge (It said "OutGauge Enabled" in game, but still nothing was received)

Thanks in advanced.

Edit: Nevermind it seems to work, I changed the ID from 0 to 1 and it suddenly started to work. Did I fail to read some instructions somewhere?
Is this updated for the updated OutGuage struct?
I have a great idea for a program im working on but Im halted by not having the correct structs through LFS_External

If not please update it
I was looking at the documentation in OutGauge but couldn't find in what Speed is displayed. Its certainly not MPh or KMh

Thanks.
InSim.txt says M/S (meter per second).
Quote from yankman :InSim.txt says M/S (meter per second).

Thank you! Didn't think of reading the Insim.txt
Quote from DavidTiger :Is this updated for the updated OutGuage struct?
I have a great idea for a program im working on but Im halted by not having the correct structs through LFS_External

If not please update it

It's fairly easy to roll your own OutGauge code. All you need to do is create a UDP socket, bind it to the correct port, and then unpack each packet that is received. UDP is a very simple protocol to work with, and not much code is required.
I had tried before but always came back to this error:

"only one usage of each socket address protocol network address port is normally permitted"

Meaning that it cant use the port becuase its used (by LFS)
I'm not sure what the error is, but that message suggests you are either trying to use a port which is already in use or one that hasn't been correctly shutdown. With UDP it shouldn't matter that LFS is using that port, in fact that's the whole idea! LFS is broadcasting packets on that UDP port, which you're trying to listen out for. Check that you app is the only program listening on that port and you are not trying to reuse a port used by LFS_External or anything else. Also make sure you are using the same port number you have specified in CFG.txt or in the ISI packet.
Hello, can someone see whats wrong with this bit of code?
Im trying to make a drift insim, all thats left is to finish the point system.
The problem is that its calculating wrong, it does not stop to count points when it should.

Fart=Speed
Vinkel=Angel

if(Fart>30&&Vinkel>10)
{ Connections[GetConnIdx(Players[GetPlyIdx(MCI.Info[i].PLID)].UniqueID)].NewScore = Convert.ToInt32(0 + (Vinkel * Fart) / 50);
}
Connections[GetConnIdx(Players[GetPlyIdx(MCI.Info[i].PLID)].UniqueID)].TotalScore =0 + (Connections[GetConnIdx(Players[GetPlyIdx(MCI.Info[i].PLID)].UniqueID)].TotalScore + Connections[GetConnIdx(Players[GetPlyIdx(MCI.Info[i].PLID)].UniqueID)].NewScore);
if(Fart<30&&Vinkel<10)
{
Connections[GetConnIdx(Players[GetPlyIdx(MCI.Info[i].PLID)].UniqueID)].TotalScore = 0;
}

I think the problem is in the TotalScore, but i cant find out what it is..
hope some of you could help me on this

Edit: i found out what it was, it was the NewScore that did not return to 0, it was stuck at the last value.
Can someone give an example of Outgauge in C++? Something similar to the C# example but in C++.
Hello,
External LFS I'm trying, but all data are updated very slowly, such as RPM does not go through all the numbers pasted on 1000 1000 jumps around, what can be done to that data is updated more frequently and has no such as sudden changes?

A greeting and thank you very much for your work T-RonX.

FGED GREDG RDFGDR GSFDG