Exemple #1
0
        void AddToDetails(GameObject detail)
        {
            // Name
            string name = LocalizedStrings.GetCreatureName(creature.Definition.AnimationId);

            AddText(name, detail.transform, new Vector3(7, 2, -3), new Vector3(0.3f, 0.3f, 1));

            // Race
            string race = LocalizedStrings.GetRaceName(creature.Definition.Race);

            AddText(race, detail.transform, new Vector3(-3, 2, -3), new Vector3(0.3f, 0.3f, 1));

            // Occupation
            string occupation = LocalizedStrings.GetOccupationName(creature.Definition.Occupation);

            AddText(occupation, detail.transform, new Vector3(-8, 2, -3), new Vector3(0.3f, 0.3f, 1));

            // LV
            int level = creature.Data.Level;

            AddText(StringUtils.Digit2(level), detail.transform, new Vector3(1.52f, 2, -1.17f), new Vector3(0.3f, 0.3f, 1));
            // EX
            int ex = creature.Data.Exp;

            AddText(StringUtils.Digit2(ex), detail.transform, new Vector3(1.52f, 2, -0.12f), new Vector3(0.3f, 0.3f, 1));
            // MV
            int mv = creature.Data.CalculatedMv;

            AddText(StringUtils.Digit2(mv), detail.transform, new Vector3(1.52f, 2, 1.02f), new Vector3(0.3f, 0.3f, 1));
            // AP
            int ap = creature.Data.CalculatedAp;

            AddText(StringUtils.Digit2(ap), detail.transform, new Vector3(1.52f, 2, 2.22f), new Vector3(0.3f, 0.3f, 1));
            // DP
            int dp = creature.Data.CalculatedDp;

            AddText(StringUtils.Digit2(dp), detail.transform, new Vector3(1.52f, 2, 3.36f), new Vector3(0.3f, 0.3f, 1));

            // DX
            int dx = creature.Data.Dx;

            AddText(StringUtils.Digit2(dx), detail.transform, new Vector3(5.63f, 2, 1.02f), new Vector3(0.3f, 0.3f, 1));
            // HIT
            int hit = creature.Data.CalculatedHit;

            AddText(StringUtils.Digit2(hit), detail.transform, new Vector3(5.63f, 2, 2.22f), new Vector3(0.3f, 0.3f, 1));
            // EV
            int ev = creature.Data.CalculatedEv;

            AddText(StringUtils.Digit2(ev), detail.transform, new Vector3(5.63f, 2, 3.36f), new Vector3(0.3f, 0.3f, 1));

            //HP
            int hp = creature.Data.Hp;

            AddText(StringUtils.Digit3(hp), detail.transform, new Vector3(-9, 2, -0.5f), new Vector3(0.3f, 0.3f, 1));
            //HP MAX
            int hpMax = creature.Data.HpMax;

            AddText(StringUtils.Digit3(hpMax), detail.transform, new Vector3(-12f, 2, -0.5f), new Vector3(0.3f, 0.3f, 1));
            //MP
            int mp = creature.Data.Mp;

            AddText(StringUtils.Digit3(mp), detail.transform, new Vector3(-9, 2, 1.5f), new Vector3(0.3f, 0.3f, 1));
            //MP MAX
            int mpMax = creature.Data.MpMax;

            AddText(StringUtils.Digit3(mpMax), detail.transform, new Vector3(-12f, 2, 1.5f), new Vector3(0.3f, 0.3f, 1));

            // LV
            // AddText("01", this.transform, new Vector3(200, 102, -5), new Vector3(8, 8, 1));
        }
        private void RenderDetails()
        {
            string name = LocalizedStrings.GetCreatureName(creature.Definition.AnimationId);

            RenderText(name, "Canvas/CreatureDetail/Name", FontAssets.FontSizeType.Normal);

            string race = LocalizedStrings.GetRaceName(creature.Definition.Race);

            RenderText(race, "Canvas/CreatureDetail/Race", FontAssets.FontSizeType.Normal);

            string occupation = LocalizedStrings.GetOccupationName(creature.Definition.Occupation);

            RenderText(occupation, "Canvas/CreatureDetail/Occupation", FontAssets.FontSizeType.Normal);

            // LV
            int level = creature.Data.Level;

            RenderText(StringUtils.Digit2(level), "Canvas/CreatureDetail/LV", FontAssets.FontSizeType.Digit);
            // EX
            int ex = creature.Data.Exp;

            RenderText(StringUtils.Digit2(ex), "Canvas/CreatureDetail/EX", FontAssets.FontSizeType.Digit);
            // MV
            int mv = creature.Data.CalculatedMv;

            RenderText(StringUtils.Digit2(mv), "Canvas/CreatureDetail/MV", FontAssets.FontSizeType.Digit);
            // AP
            int ap = creature.Data.CalculatedAp;

            RenderText(StringUtils.Digit2(ap), "Canvas/CreatureDetail/AP", FontAssets.FontSizeType.Digit);
            // DP
            int dp = creature.Data.CalculatedDp;

            RenderText(StringUtils.Digit2(dp), "Canvas/CreatureDetail/DP", FontAssets.FontSizeType.Digit);

            // DX
            int dx = creature.Data.Dx;

            RenderText(StringUtils.Digit2(dx), "Canvas/CreatureDetail/DX", FontAssets.FontSizeType.Digit);
            // HIT
            int hit = creature.Data.CalculatedHit;

            RenderText(StringUtils.Digit2(hit), "Canvas/CreatureDetail/HIT", FontAssets.FontSizeType.Digit);
            // EV
            int ev = creature.Data.CalculatedEv;

            RenderText(StringUtils.Digit2(ev), "Canvas/CreatureDetail/EV", FontAssets.FontSizeType.Digit);

            //HP
            int hp = creature.Data.Hp;

            RenderText(StringUtils.Digit3(hp), "Canvas/CreatureDetail/HP", FontAssets.FontSizeType.DigitSmall);
            //HP MAX
            int hpMax = creature.Data.HpMax;

            RenderText(StringUtils.Digit3(hpMax), "Canvas/CreatureDetail/HPMAX", FontAssets.FontSizeType.DigitSmall);
            //MP
            int mp = creature.Data.Mp;

            RenderText(StringUtils.Digit3(mp), "Canvas/CreatureDetail/MP", FontAssets.FontSizeType.DigitSmall);
            //MP MAX
            int mpMax = creature.Data.MpMax;

            RenderText(StringUtils.Digit3(mpMax), "Canvas/CreatureDetail/MPMAX", FontAssets.FontSizeType.DigitSmall);
        }