02-26-2013 11:43 AM
I'm interested in developing a 2D game for BB10, and the Belligerent Blocks example looks like it would have loads of good info. The only problem is that I can't get it to build. I've downloaded the source code, the Box2D code, and the latest SDK, but I can't figure out how to make it all work. When I try to build it, it says that it can't find Box2D.h. i've tried google, scouring the forums, and everything I can think of in the IDE, but I just can't get it to work. Can anyone provide me with an **bleep**-proof guide to setting this up?
02-26-2013 03:29 PM
Yes, I downloaded it and followed the instructions in building.txt and built it in Momentics, but I don't know how to get Belligerent Blocks to recognize it.
03-01-2013 09:30 AM
Same error after doing that. I think I could just copy all of the files in to the Belligerent blocks folder and change where it looks for the headrs in every .cpp file, but I'd really rather not.
03-04-2013 09:14 PM
Yeah, I've tried adding Box2D to the NDK include area and it seemed to help, but I was getting errors for 'sinf' and 'cosf' with suggestions of changing it to std::sinf and std::cosf... So the build didn't work.
03-05-2013 09:15 AM - edited 03-05-2013 11:11 AM
Well, I finally got the Box2D to build the library... I also had to add in the include directory for Box2D so that Blocks could find the header files. Now it's telling me that the build for Blocks cannot use the Box2D library because it's incompatible... Joy...
Any help would be appreciated. Thanks in advance.
Nevermind.. I changed the Build Configuration so that both are the same.. Unfortunately, Blocks doesn't have a Simulator-Debug option and Box2D doesn't have a Simulator option...
And copying configuration settings from one to the other and vice versa doesn't work.
Anyone have a BB Z10 they can send me?
Upon further digging around, I got it to build. Just had to change the target CPU for Box2D.
03-05-2013 11:26 AM - edited 03-05-2013 11:28 AM
What worked for me is to add the directory just before Box2D into your Paths and Symbols area for the Belligerent Blocks Properties, because the header files Blocks is looking for is in Box2D/....
For instance: E:\Blackberry\ndk-10.0.9-workspace\Box2D
Add into Paths and Symbols - Includes: E:/Blackberry/ndk-10.0.9-workspace
Also, be sure to have the Target CPU for Box2D as whatever CPU you have instead of for the Device (Arm).. Which was my mistake, although you're using the PB ....