package com.example.jmastermind.Events;

import android.content.Intent;
import android.media.MediaPlayer;
import android.view.animation.Animation;

import androidx.appcompat.app.AppCompatActivity;

import com.example.jmastermind.Menu.Menu;
import com.example.jmastermind.R;

public class PrologueAnimation implements Animation.AnimationListener {
    private AppCompatActivity context;
    private MediaPlayer mp;

    public PrologueAnimation(AppCompatActivity context) {
        this.context = context;
    }

    @Override
    public void onAnimationStart(Animation animation) {
    }

    @Override
    public void onAnimationEnd(Animation animation) {
        Intent i =  new Intent(this.context, Menu.class);
        this.context.startActivity(i);
        this.mp.stop();
    }

    @Override
    public void onAnimationRepeat(Animation animation) {

    }
}
