Day 23 Progress
This commit is contained in:
@@ -53,13 +53,22 @@ func main() {
|
||||
} else {
|
||||
fmt.Println(CenterText("Exit", tWidth))
|
||||
}
|
||||
fmt.Println()
|
||||
fmt.Println(CenterText("To run the AdventOfCode Puzzle, pass the input as an argument to the program:", tWidth))
|
||||
fmt.Println(CenterText("./day22 <filename>", tWidth))
|
||||
fmt.Println(CenterText("For the part 1 solution:", tWidth))
|
||||
fmt.Println(CenterText("./day22 <filename> -1", tWidth))
|
||||
ev := termbox.PollEvent()
|
||||
if ev.Type == termbox.EventKey {
|
||||
switch {
|
||||
case ev.Key == termbox.KeyArrowUp || ev.Ch == 'k':
|
||||
menuPos--
|
||||
if menuPos > 0 {
|
||||
menuPos--
|
||||
}
|
||||
case ev.Key == termbox.KeyArrowDown || ev.Ch == 'j':
|
||||
menuPos++
|
||||
if menuPos < 3 {
|
||||
menuPos++
|
||||
}
|
||||
case ev.Key == termbox.KeyEnter:
|
||||
done = true
|
||||
}
|
||||
|
Reference in New Issue
Block a user