|
@@ -117,8 +117,8 @@ and randomly choose one of the three animation types:
|
|
|
public override void _Ready()
|
|
|
{
|
|
|
var animSprite2D = GetNode<AnimatedSprite2D>("AnimatedSprite2D");
|
|
|
- animSprite2D.Playing = true;
|
|
|
- string[] mobTypes = animSprite2D.Frames.GetAnimationNames();
|
|
|
+ animSprite2D.Play();
|
|
|
+ string[] mobTypes = animSprite2D.SpriteFrames.GetAnimationNames();
|
|
|
animSprite2D.Animation = mobTypes[GD.Randi() % mobTypes.Length];
|
|
|
}
|
|
|
|