コード例 #1
0
        public void AddParticle(ParticleEffect particle, string name)
        {
            var time = Game.RawGameTime - (Game.Ping / 2000);

            UpdateManager.BeginInvoke(
                () =>
            {
                try
                {
                    if (!particle.IsValid)
                    {
                        return;
                    }

                    var position = particle.GetControlPoint(0);
                    var obstacle = new AreaOfEffectSpeedObstacle(this, position, 200, 200)
                    {
                        EndCastTime     = time,
                        EndObstacleTime = time + (this.ActiveAbility.Radius / this.ActiveAbility.Speed)
                    };

                    this.Pathfinder.AddObstacle(obstacle);
                }
                catch (Exception e)
                {
                    Logger.Error(e);
                }
            });
        }
コード例 #2
0
ファイル: RavageEvadable.cs プロジェクト: vana41203/O9K
        protected override void AddObstacle()
        {
            var obstacle = new AreaOfEffectSpeedObstacle(this, this.Owner.Position, 300, 150)
            {
                EndCastTime     = this.EndCastTime,
                EndObstacleTime = this.EndCastTime + (this.ActiveAbility.Radius / this.ActiveAbility.Speed)
            };

            this.Pathfinder.AddObstacle(obstacle);
        }
コード例 #3
0
        public void AddParticle(ParticleEffect particle, string name)
        {
            var time = Game.RawGameTime - (Game.Ping / 2000);

            var obstacle = new AreaOfEffectSpeedObstacle(this, particle.GetControlPoint(0), 300)
            {
                EndCastTime     = time,
                EndObstacleTime = time + (this.ActiveAbility.Radius / this.ActiveAbility.Speed)
            };

            this.Pathfinder.AddObstacle(obstacle);
        }