Inheritance: BaseAbility
Example #1
0
 public ThinkRoamAround(Vector2 anchor, float roamingRadius, float attackRange = 60, float sightRange = 110, int damage = 10, bool canBeAttacked = true)
     : base()
 {
     _goTo = new GoToPosition(.5f);
     _swing = new SwingHitAbility(1500, 0f, attackRange, damage);
     _shooter = new ShooterAbility();
     _jump = new JumpAbility();
     _rand = new Random();
     _anchor = anchor;
     _radius = roamingRadius;
     _state = RoamState.Idle;
     SightRange = sightRange;
 }
Example #2
0
        public ThinkInputGuided(float speed = .125f)
        {
            Speed = speed;

            Jump = new JumpAbility();
            Swing = new SwingHitAbility(400, 1);
            Shooter = new ShooterAbility();
            Interact = new InteractAbility();
            _frozen = false;

              /*  // Subscribe to Input events
            _input = InputManager.Instance;
            _input.KUsePotion.Pressed += new EventHandler(OnUsePotion);
            _input.KHit.Pressed += new EventHandler(OnExecuteHit);
            _input.KInteract.Pressed += new EventHandler(OnInteract);
            _input.KJump.Pressed += new EventHandler(OnJump);*/
        }