Types and polymorphism

BlitzMax Forums/BlitzMax Beginners Area/Types and polymorphism

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.

After reading John Judnich's great tutorial on OOP and BlitzMax, I though i had finally got round my head round the subject. Alas, no, hence I'm appealing for help... I have a type, TEntity that is Extended by THuman. The field "somevalue" is set in TEntity. I have some very simple code:

Local human:THuman=New THuman
Local entity:TEntity
entity=human

Can someone explain why the values of human.somevalue and entity.somevalue are different?

Thanks, a confused Welshman.