Пример #1
0
    void OnMouseOver()
    {
        if (Input.GetMouseButtonDown(0))
        {
            Ability1 = GameObject.Find("Ability1");
            if (Ability1 == null)
            {
                Ability1 = GameObject.Find("Ability1Alt");
            }
            Ability2 = GameObject.Find("Ability2");
            if (Ability2 == null)
            {
                Ability2 = GameObject.Find("Ability2Alt");
            }
            Ability3 = GameObject.Find("Ability3");
            if (Ability3 == null)
            {
                Ability3 = GameObject.Find("Ability3Alt");
            }
            Ability4 = GameObject.Find("Ability4");
            if (Ability4 == null)
            {
                Ability4 = GameObject.Find("Ability4Alt");
            }

            if (Ability1.GetComponent <AbilityPreset>().abilityPressed == true)
            {
                Ability1.GetComponent <AbilityPreset>().Point(this.gameObject);
            }
            if (Ability2.GetComponent <AbilityPreset>().abilityPressed == true)
            {
                Ability2.GetComponent <AbilityPreset>().Point(this.gameObject);
            }
            if (Ability3.GetComponent <AbilityPreset>().abilityPressed == true)
            {
                Ability3.GetComponent <AbilityPreset>().Point(this.gameObject);
            }
            if (Ability4.GetComponent <AbilityPreset>().abilityPressed == true)
            {
                Ability4.GetComponent <AbilityPreset>().Point(this.gameObject);
            }
        }
    }
Пример #2
0
        public override string ToString()
        {
            String Moves  = "";
            String Levels = "";

            for (int i = 0; i < MoveLevels.Length; i++)
            {
                Moves  = Moves + MoveList[i].ToString() + "¶";
                Levels = Levels + MoveLevels[i].ToString() + "¶";
            }
            Moves  = Moves + "65535";
            Levels = Levels + "65535" + "¶";
            return(ID + "¶" + Name + "¶" + BaseHP.ToString() + "¶" + BaseAttack.ToString() + "¶" + BaseDefense.ToString() + "¶" + BaseSpecialAttack.ToString() + "¶" + BaseSpecialDefense.ToString() + "¶" + BaseSpeed.ToString() + "¶" + ((int)LevelingType).ToString() + "¶" + FormID.ToString() + "¶" + GenderValue.ToString() + "¶" + ((int)Type1).ToString() + "¶" + ((int)Type2).ToString() + "¶" + CatchRate.ToString() + "¶" + ExpYield.ToString() + "¶" + EffortYield.ToString() + "¶" + Item1.ToString() + "¶" + Item2.ToString() + "¶" + Ability1.ToString() + "¶" + Ability2.ToString() + "¶" + Ability3.ToString() + "¶" + DexEntry + "¶" + Levels + Moves);
        }