Procházet zdrojové kódy

FX: fix loading of shader anims

trethaller před 7 roky
rodič
revize
deaa0a5ae4
1 změnil soubory, kde provedl 5 přidání a 4 odebrání
  1. 5 4
      hide/prefab/fx/FXScene.hx

+ 5 - 4
hide/prefab/fx/FXScene.hx

@@ -233,11 +233,12 @@ class FXScene extends Library {
 		if( inRec )
 			return ctx;
 		ctx = ctx.clone(this);
-		var anim = new FXAnimation(ctx.local3d);
-		getObjAnimations(ctx, this, anim.objects);
-		getShaderAnims(ctx, this, anim.shaderAnims);
-		ctx.local3d = anim;
 		super.makeInstance(ctx);
+		var fxanim = new FXAnimation(ctx.local3d);
+		var ctx = super.makeInstance(ctx);
+		getObjAnimations(ctx, this, fxanim.objects);
+		getShaderAnims(ctx, this, fxanim.shaderAnims);
+		ctx.local3d = fxanim;
 		return ctx; 
 	}