Abstract Methods... pop quiz

BlitzMax Forums/BlitzMax Programming/Abstract Methods... pop quiz

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

So is there a really good reason why it can't do this in the New() method?

Surely the reason is because this is how inheritance works. When you create an object, it becomes a base class object first, then becomes an extended class object, and so on if there are multiple levels of inheritance. So in the New method of the base object, it cannot call the inherited method, because at this point in time, it is not of an inherited type. None of the inherited properties (fields and methods) have been added yet.

And with delete, the same is true. The delete methods are called in reverse order, and so by the time it gets back to the base class, it is no longer inherited. Those inherited properties have been destroyed.

EDIT: Furthermore, surely it *has* to work this way or properties in the base class would override properties in the extended class if they were added in a different order.