Selaa lähdekoodia

Fixed default sprite with no material.

Mark Sibly 6 vuotta sitten
vanhempi
commit
775b020a88
1 muutettua tiedostoa jossa 4 lisäystä ja 1 poistoa
  1. 4 1
      modules/mojo3d/scene/entities/sprite.monkey2

+ 4 - 1
modules/mojo3d/scene/entities/sprite.monkey2

@@ -26,9 +26,12 @@ Class Sprite Extends Renderable
 		
 		
 		Super.New( parent )
 		Super.New( parent )
 		
 		
+		Global _defaultMaterial:=New SpriteMaterial
+		
 		Name="Sprite"
 		Name="Sprite"
+		Material=_defaultMaterial
 		
 		
-		AddInstance()
+		AddInstance( New Variant[]( parent ) )
 		
 		
 		Visible=True
 		Visible=True
 	End
 	End