Box2D Forums

It is currently Sat May 25, 2013 9:08 am

All times are UTC - 8 hours [ DST ]




Post new topic Reply to topic  [ 8 posts ] 
Author Message
PostPosted: Sun Dec 28, 2008 6:20 pm 
Offline

Joined: Sun Dec 28, 2008 6:17 pm
Posts: 5
i followed the how to but the game will not work when i click build it comes up with:

1>------ Build started: Project: box2d, Configuration: Debug Win32 ------
1>Compiling...
1>HelloWorld.cpp
1>d:\my documents\downloads\box2d_v2.0.1\box2d_v2.0.1\box2d\examples\helloworld\helloworld.cpp(19) : fatal error C1083: Cannot open include file: 'Box2D.h': No such file or directory
1>Build log was saved at "file://d:\My Documents\Visual Studio 2008\Projects\box2d\box2d\Debug\BuildLog.htm"
1>box2d - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
:!: :?: :!:


Top
 Profile  
 
 Post subject: sp...
PostPosted: Sun Dec 28, 2008 9:08 pm 
Offline

Joined: Sun Dec 28, 2008 6:17 pm
Posts: 5
sry about miss spelling make (mixed up the a and the m!)


Top
 Profile  
 
PostPosted: Mon Dec 29, 2008 11:38 am 
Offline

Joined: Sun Dec 28, 2008 6:17 pm
Posts: 5
can some one plz just email me a 'build'et version of box2d because now it is getting more errors! :x

PS:my email is: elff107@hotmail.com


Top
 Profile  
 
PostPosted: Mon Dec 29, 2008 11:48 am 
Offline

Joined: Mon Jan 07, 2008 10:51 am
Posts: 1911
Um, there's not much point getting a built version of Box2D. You are aware Box2D is a game library, and not a game in itself?

What are you using to compile it, I cannot tell directly form your error message what is wrong.


Top
 Profile  
 
PostPosted: Mon Dec 29, 2008 3:52 pm 
Offline

Joined: Sun Dec 28, 2008 6:17 pm
Posts: 5
i mean built as in the file u get after u press f5 'build' in the "how to". All i'm doing is doing what it say's to do in th "how to" on this site...


Top
 Profile  
 
PostPosted: Tue Dec 30, 2008 3:22 am 
Offline

Joined: Mon Dec 29, 2008 7:47 am
Posts: 3
Location: UK
elff107 wrote:
1>d:\my documents\downloads\box2d_v2.0.1\box2d_v2.0.1\box2d\examples\helloworld\helloworld.cpp(19) : fatal error C1083: Cannot open include file: 'Box2D.h': No such file or directory

This is probably because VS2008 doesn't know where to find the include file for box2d. If you look at the source file in question, you'll see that it has a #include "Box2D.h" directive, instructing the compiler to read the Box2D.h file when compiling. The compiler will look in the same directory as the source file, but it doesn't find Box2D.h there, so it fails with that error message.

In order to get this to work you need to configure VS2008's include directories so that Box2D's include directory is on the list. To do this:

1. Select Tools / Options from the main menu
2. Click into the Projects and Solutions/VC++ Directories section
3. Drop down "Show directories for" and select "Include files"
4. Click the "New Line" button and then browse in the item that appears to the Box2D include directory (e.g., "D:\Code\Box2d\Include", or wherever you have the Box2D files stored)
5. Drop down "Show directories for" and select "Library files"
6. Click the "New Line" button and then browse in the item that appears to the Box2D library directory (e.g., "D:\Code\Box2d\Library")
7. Click OK to return to the VS2008 IDE

Once you've done this, try compiling again. This time VS2008 should know where to look to find the Box2D.h file and it should compile cleanly.


Top
 Profile  
 
PostPosted: Tue Dec 30, 2008 12:38 pm 
Offline

Joined: Sun Dec 28, 2008 6:17 pm
Posts: 5
Um i all ready did that (i followed the how to) and now even more files are missing!(not because of what you sayed)I need help!...


Top
 Profile  
 
PostPosted: Mon Jan 05, 2009 2:46 pm 
Offline
Site Admin

Joined: Thu Sep 06, 2007 12:34 am
Posts: 2931
elff, do you know how to write a C++ program? Can you write a C++ OpenGL program that moves a box around the screen? If not, you probably should not be trying to use Box2D.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC - 8 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
cron
Powered by phpBB® Forum Software © phpBB Group