public bool Step() { char[] stepCommand = VirtualMemory.GetValue(GetICRegisterValue()); char[] nextCommand = VirtualMemory.GetValue(GetICRegisterValue() + 1); string stringCommand = new string(stepCommand); string stringNext = new string(nextCommand); Console.WriteLine("STEP: " + stringCommand + " (NEXT: " + stringNext + ")"); bool commandResult = CommandInterpretator.ParseCommand(stepCommand); if (Test()) { if (!Interrupt()) { FileManager.CloseAll(); return(false); } } if (ChangedIC) { ChangedIC = false; } else { IncICRegisterValue(1); } if (UseMaxStep && CurrentStep++ >= Utility.MAX_STEPS) { return(StopProgram()); } return(commandResult); }
private char GetCurrentCommandSecondLastArgumentChar() { char[] command = VirtualMemory.GetValue(Processor.GetICRegisterValue()); return(command[2]); }
private int GetCurrentCommandSecondLastArgument() { char[] command = VirtualMemory.GetValue(Processor.GetICRegisterValue()); return(command[2].ToString().HexToInt()); }
private int[] GetCurrentCommandLastTwoArguments() { char[] command = VirtualMemory.GetValue(Processor.GetICRegisterValue()); return(new int[] { command[2].ToString().HexToInt(), command[3].ToString().HexToInt() }); }