Skip to content

Commit f6ca61f

Browse files
Use set_notify_transform() instead of set_notify_local_transform().
1 parent 5f55923 commit f6ca61f

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

scene/2d/box2d_area.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ void Box2DArea::_notification(int p_what) {
8888
last_step_xform = get_box2dworld_transform();
8989
}
9090

91-
case NOTIFICATION_LOCAL_TRANSFORM_CHANGED: {
91+
case NOTIFICATION_TRANSFORM_CHANGED: {
9292
// Send new transform to physics
9393
Transform2D new_xform = get_box2dworld_transform();
9494

scene/2d/box2d_collision_object.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,7 @@ Box2DCollisionObject::Box2DCollisionObject() {
337337
filterDef.maskBits = 0x0001;
338338

339339
set_physics_process_internal(true);
340-
set_notify_local_transform(true);
340+
set_notify_transform(true);
341341
}
342342

343343
Box2DCollisionObject::~Box2DCollisionObject() {

scene/2d/box2d_physics_body.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ void Box2DPhysicsBody::_notification(int p_what) {
357357
set_process_internal(false);
358358
} break;
359359

360-
case NOTIFICATION_LOCAL_TRANSFORM_CHANGED: {
360+
case NOTIFICATION_TRANSFORM_CHANGED: {
361361
Mode type = get_type();
362362
Transform2D new_xform = get_box2dworld_transform();
363363

@@ -1183,7 +1183,6 @@ bool Box2DPhysicsBody::is_sync_to_physics_enabled() const {
11831183

11841184
Box2DPhysicsBody::Box2DPhysicsBody() {
11851185
set_physics_process_internal(true);
1186-
set_notify_local_transform(true);
11871186
}
11881187

11891188
Box2DPhysicsBody::~Box2DPhysicsBody() {

0 commit comments

Comments
 (0)