it doesn't sound like your using classes for the right reason if you had to create an init function for a class; but, if you ask me, go with the constructor. They tend to be more self-contained and less worrisome then Init functions.
To the contrary. I think Eber asked the right question. Constructors are for initializing variables. BUT: A constructor has no return value. Therefore, if you do anything that can fail at initialization, use a boolean Init function.
>What im doing is loading external data
Then you basically have two choices. Keep a state and query that like this:
Code:
YourClass c( "externat.dat" );
if( c.failed() ) return false;
or have an Init function:
Code:
YourClass c;
if( ! c.Init("External.dat" ) ) return false;
I personally would prefer the Init function, and if you look at bigger suppliers of class libraries that have to load externals, like databases or datafiles, they seem to prefer that, too.