예제 #1
0
파일: Hero.cs 프로젝트: tomekaq/OnlineRPG
        public Hero()
        {
            IsAlive = true;
            Agility = new Random().Next(2, 12);
            DefensePoint = new Random().Next(3, 18);
            HealthPoints = 200;
            HealthPointsNow = HealthPoints;

            body = new Body();
            head = new Head();
            leftHand = new LeftHand();
            rightHand = new RightHand();
            legs = new Legs();
            bodyPart.Add(body);
            bodyPart.Add(head);
            bodyPart.Add(leftHand);
            bodyPart.Add(rightHand);
            bodyPart.Add(legs);
        }
예제 #2
0
파일: Hero.cs 프로젝트: tomekaq/WebRPGGame
        public Hero()
        {
            IsAlive = true;
            Agility = DiceProvider.Instance.Throw(1, 12);
            DefensePoint = DiceProvider.Instance.Throw(3, 18);
            HealthPoints = 1000;
            HealthPointsNow = 1000;

            body = new Body() { Health = 200 };
            head = new Head() { Health = 200 };
            leftHand = new LeftHand() { Health = 200 };
            rightHand = new RightHand() { Health = 200 };
            legs = new Legs() { Health = 200 };

            bodyPart.Add(body);
            bodyPart.Add(head);
            bodyPart.Add(leftHand);
            bodyPart.Add(rightHand);
            bodyPart.Add(legs);
        }