public AutoTarget(Actor self, AutoTargetInfo info) { this.info = info; attack = self.Trait <AttackBase>(); Stance = info.InitialStance; PredictedStance = Stance; at = self.TraitOrDefault <AttackFollow>(); }
public AttackActivity(Actor self, Target target, bool allowMove) { attack = self.Trait<AttackFollow>(); move = allowMove ? self.TraitOrDefault<IMove>() : null; // HACK: Mobile.OnRails is horrible var mobile = move as Mobile; if (mobile != null && mobile.Info.OnRails) move = null; this.target = target; }
public AttackActivity(Actor self, Target target, bool allowMove) { attack = self.Trait <AttackFollow>(); move = allowMove ? self.TraitOrDefault <IMove>() : null; // HACK: Mobile.OnRails is horrible var mobile = move as Mobile; if (mobile != null && mobile.Info.OnRails) { move = null; } this.target = target; }