コード例 #1
0
ファイル: Player.cs プロジェクト: GunnerJnr/lib9c
        // ToDo. 지금은 스테이지에서 재료 아이템만 주고 있음. 추후 대체 불가능 아이템도 줄 경우 수정 대상.
        public CollectionMap GetRewards(List <ItemBase> items)
        {
            var map = new CollectionMap();

            foreach (var item in items)
            {
                map.Add(Inventory.AddItem(item));
            }

            return(map);
        }
コード例 #2
0
ファイル: Player.cs プロジェクト: GunnerJnr/lib9c
        protected Player(Player value) : base(value)
        {
            Exp                 = (ExpData)value.Exp.Clone();
            Inventory           = value.Inventory;
            worldInformation    = value.worldInformation;
            weapon              = value.weapon;
            armor               = value.armor;
            belt                = value.belt;
            necklace            = value.necklace;
            ring                = value.ring;
            monsterMap          = value.monsterMap;
            eventMap            = value.eventMap;
            hairIndex           = value.hairIndex;
            lensIndex           = value.lensIndex;
            earIndex            = value.earIndex;
            tailIndex           = value.tailIndex;
            characterLevelSheet = value.characterLevelSheet;

            _costumes   = value._costumes;
            _equipments = value._equipments;
        }
コード例 #3
0
ファイル: Player.cs プロジェクト: x86chi/lib9c
 public Player(int level, TableSheets tableSheets) :
     base(
         null,
         tableSheets,
         GameConfig.DefaultAvatarCharacterId,
         level)
 {
     Exp.Current      = 0;
     Inventory        = new Inventory();
     worldInformation = null;
     weapon           = null;
     armor            = null;
     belt             = null;
     necklace         = null;
     ring             = null;
     monsterMap       = new CollectionMap();
     eventMap         = new CollectionMap();
     hairIndex        = 0;
     lensIndex        = 0;
     earIndex         = 0;
     tailIndex        = 0;
     PostConstruction(tableSheets);
 }
コード例 #4
0
ファイル: Player.cs プロジェクト: x86chi/lib9c
 public Player(AvatarState avatarState, TableSheets tableSheets)
     : base(
         null,
         tableSheets,
         avatarState.characterId,
         avatarState.level)
 {
     // FIXME 중복 코드 제거할 것
     Exp.Current      = avatarState.exp;
     Inventory        = avatarState.inventory;
     worldInformation = avatarState.worldInformation;
     weapon           = null;
     armor            = null;
     belt             = null;
     necklace         = null;
     ring             = null;
     monsterMap       = new CollectionMap();
     eventMap         = new CollectionMap();
     hairIndex        = avatarState.hair;
     lensIndex        = avatarState.lens;
     earIndex         = avatarState.ear;
     tailIndex        = avatarState.tail;
     PostConstruction(tableSheets);
 }