Hello,
just to justify my question I have to say, that I moved from Java to C++.
Now my problem is, that I have some objects in my DirectX game. They are drawing fine, but all the code I have for the objects are in the main.cpp class.
And thats a problem for me.
Now in Java, I could create a class and just write all the objects code in there and then just create an instance of it, and call the draw method of the objects class in draw.
....
Object object = new Object(blablabla);
..
void draw()
{
...
object.draw();
...
}
Now my question is how to do this in C++/ DirectX ?
As you have all these COM objects, that only can be used in the main class and you have to bind it all to buffers and then draw the buffer.
How could I make this constructor based ? So like the Java exaple ?
A code exaple would be a great help :-)