Exemple #1
0
	// Use this for initialization
	void Awake () {
		
		// ADD COMPONENT
/*
		// Buscamos al personaje principal
		this.NPCs = GameObject.FindGameObjectsWithTag("Enemy");
		this.boss = GameObject.FindGameObjectWithTag("Boss");
*/
		this.trofeos = GameObject.FindGameObjectWithTag("Trofeos").GetComponent<TrophyEngine>();
		this.music = GameObject.FindGameObjectWithTag ("music_engine").GetComponent<Music_Engine_Script> ();

		// Memory Card Save/Load data
		this.mc = GameObject.FindGameObjectWithTag ("MemoryCard").GetComponent<MemoryCard> ();
		this.save = this.mc.saveData();
		this.load = this.mc.loadData();

		// ADD TEXTURES
		this.LevelUpTexture = Resources.Load<Texture2D>("Misc/levelup");
	}
Exemple #2
0
	// Use this for initialization
	void Start () {

		// Memory Card Save/Load data
		this.mc = GameObject.FindGameObjectWithTag ("MemoryCard").GetComponent<MemoryCard> ();
		this.save = this.mc.saveData ();
		this.load = this.mc.loadData (); 

		this.trofeos = GameObject.FindGameObjectWithTag("Trofeos").GetComponent<TrophyEngine>();
		string[] list_trophies = new string[18];
		this.trofeos.getTrophys (list_trophies);

		string str = "lock_";

		// MAIN MENU
		this.backgroundTexture = Resources.Load<Texture2D>("Trofeos/background_trophyv2");
		this.PlatinoTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[17]+"platino");
		this.EasyTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[9]+"easy");
		this.NormalTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[10]+"normal");
		this.HardTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[11]+"hard");
		this.ExtremeTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[12]+"extreme");
		this.WarriorTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[13]+"guerrero");
		this.SageTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[14]+"maga");
		this.ThiefTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[15]+"ladron");
		this.AllTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[16]+"todos");
		this.BusterSwordTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[6]+"bustersword");
		this.Level5Texture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[2]+"level5");
		this.Level10Texture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[3]+"level10");
		this.Level20Texture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[4]+"level20");
		this.Level50Texture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[5]+"level50");
		this.miniGolemTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[0]+"minigolem");
		this.EsqueletoTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[7]+"esqueleto");
		this.GolemLavaTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[1]+"golemlava");
		this.GolemHieloTexture = Resources.Load<Texture2D>("Trofeos/"+list_trophies[8]+"golemhielo");

		this.btnExitTexture = Resources.Load<Texture2D>("MainMenu/exit");
		this.hoverBtnExitTexture = Resources.Load<Texture2D>("MainMenu/hover_exit");

		this.hoverSound = GameObject.FindGameObjectWithTag("music_engine");

	}
Exemple #3
0
	// Use this for initialization
	void Start () {
		
		seeker = GetComponent<Seeker>();
		player = GameObject.FindGameObjectWithTag("Player");
		player_transform = player.transform;
		anim = GetComponent<Animator>();
		difficulty = PlayerPrefs.GetString ("Difficult");
		npcAttributes.setDificulty (difficulty);
		//this.NPCbar = GameObject.FindGameObjectWithTag("NPCHealth");
		
		this.trofeos = GameObject.FindGameObjectWithTag("Trofeos").GetComponent<TrophyEngine>();
		this.music = GameObject.FindGameObjectWithTag ("music_engine").GetComponent<Music_Engine_Script> ();
		
		controller = GetComponent<CharacterController>();
	}
	// Use this for initialization
	void Start () {
		
		seeker = GetComponent<Seeker>();
		player = GameObject.FindGameObjectWithTag("Player");
		player_transform = player.transform;
		anim = GetComponent<Animator>();
		difficulty = PlayerPrefs.GetString ("Difficult");
		npcAttributes.setDificulty (difficulty);

		this.health_sphere = Resources.Load<GameObject> ("Prefabs/Effects/life_sphere");
		this.mana_sphere = Resources.Load<GameObject> ("Prefabs/Effects/mana_sphere");

		this.trofeos = GameObject.FindGameObjectWithTag("Trofeos").GetComponent<TrophyEngine>();
		this.music = GameObject.FindGameObjectWithTag ("music_engine").GetComponent<Music_Engine_Script> ();

		controller = GetComponent<CharacterController>();
	}