@CONSOLE[title] : Returns 1 if the specified window title belongs to a console window; 0 if it does not. The title may include wildcards.

 

Example:

 

echo %@console[TCC Prompt]

1