Hello,
I am in the process of trying to get my some of my RUBE scenes running using cocos2d-x. I am using a fairly up to date developer version but regardless it still uses Box2D version 2.2.1. The c++ loader uses the b2MotorJoint so I tried just updating the Box2D files to 2.3.0 in the template but I get errors.
Is the problem that the loader uses 32-bit c++ code to read and manipulate the data and it crashes because I am compiling my app in 64-bit?
Here is my compiler error log:
"b2MotorJoint::GetMaxForce() const", referenced from:
b2dJson::b2j(b2Joint*) in b2dJson.o
"b2MotorJoint::GetMaxTorque() const", referenced from:
b2dJson::b2j(b2Joint*) in b2dJson.o
"b2MotorJoint::GetAngularOffset() const", referenced from:
b2dJson::b2j(b2Joint*) in b2dJson.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Problem using b2djson RUBE loader
Re: Problem using b2djson RUBE loader
Sounds like you just need to add the b2MotorJoint.cpp file to the project.
Re: Problem using b2djson RUBE loader
Got it fixed.
I did have to add the new sources to my compile list.
Weird how other libraries that relied on Box2D lost a link to common files and I had to explicitly add the search path to the folder even though it worked before I upgraded to the newer Box2D version.
Anyways, it works.
Thank you.
I did have to add the new sources to my compile list.
Weird how other libraries that relied on Box2D lost a link to common files and I had to explicitly add the search path to the folder even though it worked before I upgraded to the newer Box2D version.
Anyways, it works.
Thank you.
Re: Problem using b2djson RUBE loader
Those files did not exist in the older Box2D version, so they did not really lose a link, rather it was never there to begin with.