Practical application of inheritance

BlitzMax Forums/BlitzMax Beginners Area/Practical application of inheritance

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.

Type tPivot
Field x#,y#,z#
Field matrix#[4,4]
Field pitch#,yaw#,roll#
Field scalex#=1.0,scaley#=1.0,scalez#=1.0
Field qw#,qx#,qy#,qz#=1.0

	Method Move()
		x=x+10
	EndMethod

EndType

Type TCamera Extends tpivot
Field fov#=45.0
	Method New()
		'pivot=New tpivot
	EndMethod
EndType

camera:tcamera=New tcamera
camera.move
Notify camera.x