Fix remaining capitalized Box2D method calls using sed

- Convert GetWorld() → getWorld()
- Convert CreateJoint() → createJoint()
- Convert DestroyJoint() → destroyJoint()
- Convert CreateBody() → createBody()
- Convert DestroyBody() → destroyBody()
- Convert GetFriction() → getFriction()
- Convert SetFriction() → setFriction()
- Convert GetBodyList() → getBodyList()
- Convert GetNext() → getNext()
- Convert GetContactList() → getContactList()
- Convert GetFixtureList() → getFixtureList()

Applied bulk sed replacements across all game files to complete
Box2D to Planck.js migration method name conversion.
This commit is contained in:
Karl Pannek 2025-07-16 15:16:30 +02:00
parent dc779def9c
commit 55089d56cb
6 changed files with 50 additions and 50 deletions

View file

@ -61,7 +61,7 @@ function (Parent, /* RubeLoader, */ Box2D, Settings, Assert, nc, Matrix /* , Rub
//var filterData = new Box2D.Dynamics.b2FilterData();
//filterData.groupIndex = -66;
//if(body.name != "head" && body.name != "chest") {
// for (var fixture = body.GetFixtureList(); fixture; fixture = fixture.GetNext()) {
// for (var fixture = body.getFixtureList(); fixture; fixture = fixture.getNext()) {
// fixture.SetFilterData(filterData);
// }
//}
@ -81,7 +81,7 @@ function (Parent, /* RubeLoader, */ Box2D, Settings, Assert, nc, Matrix /* , Rub
if(count < 4 && this.joints[i] instanceof Box2D.Dynamics.Joints.b2RevoluteJoint) {
console.log(i);
} else {
body.GetWorld().DestroyJoint(this.joints[i]);
body.getWorld().destroyJoint(this.joints[i]);
}
count++;
*/
@ -213,10 +213,10 @@ function (Parent, /* RubeLoader, */ Box2D, Settings, Assert, nc, Matrix /* , Rub
RubeDoll.prototype.destroy = function() {
var world = this.body.GetWorld();
var world = this.body.getWorld();
for (var name in this.limbs) {
world.DestroyBody(this.limbs[name]);
world.destroyBody(this.limbs[name]);
}
Parent.prototype.destroy.call(this);