void JumpToTarget() { callStack.ClearIfStack(); target = ArgumentExpression.replaceVariable(target, context.VariableRepository); index = context.ScenarioRepository.GetCurrentRunningScenario().getIndex(target); callStack.JumpToCommand(index); }
public void Execute(ICallStack callStack, IStoryContext context) { callStack.ClearIfStack(); if (string.IsNullOrEmpty(file)) { file = context.ScenarioRepository.GetCurrentRunningScenario().name; } file = ArgumentExpression.replaceVariable(file, context.VariableRepository); context.ScenarioRepository.JumpToScenario(file); target = ArgumentExpression.replaceVariable(target, context.VariableRepository); if (index < 0) { index = context.ScenarioRepository.GetScenario(file).getIndex(target); } }