mirror of
https://github.com/godotengine/godot.git
synced 2025-02-17 22:43:01 +08:00
Merge pull request #77839 from mihe/physics-engine-restart
Change the "Physics Engine" project settings to prompt a restart
This commit is contained in:
commit
ed63b9ea23
@ -912,6 +912,7 @@ void PhysicsServer2DManager::on_servers_changed() {
|
|||||||
physics_servers += "," + get_server_name(i);
|
physics_servers += "," + get_server_name(i);
|
||||||
}
|
}
|
||||||
ProjectSettings::get_singleton()->set_custom_property_info(PropertyInfo(Variant::STRING, setting_property_name, PROPERTY_HINT_ENUM, physics_servers));
|
ProjectSettings::get_singleton()->set_custom_property_info(PropertyInfo(Variant::STRING, setting_property_name, PROPERTY_HINT_ENUM, physics_servers));
|
||||||
|
ProjectSettings::get_singleton()->set_restart_if_changed(setting_property_name, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void PhysicsServer2DManager::_bind_methods() {
|
void PhysicsServer2DManager::_bind_methods() {
|
||||||
|
@ -1079,6 +1079,7 @@ void PhysicsServer3DManager::on_servers_changed() {
|
|||||||
physics_servers2 += "," + get_server_name(i);
|
physics_servers2 += "," + get_server_name(i);
|
||||||
}
|
}
|
||||||
ProjectSettings::get_singleton()->set_custom_property_info(PropertyInfo(Variant::STRING, setting_property_name, PROPERTY_HINT_ENUM, physics_servers2));
|
ProjectSettings::get_singleton()->set_custom_property_info(PropertyInfo(Variant::STRING, setting_property_name, PROPERTY_HINT_ENUM, physics_servers2));
|
||||||
|
ProjectSettings::get_singleton()->set_restart_if_changed(setting_property_name, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void PhysicsServer3DManager::_bind_methods() {
|
void PhysicsServer3DManager::_bind_methods() {
|
||||||
|
Loading…
Reference in New Issue
Block a user