public ParallelGoal(ILogger logger, ConfigurableInput input, PlayerReader playerReader, StopMoving stopMoving, List <KeyAction> keysConfig, CastingHandler castingHandler) { this.logger = logger; this.input = input; this.stopMoving = stopMoving; this.playerReader = playerReader; this.castingHandler = castingHandler; AddPrecondition(GoapKey.incombat, false); keysConfig.ForEach(key => this.Keys.Add(key)); }
public AdhocGoal(ILogger logger, ConfigurableInput input, KeyAction key, PlayerReader playerReader, StopMoving stopMoving, CastingHandler castingHandler) { this.logger = logger; this.input = input; this.stopMoving = stopMoving; this.playerReader = playerReader; this.key = key; this.castingHandler = castingHandler; if (key.InCombat == "false") { AddPrecondition(GoapKey.incombat, false); } else if (key.InCombat == "true") { AddPrecondition(GoapKey.incombat, true); } this.Keys.Add(key); }
public PullTargetGoal(ILogger logger, ConfigurableInput input, PlayerReader playerReader, NpcNameFinder npcNameFinder, StopMoving stopMoving, CastingHandler castingHandler, StuckDetector stuckDetector, ClassConfiguration classConfiguration) { this.logger = logger; this.input = input; this.playerReader = playerReader; this.npcNameFinder = npcNameFinder; this.stopMoving = stopMoving; this.castingHandler = castingHandler; this.stuckDetector = stuckDetector; this.classConfiguration = classConfiguration; AddPrecondition(GoapKey.incombat, false); AddPrecondition(GoapKey.hastarget, true); AddPrecondition(GoapKey.pulled, false); AddPrecondition(GoapKey.withinpullrange, true); AddPrecondition(GoapKey.isswimming, false); AddEffect(GoapKey.pulled, true); this.classConfiguration.Pull.Sequence.Where(k => k != null).ToList().ForEach(key => this.Keys.Add(key)); }
public CombatGoal(ILogger logger, ConfigurableInput input, Wait wait, AddonReader addonReader, StopMoving stopMoving, ClassConfiguration classConfiguration, CastingHandler castingHandler) { this.logger = logger; this.input = input; this.wait = wait; this.addonReader = addonReader; this.playerReader = addonReader.PlayerReader; this.stopMoving = stopMoving; this.classConfiguration = classConfiguration; this.castingHandler = castingHandler; AddPrecondition(GoapKey.incombat, true); AddPrecondition(GoapKey.hastarget, true); AddPrecondition(GoapKey.targetisalive, true); AddPrecondition(GoapKey.incombatrange, true); AddEffect(GoapKey.producedcorpse, true); AddEffect(GoapKey.targetisalive, false); AddEffect(GoapKey.hastarget, false); classConfiguration.Combat.Sequence.Where(k => k != null).ToList().ForEach(key => Keys.Add(key)); }
public PullTargetGoal(ILogger logger, ConfigurableInput input, Wait wait, AddonReader addonReader, StopMoving stopMoving, CastingHandler castingHandler, StuckDetector stuckDetector, ClassConfiguration classConfiguration) { this.logger = logger; this.input = input; this.wait = wait; this.addonReader = addonReader; this.playerReader = addonReader.PlayerReader; this.stopMoving = stopMoving; this.castingHandler = castingHandler; this.stuckDetector = stuckDetector; this.classConfiguration = classConfiguration; classConfiguration.Pull.Sequence.Where(k => k != null).ToList().ForEach(key => Keys.Add(key)); AddPrecondition(GoapKey.targetisalive, true); AddPrecondition(GoapKey.incombat, false); AddPrecondition(GoapKey.hastarget, true); AddPrecondition(GoapKey.pulled, false); AddPrecondition(GoapKey.withinpullrange, true); AddEffect(GoapKey.pulled, true); }