mirror of
https://github.com/godotengine/godot.git
synced 2025-01-23 19:12:24 -05:00
World2D: Fix typo in default_density deprecation check
This commit is contained in:
parent
0d53ee274c
commit
08ba6086be
1 changed files with 1 additions and 1 deletions
|
@ -407,7 +407,7 @@ World2D::World2D() {
|
|||
Physics2DServer::get_singleton()->area_set_param(space,Physics2DServer::AREA_PARAM_GRAVITY,GLOBAL_DEF("physics_2d/default_gravity",98));
|
||||
Physics2DServer::get_singleton()->area_set_param(space,Physics2DServer::AREA_PARAM_GRAVITY_VECTOR,GLOBAL_DEF("physics_2d/default_gravity_vector",Vector2(0,1)));
|
||||
// TODO: Remove this deprecation warning and compatibility code for 2.2 or 3.0
|
||||
if (Globals::get_singleton()->get("physics_2d/default_density") && !Globals::get_singleton()->get("physics_2d/default_linear_damp)")) {
|
||||
if (Globals::get_singleton()->get("physics_2d/default_density") && !Globals::get_singleton()->get("physics_2d/default_linear_damp")) {
|
||||
WARN_PRINT("Deprecated parameter 'physics_2d/default_density'. It was renamed to 'physics_2d/default_linear_damp', adjusting your project settings accordingly (make sure to adjust scripts that potentially rely on 'physics_2d/default_density'.");
|
||||
Globals::get_singleton()->set("physics_2d/default_linear_damp", Globals::get_singleton()->get("physics_2d/default_density"));
|
||||
Globals::get_singleton()->set_persisting("physics_2d/default_linear_damp", true);
|
||||
|
|
Loading…
Add table
Reference in a new issue