void Buy() { PlaySceneController controller = GameObject.Find("Controller").GetComponent <PlaySceneController>(); controller.BuyItem(itemID, int.Parse(inputCount.text)); inputCount.text = null; gameObject.SetActive(false); }
void OK() { PlaySceneController pc = GameObject.Find("Controller").GetComponent <PlaySceneController>(); pc.Exit(); this.gameObject.SetActive(false); SceneManager.LoadScene("LoginScene"); }
void OnTriggerEnter(Collider other) { if (other.gameObject.tag == "Player") { PlaySceneController pc = GameObject.Find("Controller").GetComponent <PlaySceneController>(); pc.GetMoney(Price); Destroy(this.gameObject); } }
public void UseItem() { PlaySceneController controller = GameObject.Find("Controller").GetComponent <PlaySceneController>(); if (!controller.UseItem(item.ItemID)) { return; } gameObject.GetComponentInChildren <Text>().text = item.ItemCount.ToString(); }
public void UseSkill() { PlaySceneController controller = GameObject.Find("Controller").GetComponent <PlaySceneController>(); if (!controller.UseSkill(characterSkill.SlotNum)) { return; } Debug.Log(gameObject.name + characterSkill.SlotNum + "스킬 사용" + characterSkill.Mp); }
void Start() { estado = "EMISIONES DE CO2 ALTAS"; txtEstado.text = "Estado: " + estado; txtEstado.color = Color.magenta; nivel = 1; experiencia = 0; timer = 0; greenCoins = 100; txtGreenCoins.text = greenCoins.ToString(); playSceneController = this; añoActual = 2020; txtUserName.text = PlayerData.playerData.getUsername(); scene = SceneManager.GetActiveScene(); EstadisticasAction(); //Se carga la pestaña estadisticas para poder activar el script EstadisticasController y tener sus metodos disponibles. }
public override void IncreaseGauge(float amount) { CurrentGauge += amount; PlaySceneController controller = GameObject.Find("Controller").GetComponent <PlaySceneController>(); // >> : 레벨업... if (CurrentGauge >= MaxGauge) { CurrentGauge = CurrentGauge - MaxGauge; controller.LevelUp((int)CurrentGauge); } else { controller.ExpUp((int)CurrentGauge); } // << : }
void SkillLevelDown() { PlaySceneController controller = GameObject.Find("Controller").GetComponent <PlaySceneController>(); controller.SkillLevelDown(slotNum); }
void Awake() { playSC = GameObject.Find("PlaySceneController").GetComponent <PlaySceneController>() as PlaySceneController; }
public PlayGameInstance (PlaySceneController pSC) { this.pSC = pSC; INSTANCE = this; GameState.Init(); }
public PlayGameInstance(PlaySceneController pSC) { this.pSC = pSC; INSTANCE = this; GameState.Init(); }