I just learned GDI in C++ and the first thing I want to make is a simple physics sandbox. I have chosen Box2D for this because it seems lightweigth and easy
However, I'm new to including other projects in my project, so this is what I did to include Box2D:
I copied the Source directory from the zip to my project directory (Visual Studio 2008/Projects/Physics)
Then I make a file called "Box2D.h" and put this in it:
* Copyright (c) 2006-2007 Erin Catto http://www.gphysics.com
* This software is provided 'as-is', without any express or implied
* warranty. In no event will the authors be held liable for any damages
* arising from the use of this software.
* Permission is granted to anyone to use this software for any purpose,
* including commercial applications, and to alter it and redistribute it
* freely, subject to the following restrictions:
* 1. The origin of this software must not be misrepresented; you must not
* claim that you wrote the original software. If you use this software
* in a product, an acknowledgment in the product documentation would be
* appreciated but is not required.
* 2. Altered source versions must be plainly marked as such, and must not be
* misrepresented as being the original software.
* 3. This notice may not be removed or altered from any source distribution.
\mainpage Box2D API Documentation
\section intro_sec Getting Started
For tutorials please see http://www.box2d.org/manual.html
For discussion please visit http://www.box2d.org/forum
// These include files constitute the main Box2D API
And then I added this to my main.cpp file:
b2Vec2 gravity(0.0f, -10.0f);
bool doSleep = true;
b2World world(worldAABB, gravity, doSleep);
However, when I add the last line it stops compiling with this error:
error LNK2001: unresolved external symbol "public: __thiscall b2World::~b2World(void)" (??1b2World@@QAE@XZ)
error LNK2001: unresolved external symbol "public: __thiscall b2World::b2World(struct b2AABB const &,struct b2Vec2 const &,bool)" (??0b2World@@QAE@ABUb2AABB@@ABUb2Vec2@@_N@Z)
I have no idea what this means and I want to use Box2D so badly
Does anyone have a solution?