예제 #1
0
파일: Player.cs 프로젝트: jiowchern/Regulus
        protected override void _SetAbility(Entity.AbilitySet abilitys)
        {
            _ObservedAbility = new PlayerObservedAbility(this, _DBActorInfomation);
            abilitys.AttechAbility<IObservedAbility>(_ObservedAbility);

            _ObserveAbility = new PlayerObserveAbility( _DBActorInfomation);
            abilitys.AttechAbility<IObserveAbility>(_ObserveAbility);

            _CrossAbility = new CrossAbility();
            abilitys.AttechAbility<ICrossAbility>(_CrossAbility);

            _CrossAbility.MoveEvent += _CrossAbility_MoveEvent;

            base._SetAbility(abilitys);
        }
예제 #2
0
파일: Player.cs 프로젝트: jiowchern/Regulus
        /// <summary>
        /// 設定功能
        /// </summary>
        /// <param name="abilitys">現有功能Dict</param>
        protected override void _SetAbility(Entity.AbilitySet abilitys)
        {
            _ObservedAbility = new PlayerObservedAbility(this, _DBActorInfomation);
            abilitys.AttechAbility<IObservedAbility>(_ObservedAbility);

            _ObserveAbility = new PlayerObserveAbility( _DBActorInfomation);
            abilitys.AttechAbility<IObserveAbility>(_ObserveAbility);

            _CrossAbility = new CrossAbility();
            abilitys.AttechAbility<ICrossAbility>(_CrossAbility);

            if(_DBActorInfomation.Property.Identity == Serializable.EntityPropertyInfomation.IDENTITY.CONVERSATION)
            {
                _TeacherAbility = new Session.StuffTeacher(this);
                abilitys.AttechAbility<Session.StuffTeacher>(_TeacherAbility);
            }

            _StudentAbility = new Session.StuffStudent(this);
            abilitys.AttechAbility<Session.StuffStudent>(_StudentAbility);

            base._SetAbility(abilitys);
        }