i need help i c++ graphics

Please support our C++ advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: Jan 2008
Posts: 2
Reputation: amna_aries1 is an unknown quantity at this point 
Solved Threads: 0
amna_aries1 amna_aries1 is offline Offline
Newbie Poster

i need help i c++ graphics

 
0
  #1
Jan 10th, 2008
can anyone help me with mouse handling in c++. espcially on how to check mouse clicking. i am making a game connect four so if anyone could help me with the code and explaining a couple of functions i would really appreciate it. help required urgently.
Reply With Quote Quick reply to this message  
Join Date: Sep 2004
Posts: 7,868
Reputation: Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute 
Solved Threads: 755
Team Colleague
Narue's Avatar
Narue Narue is offline Offline
Senior Bitch

Re: i need help i c++ graphics

 
0
  #2
Jan 10th, 2008
If you don't ask an actual question, you're not likely to get any help.
New members chased away this month: 5
Reply With Quote Quick reply to this message  
Join Date: Feb 2005
Posts: 1,181
Reputation: hollystyles will become famous soon enough hollystyles will become famous soon enough 
Solved Threads: 67
hollystyles's Avatar
hollystyles hollystyles is offline Offline
Veteran Poster

Re: i need help i c++ graphics

 
0
  #3
Jan 10th, 2008
It depends what platform your building your game for. C++ doesn't know about 'mice'

If you're creating your game for Windows, you need to look at the Win32 API. Particularly the message loop or 'pump' as it's sometimes called. Windows will send mouse event msgs with parameters to this function within your C++ program where you can then decide how to handle them.

So Google for some of the terms I've mentioned and you can come back when your problem's a little more specific.
Last edited by hollystyles; Jan 10th, 2008 at 11:59 am.
==========================================
Yadda yadda yadda...
Web junky, fevered monkey
Reply With Quote Quick reply to this message  
Join Date: Dec 2005
Posts: 5,850
Reputation: Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute 
Solved Threads: 751
Team Colleague
Salem's Avatar
Salem Salem is offline Offline
Void main'ers are DOOMed

Re: i need help i c++ graphics

 
0
  #4
Jan 10th, 2008
> and explaining a couple of functions i would really appreciate it
OK,
  1. int main ( ) {
  2. // your code goes here
  3. return 0;
  4. }
All C and C++ programs begin with this function. When the function returns 0, this indicates that the program has successfully run to completion. Other values you can return are specified using the EXIT_SUCCESS and EXIT_FAILURE macro constants.

Further, int main ( int argc, char *argv[] ) introduce the mechanism by which you can specify command line parameters to the program.

> can anyone help me with mouse handling in c++
Standard C++ knows nothing about mice, or any other kind of rodentae. You need to tell us which operating system, compiler, graphics library etc you're using.

> help required urgently.
I'm sure it is, but that isn't my problem.
http://www.catb.org/~esr/faqs/smart-...ns.html#urgent
Reply With Quote Quick reply to this message  
Join Date: May 2006
Posts: 1,867
Reputation: ithelp is a name known to all ithelp is a name known to all ithelp is a name known to all ithelp is a name known to all ithelp is a name known to all ithelp is a name known to all 
Solved Threads: 120
ithelp's Avatar
ithelp ithelp is offline Offline
Posting Virtuoso

Re: i need help i c++ graphics

 
0
  #5
Jan 11th, 2008
You need to make use of MFC apis. Just create an application in VC++ environment and use the mouse operation apis.
Reply With Quote Quick reply to this message  
Join Date: Jan 2008
Posts: 2
Reputation: amna_aries1 is an unknown quantity at this point 
Solved Threads: 0
amna_aries1 amna_aries1 is offline Offline
Newbie Poster

Re: i need help i c++ graphics

 
0
  #6
Jan 11th, 2008
i am using windows xp OS and not sure about the version but i have borlandc++.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the C++ Forum


Views: 773 | Replies: 5
Thread Tools Search this Thread



Tag cloud for C++
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC