• Advertisement
Sign in to follow this  

help making dos program

This topic is 4362 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello! This is my first time posting here so go easy on me. :P I was wondering if anyone could give me pointers on how to make a DOS program that is multithreaded. I need to separate when I'm getting the input. I don't know the advanced studff, I'm only using a getch() method within a while() loop. So it waits for the input first before it iterates. Any help would be greatly appreciated. The reason for this is that there doesn't seem to be a gotoxy() in CodeBlocks so what I was planning on doing was repeatedly clearing the screen then printing everything. I'm making a game where you try to guess the scrambled word. I want to include a timer that's why I want to know how to do it.

Share this post


Link to post
Share on other sites
Advertisement
oh no.. is there an alternative? I mean how do I handle the input in such a way that the main while() statement continues to loop? I've seen some DOS games, you know, the one where the graphics are just letters and numbers.

Share this post


Link to post
Share on other sites
Console!! That's the word! I'm sorry.. I got used to the term dos.. hehe.. funny that I've seen that word in codeblocks.. Sorry bout that.

Share this post


Link to post
Share on other sites
Quote:
Original post by whitespace
Console!! That's the word! I'm sorry.. I got used to the term dos.. hehe.. funny that I've seen that word in codeblocks.. Sorry bout that.


I'm sure at least 90% of everyone here has made that mistake before [grin]

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
It's just a compilation flag thing. The linker needs "/SUBSYSTEM:CONSOLE"; look it up in the help file or on MSDN. Just avoid any graphics calls, make sure you use "_beginthread()" instead of "CreateThread()" and you should be fine.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement