using UnityEngine;
using System.Collections;
using System.Collections.Generic;

public class MyManager : MonoBehaviour {
	public BasementManager basement;
	public WorldMapManager worldMapManager;
	public VirginFoodsManager virginFoodsManager;
	public HomeSteepleManager homeSteepleManager;
	public WorkbenchManager workbenchManager;
	public StartScreenManager startScreenManager;
	public CreditsManager creditsManager;

	public Knife knife;

	public MyPlayer player;

	public string CurrentLevel = "Home"; // updates upon selection at world screen...
	
	Vector2 GameStartPosition = new Vector2();

	void Awake()
	{
		basement = GameObject.Find("Basement").GetComponent<BasementManager>();
		worldMapManager = GameObject.Find("World Map").GetComponent<WorldMapManager>();
		player = GameObject.Find("Player").GetComponent<MyPlayer>();
		virginFoodsManager = GameObject.Find("VirginFoods").GetComponent<VirginFoodsManager>();
		homeSteepleManager = GameObject.Find("HomeSteeple").GetComponent<HomeSteepleManager>();
		workbenchManager = GameObject.Find("Workbench").GetComponent<WorkbenchManager>();
		startScreenManager = GameObject.Find("StartScreen").GetComponent<StartScreenManager>();
		creditsManager = GameObject.Find("CreditsScreen").GetComponent<CreditsManager>();
	}

	void Start()
	{
		GameStartPosition = startScreenManager.StartPosition;
		player.transform.position = new Vector3(GameStartPosition.x,GameStartPosition.y,0);
	}

	public Vector2 ConvertToVector2(Vector2 myVect)
	{
		return new Vector2(myVect.x,myVect.y);
	}
	
	public Vector3 ConvertToVector3(Vector2 myVect)
	{
		return new Vector3(myVect.x,myVect.y,0);
	}
}
