Jump to content
The simFlight Network Forums

FSUIPC DLL program to remove unwanted AI (help with a few bits pls!)


Recommended Posts

Hi everyone

I am new here so sorry if this is in the wrong place. I am using C#

I am in the middle of creating a program which will remove 'unwanted' AI traffic ('unwanted' being traffic for example that loads at EGLL when I am flying LEBL-EGKK - the traffic loads even though I do not see it when at EGKK, slowing down my sim).

I have successfully written a C# program to use FSUIPC to load all AI aircraft and remove them (I'll sort out what I do and don't need removing later on).

 

However, my problem is that when I run my program, it works great at removing everything around me but after a certain distance around me the AI Traffic is not removed. I can slew up at EGKK a few thousand feet and see EGLL, I run my program but the EGLL traffic still stays put.

My initial thought is does FSUIPC have a radius limit or something which it loads AI Traffic? The aircraft have obviously loaded in the sim as I can see them from EGKK, but FSUIPC doesn't seem to see them.

 

Any help would be greatly appreciated. When finished I'll upload my program somewhere for those who wish to use it.

 

Many thanks

Callum

Edited by Callum
Link to post
Share on other sites
2 hours ago, Callum said:

My initial thought is does FSUIPC have a radius limit or something which it loads AI Traffic?

Using the FSUIPC TCAS tables (which are designed really purely for TCAS display use, the range limit applying to airborne traffic is 40nm by default, but can be set in the options or via the INI file parameter. The ground traffic range when the user aircraft is airborne is 6nm, but only 3nm when the user aircraft is also on the ground.

Normally ground traffic is not a feature of TCAS.

FSUIPC does in fact get ALL the traffic from SimConnect (it doesn't really have an option), and uses this for its own Traffic Limiter options, but the TCAS tables are purpose designed and very limited in size, using offsets as they do.

Most programs doing the sort of things you are doing get the traffic data from SimConnect directly, even if they have to use FSUIPC to delete them (SimConnect only lets the object creating program to delete said objects. FSUIPC's method is actually a hack into the code).

I suppose I could make the Ground traffic range for an Airborne user configurable to more than 6 nm, perhaps following the Airborne setting.

Pete

 

Link to post
Share on other sites

Hi Pete

 

Many thanks for your reply.

That makes much more sense now that the Ground Traffic is limited seperatly to the Airborne traffic.

I messed around with the TCAS limiter and was wondering why ground traffic didn't show up (silly me!)

If you can make the Ground traffic limit changeable that would be excellent - that would help myself and I am sure many more developers in the future.

I was using FSUIPC because I am much more familiar with it than SimConnect, even though I understand it isn't designed for this. I downloaded the example C# which includes the starting point of what I need and went along with it.

If you are going to allow the Ground Traffic range to be adjusted (which would make me very happy!), then do let me know. Of course if it isn't possible then do not worry, but it sounds like a good addition to FSUIPC and will allow developers some more flexibility when needed (such as now).

If you have any other suggestions I would certainly look forward to hearing them.

Many thanks

Callum

 

Link to post
Share on other sites
1 minute ago, Callum said:

If you are going to allow the Ground Traffic range to be adjusted (which would make me very happy!), then do let me know.

I'll have a look, before the next release. Not sure when, but they are more or less monthly at least. No promises till I've checked the code. It's pretty old now.

Pete

 

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.