additional changes when converting to OOP C++