mirror of
https://github.com/godotengine/godot.git
synced 2024-12-18 09:03:16 +00:00
Make sure sync to physics is disabled in editor, fixes #20230
This commit is contained in:
parent
a2a606794c
commit
0032345618
@ -1425,6 +1425,10 @@ void KinematicBody2D::set_sync_to_physics(bool p_enable) {
|
||||
return;
|
||||
}
|
||||
sync_to_physics = p_enable;
|
||||
|
||||
if (Engine::get_singleton()->is_editor_hint())
|
||||
return;
|
||||
|
||||
if (p_enable) {
|
||||
Physics2DServer::get_singleton()->body_set_force_integration_callback(get_rid(), this, "_direct_state_changed");
|
||||
set_only_update_transform_changes(true);
|
||||
|
Loading…
Reference in New Issue
Block a user