コード例 #1
0
 public PlayerCursor(int playernumber, CursorPosition pos, ControlSet contr, string tokenloc, string slotloc, Vector2 corner)
 {
     this.Position = pos;
     this.control = contr;
     Token = new Texture(tokenloc);
     Slot = new Texture(slotloc, false);
     this.Corner = corner;
     this.PlayerNumber = playernumber;
     State = CursorState.PokemonSelect;
 }
コード例 #2
0
ファイル: Player.cs プロジェクト: CloneDeath/PokemonSmash
        public Player(BattleArena arena, ControlSet Controls, int ID, PlayerDef definition)
        {
            this.World = arena;
            PokemonName = definition.Pokemon.Name;
            anim = new Animation(Pokemon.Animation);
            anim.state.SetAnimation("idle", true);
            foreach (MixItem item in Pokemon.MixQueue) {
                anim.stateData.SetMix(item.From, item.To, item.Time);
            }
            this.Controls = Controls;
            this.HP = Pokemon.HP;
            this.Attack = Pokemon.Attack;
            this.Defense = Pokemon.Defense;
            this.SpecialAttack = Pokemon.SpecialAttack;
            this.SpecialDefense = Pokemon.SpecialDefense;
            this.Speed = Pokemon.Speed;
            this.ID = (short)ID;

            for (int i = 0; i < 4; i++) {
                Move[i] = new MoveInstance(definition.Moves[i]);
            }

            InitPhysics(arena);
        }