mirror of
https://github.com/coding-horror/basic-computer-games.git
synced 2025-12-25 04:15:45 -08:00
14 lines
362 B
C#
14 lines
362 B
C#
namespace Mugwump;
|
|
|
|
// Provides input methods which emulate the BASIC interpreter's keyboard input routines
|
|
internal static class TextIOExtensions
|
|
{
|
|
internal static Position ReadGuess(this TextIO io, string prompt)
|
|
{
|
|
io.WriteLine();
|
|
io.WriteLine();
|
|
var (x, y) = io.Read2Numbers(prompt);
|
|
return new Position(x, y);
|
|
}
|
|
}
|