Jump to content

You're browsing the 2004-2023 VATSIM Forums archive. All content is preserved in a read-only fashion.
For the latest forum posts, please visit https://forum.vatsim.net.

Need to find something? Use the Google search below.

Euroscope plugin development problems


Eoin Motherway 1315348
 Share

Recommended Posts

Eoin Motherway 1315348
Posted
Posted

I'm looking to teach myself some C++ and EuroScope plugin development stuff. I followed the dev guide and I am getting some errors:

 

0f315420699a48b6bebf4e9be894cb7c.png

 

Can anyone help me sort out the errors?

1. "CPlugIn" is not a nonstatic dada member or base cl[Mod - Happy Thoughts] of cl[Mod - Happy Thoughts] "xxxxxxxx"

2. Identifier "pMyPlugIn" is undefined

 

I know barely anything about C++ or C# (Trying to self-teach myself) so bare with me for the newbie question. I've looked all over google and checked the source code of other plugins, no luck...

 

Merry Christmas!

C1 Controller

/O Pacific Oceanic Endorsement

BICC_FSS (Iceland Radio) Endorsement

Link to comment
Share on other sites

  • 2 weeks later...
Bjoern Helge Smaavollan
Posted
Posted

Not that I'm a programmer myself, but I've been fiddeling a little about.

 

First thing I notice is that it seems you haven't defined/initialized "PMyPlugin" without having read up on ES plugin dev kit, I would say that "PMyPlugin" is a place holder name and should be swapped with the name of your plugin. As I believe this piece of code is used to start our plugin

 

The other error you're having I won't venture out on

Link to comment
Share on other sites

David Zhong
Posted
Posted

In the cl[Mod - Happy Thoughts] definition for CTAAATSVSCSApp (probably located in your ".h" file), check that the cl[Mod - Happy Thoughts] inherits from CPlugIn and that there is a declaration for pMyPlugIn.

 

It should look something like:

 

cl[Mod - Happy Thoughts] CTAAATSVSCSApp : public CPlugIn {
}

EuroScopePlugIn::CPlugIn** pMyPlugIn;

 

To explain what the compiler is unhappy about:

 

(1) In your constructor, everything after ':' and before '{' is called the initialiser list. Here, you can initialise the values of member variables as well as calling the constructor of your base cl[Mod - Happy Thoughts]. The compiler is complaining that CPlugIn doesn't appear to be a member variable or a base cl[Mod - Happy Thoughts]. What is probably missing is that you haven't included the base cl[Mod - Happy Thoughts] in your cl[Mod - Happy Thoughts] definition.

 

(2) Here, the compiler is complaining that it doesn't know what "pMyPlugIn" means. You need to declare this variable somewhere. My understanding of the example code is that it expects pMyPlugIn to be a global variable, so best bet is to declare it in a header file that everything has access to.

David Zhong

Link to comment
Share on other sites

 Share