Custom Console

Hi, I want to have a custom win32 console (Kinda like the one Wolfenstien: Return to Castle Wolfenstien has) for my game engine. Do any of you know how I can do this?
AllocateConsole();
1) You can add colour to your console using SetConsoleTextAttribute(...).
2) You can resize it using MoveWindow(...) / SetWindowPos(...).
Enjoy!
If you want a console to send commands to your game then a cmd console probably isn't what you want. Maybe just "emulate" a console to read command input.
No that's not what I want to do. I don't want to have the CMD console, I want my own.

Example:

http://prntscr.com/2e979u
closed account (Dy7SLyTq)
are you saying you want to build your own command prompt/terminal/console? it shouldnt be too hard. i highly recommend qt w/ qreator for this. you can create the interface by dragging and dropping and make it look really cool

edit: i suggest getting boost involved too because ive been told that it has a library to execute system commands
Last edited on
Do you want to have your own window which happens to appear like a console, or do you want to run your program with a different console program than the default Windows one?
I want a window that has a custom console. My main window should be able to output data to that window whenever.

I'm planning on doing this in pure WinAPI since my Game Engine is using it.
I don't understand what you mean. Answer my question with one of the possible responses listed, please.
LB wrote:
Do you want to have your own window which happens to appear like a console, or do you want to run your program with a different console program than the default Windows one?
I would like to have my own window that appears like a console, that looks similar to the image I've posted above.
bump
Are you having trouble creating the window or communicating to the main window?
I don't know how to add a text box.
I don't really know winapi well, but here is an example I pieced together from a few tutorials that has two windows, one with a text box for input and a button, the second has an multi-line edit box. Pressing the button sends the text to second window to be displayed in the edit control. http://pastebin.com/25zyFSi8
sorry.... i have no extra knowledge about this topic....
You need a multiline edit control. Be sure to pass ES_MULTILINE to the window style.
http://msdn.microsoft.com/en-us/library/windows/desktop/ff485918.aspx

If you need to use your own color and font styles use a richedit control:
http://msdn.microsoft.com/en-us/library/windows/desktop/bb787605.aspx
Last edited on
Topic archived. No new replies allowed.