When you define a constructor, it can include a member initialiser list. That's the proper way to initialise members and base classes. So you'd implement the constructor of you
like this:
you::you(string Name, int Number, COLORREF Color) :
name(Name),
number(Number),
color(Color),
drink(whatever_arguments, you_want)
{
// body as usual
}
Note that this is the only way to initialise data members of a class. If you instead do this:
you::you(string Name, int Number, COLORREF Color)
{
name = Name;
number = Number;
color = Color;
}
then you're not initialising the members, you're assigning to them. The empty member initialiser list will first default-initialise them. That means calling the default constructor for classes, and leaving an uninitialised value for primitive types. Then, the constructor body overwrites them by assigning into them.
It's always better to use member initialiser lists, because you skip the (useless) default initialisation. Sometimes, it's also the only way, if you have a non-assignable member (such as a const
member, a reference, or simply an object without an accessible assignment operator).