1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Tools Programming FAQ

Discussion in 'Tools programming' started by scruffyduck, 29 Sep 2006.

  1. scruffyduck

    scruffyduck Administrator Staff Member FSDevConf team Resource contributor

    Joined:
    17 Sep 2005
    Messages:
    28,995
    Country:
    unitedkingdom
    This Sticky will be used over time to provide information on Tools Programming. It is intended to help those who may be new to developing add-on programs for FS. It is in the form of a Q&A FAQ and will be added to over time.

    Q. What is the best programming language to develop FS Add-ons?

    A. There isn't one. Add-ons can be developed in any language from C thru Delphi to VB.NET and C#. In many cases it will come down to the degree of interaction that is needed with FS and the personal preference of the developer.

    In FS9 the main way to do that is through FSUIPC and there are SDK examples of how to interact in most of the common programming languages. In FSX the expectation is that developers will use SimConnect to interact. The SDK for SimConnect provides access via C++ or C#, although the managed library can be accessed from any dotNET language such as VB.NET or Java.
     
    Last edited: 18 Oct 2006
  2. Ar Alm

    Ar Alm

    Joined:
    23 Dec 2016
    Messages:
    8
    I'm new. And I'm disappointed that there's just one post here. So, I'll start the questions, and hopefully I'll get good answers.


    1. Should I go with C++, C# or something else, provided that I don't know programming at all.

    2. What's a good resource to learn from for creating FSX addons? Will Microsoft's page (https://msdn.microsoft.com/en-us/library/cc526948.aspx#SimObjectCreationKit) suffice?

    3. What is FSX ESP? Do I need it? If I do, how can I get it?

    4. I want to develop addons that would work for both FSX Acceleration and FSX-SE. Is there anything I should keep in mind?

    Thanks
     
  3. Ronald

    Ronald Resource contributor

    Joined:
    26 Jan 2015
    Messages:
    553
    1. MS-FS[n] is written in C or C++ so if you want to tap into the raw power of MSFS, start learning its own native programming language first.
    This helps you to
    - understand how the FSX-stuff works under-the-hood and to know its internal architecture.
    - to tap directly into the heart of FSX (instead through FSUIPC.DLL internal limitations).


    2. Internet search engines (like Yahoo, Dogpile, Google) is your best friend in this, but here are few link to get you started:
    FSX (ESP) - Programming gauges in C++:

    - https://msdn.microsoft.com/en-us/library/cc526958.aspx

    FSX (ESP) - Creating XML gauges:
    - https://msdn.microsoft.com/en-us/library/cc526953.aspx

    FSX - Development related websites:
    - http://www.flightsim.com/vbfs/forumdisplay.php?24-Panel-amp-Gauge-Design
    >>
    - http://www.fsdeveloper.com/wiki/index.php?title=Category:panel_and_Gauge_Design
    - http://www.fsdeveloper.com/wiki/index.php?title=Category:SimConnect
    - http://www.fsdeveloper.com/wiki/index.php?title=Category:Tools
    >>
    "Welcome to the fs2x Tutorials Page"
    - http://www.fs2x.com/Tutorials.htm
    >>
    "FSX, P3D and CFS3 Gauge Creation Tutorial Rev.35" (download):
    - http://library.avsim.net/index.php?CatID=fsxpan&Sort=Name&ScanMode=0&Page=15


    3a. "ESP" is a kind of "rebranding name" invented by Microsoft for its "flight-simulation product":
    You can read more about it over here:
    - https://msdn.microsoft.com/en-us/library/cc526948.aspx
    - https://msdn.microsoft.com/en-us/library/aa155304.aspx

    3b. You can "get it" by installing it from the DVD's from the "FSX DeLuxe" / "FSX Acceleration" or the "FSX Gold" version:
    Read more about it here:
    - http://www.fsdeveloper.com/wiki/index.php?title=SDK_Installation_(FSX)


    4. I do not have answers for this question, since i'm only(yet) plane designers / builder


    I hope my answers get you started in flightsim development.
     
  4. arno

    arno Administrator Staff Member FSDevConf team Resource contributor

    Joined:
    28 May 2004
    Messages:
    24,698
    Country:
    netherlands
    What kind of addon do you want to make? Not all addons involve programming.
     
  5. Ar Alm

    Ar Alm

    Joined:
    23 Dec 2016
    Messages:
    8
    I'm trying to make an addon like FSIPanel. Something that would make it easier to practice landing repeatedly and evaluate your performance.
     
  6. Ronald

    Ronald Resource contributor

    Joined:
    26 Jan 2015
    Messages:
    553
    - Is it going to be a one-on-one copy of FSI-Panel?
    - What kind of other / new functionalities are you going to create?
     
  7. Ar Alm

    Ar Alm

    Joined:
    23 Dec 2016
    Messages:
    8
    I haven't figured everything out yet, except that I have to learn more C#. As far as programming goes, if there's a level before "beginner" or "newbie" that would be me. The problem is, I can't find all the information I need in one place in order for me to learn what is needed to learn. I've already tried to copy and paste the SDK C# given examples into Visual Studio, but for some reason I get many errors without any changes on my part. These example should work. I spend hours every day just searching for solutions.

    As for the features I'd like to add... here are some:
    1. Touch 'n' go landing reports (which would keep reports coming without ending the flight and reloading).
    2. Random and/or customized weather changes with every landing without ending a flight.
    3. Difficulty levels
    4. The most important feature in my opinion would be that it would be free.
     
    Last edited: 2 Jan 2017
  8. Ronald

    Ronald Resource contributor

    Joined:
    26 Jan 2015
    Messages:
    553
    1 - Then I suggest to start at the absolute C# beginners basics, by choosing the right C# compiler first and learn to install it right on your computer:
    If you do not learn this to perfection, you shall be running into compiler, linker, builder errors, without you have a clue about:
    - What these errors really mean (since you do not know yet how a compiler really works under-the-hood)
    - Where to start looking for a solution to solve it (since you are not yet able to decypher what causes the problem in the first place)
    Only when you got this part right and fully understood, then move on by installing an integrated C# IDE like the one's below, not sooner!
    List of free C# compilers:
    - http://www.thefreecountry.com/compilers/csharp.shtml
    - https://www.visualstudio.com/vs/visual-studio-express/
    - https://eclipse.org/users/

    2 - Next start learning to program C# from the Windows\Linux\Apple COMMANDLINE:
    Why? This gives you a great change to get to know how a compiler, linker, builder and libraries works , and to encounter LOTS of error messages there. Once you got a grasp of that error-level, you are ready to install an integrated C# IDE like Microsoft Visual Studio or Eclipse with a C# addon:
    General C# tutorials
    - https://www.tutorialspoint.com/csharp/
    - http://csharp.net-tutorials.com/
    >
    Microsoft related C# materials
    - https://msdn.microsoft.com/en-us/library/aa288436(v=vs.71).aspx
    - https://msdn.microsoft.com/en-us/library/618ayhy6(v=vs.71).aspx


    That is correct, unfortunately it is splattered all over the Internet.

    Welcome to the FSdevelopers community, where you can find lots of information you need to get started. Just browse the forum and ask your questions in the right section and wait for the replies from the worlds most experienced FS-add-developers here.


    That is the very reason why you should FIRST work you way up from the C# basics:
    - first learn the C# language by heart,
    - get to know your compiler, libraries, linkers, and WHAT causes WHICH errors and know how to solve them first by understanding then fully
    - get to know your your IDE (Visual Studio) works and what you must adjust to get the samples working

    In short:
    There is no quick-and-dirty to easily develop an good Fs-addon by <copy-and-pasting examples>, without:
    - fully understanding the underlying C# language basics,
    - totally know and control your C# compiler
    - mastering your C# IDE first.

    Once you fully and truly understand your C# development environment, you can solve the error within hours.
    Start at the absolute C# first (and master it) then you will enjoy that time spend there later :)
     
  9. Ar Alm

    Ar Alm

    Joined:
    23 Dec 2016
    Messages:
    8
    Thanks Ronald :) I'm getting right into it.
     
  10. Ronald

    Ronald Resource contributor

    Joined:
    26 Jan 2015
    Messages:
    553
    @Ar Alm: You got a [pm] with some more tips
     

Share This Page