diff options
Diffstat (limited to 'servers/physics')
-rw-r--r-- | servers/physics/area_sw.cpp | 8 | ||||
-rw-r--r-- | servers/physics/area_sw.h | 1 |
2 files changed, 9 insertions, 0 deletions
diff --git a/servers/physics/area_sw.cpp b/servers/physics/area_sw.cpp index 01dfdd633f..e78f0699cb 100644 --- a/servers/physics/area_sw.cpp +++ b/servers/physics/area_sw.cpp @@ -83,6 +83,10 @@ void AreaSW::set_monitor_callback(ObjectID p_id, const StringName& p_method) { _shape_changed(); + if (!moved_list.in_list() && get_space()) + get_space()->area_add_to_moved_list(&moved_list); + + } void AreaSW::set_area_monitor_callback(ObjectID p_id, const StringName& p_method) { @@ -103,6 +107,10 @@ void AreaSW::set_area_monitor_callback(ObjectID p_id, const StringName& p_method _shape_changed(); + if (!moved_list.in_list() && get_space()) + get_space()->area_add_to_moved_list(&moved_list); + + } diff --git a/servers/physics/area_sw.h b/servers/physics/area_sw.h index 0c5295d42a..40ccdaf370 100644 --- a/servers/physics/area_sw.h +++ b/servers/physics/area_sw.h @@ -206,6 +206,7 @@ void AreaSW::remove_area_from_query(AreaSW *p_area, uint32_t p_area_shape,uint32 monitored_areas[bk].dec(); if (!monitor_query_list.in_list()) _queue_monitor_update(); + } |