private void HandleNeededAction(NeededAction action) { switch (action) { case NeededAction.HearthStone: m_mainForm.StopFishing(); goto case NeededAction.Lure; // We continue, Hearthstone need m_hands.DoAction case NeededAction.Lure: case NeededAction.Charm: case NeededAction.Raft: case NeededAction.Bait: m_hands.DoAction(action, m_mouth); break; case NeededAction.AntiAfkMove: m_legs.DoMovement(t2s); break; default: break; } RemoveNeededAction(action); }
private async Task HandleNeededAction(NeededAction action, CancellationToken cancellationToken) { switch (action) { case NeededAction.HearthStone: Stop(); goto case NeededAction.Lure; // We continue, Hearthstone need m_hands.DoAction case NeededAction.Lure: case NeededAction.Charm: case NeededAction.Raft: case NeededAction.Bait: await m_hands.DoAction(action, m_mouth, cancellationToken); break; case NeededAction.AntiAfkMove: await m_legs.DoMovement(t2s, cancellationToken); break; } RemoveNeededAction(action); }