using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using DG.Tweening;

public class Player2PointIdendifier : MonoBehaviour {

	// Use this for initialization
	public Vector3 GotoPosition;

	void Start () {
	
		transform.DOScale (new Vector3 (2f, 2f, 2f), .25f).OnComplete (gotoPoint);

		//transform.DOLocalMove (-Camera.main.ScreenToWorldPoint(ScorePosition.position), 1.5f);//.OnComplete (killMe);
	
	}


	void gotoPoint()
	{
		//transform.DOLocalMove (-Camera.main.ScreenToWorldPoint(Vector3.zero), 1f).OnComplete (killMe);
		transform.DOLocalMove (GotoPosition, 1f).OnComplete (killMe);
	}

	void killMe()
	{
		Destroy (gameObject);
	}

}
