Animated & non Animated meshes

Blitz3D Forums/Blitz3D Beginners Area/Animated & non Animated meshes

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.

Yap, try this:
Graphics3D 640,480 
SetBuffer BackBuffer() 

camera=CreateCamera() 

light=CreateLight() 
RotateEntity light,90,0,0 

arialfont = LoadFont("Arial", 16)
SetFont arialfont

model% = LoadMesh("the_static_model")
If model <> 0 Then PositionEntity model,0,0,MeshDepth(model)*2

; Load mesh 
animmodel% = LoadAnimMesh("the_static_model")

If animmodel <> 0
	Animate animmodel
	anim_length% = AnimLength(animmodel) 
	animate_ing% = Animating(animmodel)
EndIf

While Not KeyDown( 1 ) 

	RenderWorld
	UpdateWorld
	If animmodel <> 0
		Text 0,0,"Model is valid"
		Text 0,20, "Width = "+MeshWidth(animmodel)
		Text 0,40, "Height = "+MeshHeight(animmodel)
		Text 0,60, "Depth = "+MeshDepth(animmodel)
		Text 0,80, "Anim length = "+anim_length
		Text 0,100, "Animating = "+animate_ing
	Else
		Text 0,0,"Model is not valid"
	EndIf
	Flip 

Wend

End