in reply to Exiting main loop in Win32::Console

Have you tried using ->PeekInput or ->GetEvents ?

(as you've noticed, you need something that does not block the way ->InputChar does.)

And it's not that simple; you are, after all, asking it to do two things at the same time (print stuff and listen for keyboard input).

(never mind that most likely what you really want is something that's event driven, i.e., listening for both keyboard input and events from whatever it is you're monitoring that's going to cause the printed text to change...)

Replies are listed 'Best First'.
Re^2: Exiting main loop in Win32::Console
by Anonymous Monk on May 17, 2015 at 19:36 UTC
    Ah, that's the stuff was looking for!... GetEvents works very nicely!

    you are true perl monk... thank you!