Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible Issue with body_set_mode in 4.4 #103650

Open
Jestus opened this issue Mar 5, 2025 · 1 comment
Open

Possible Issue with body_set_mode in 4.4 #103650

Jestus opened this issue Mar 5, 2025 · 1 comment

Comments

@Jestus
Copy link

Jestus commented Mar 5, 2025

Tested versions

Reproducible in 4.4.stable

System information

Godot v4.4.stable - Windows 11 (build 26100) - Multi-window, 3 monitors - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 4080 SUPER (NVIDIA; 32.0.15.6603) - 13th Gen Intel(R) Core(TM) i7-13700K (24 threads)

Issue description

I upgraded my project 4.3 -> 4.4. I worked through many of the initial issues, but one of my scenes will not open in editor.

However, I can load the scene in-game, but when loading the scene I get 403 errors like so:

  <C++ Source>  ./core/templates/rid_owner.h:296 @ initialize_rid()
E 0:00:42:155   body_set_mode: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:569 @ body_set_mode()
E 0:00:42:155   body_set_space: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:541 @ body_set_space()
E 0:00:42:155   body_set_state: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:772 @ body_set_state()
E 0:00:42:155   body_attach_object_instance_id: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:683 @ body_attach_object_instance_id()
E 0:00:42:155   body_set_collision_layer: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:711 @ body_set_collision_layer()
E 0:00:42:155   body_set_collision_mask: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:724 @ body_set_collision_mask()
E 0:00:42:155   body_set_collision_priority: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:737 @ body_set_collision_priority()
E 0:00:42:155   body_set_pickable: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:990 @ body_set_pickable()
E 0:00:42:155   body_set_state: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:772 @ body_set_state()
E 0:00:42:155   body_set_state: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:772 @ body_set_state()
E 0:00:42:155   body_set_param: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:751 @ body_set_param()
E 0:00:42:155   body_set_param: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:751 @ body_set_param()
E 0:00:42:155   body_clear_shapes: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:643 @ body_clear_shapes()
E 0:00:42:155   body_add_shape: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:584 @ body_add_shape()
E 0:00:42:155   body_set_shape_as_one_way_collision: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:661 @ body_set_shape_as_one_way_collision()
E 0:00:42:155   _allocate_rid: Element limit reached.
  <C++ Error>   Method/function failed. Returning: RID()
  <C++ Source>  ./core/templates/rid_owner.h:133 @ _allocate_rid()

This series of errors repeat until:

  <C++ Error>   TOO_MANY_ERRORS
  <C++ Source>  :-1

Looking at the migration documentation, I don't see anything listed that might cause this.
The only Physics change is a single one for SoftBody3D
https://docs.godotengine.org/en/4.4/tutorials/migrating/upgrading_to_godot_4.4.html

Is there any immediate idea of what might be happening? Note: this happens in recovery mode as well.

ALSO:

If I load another scene (in-game) after the above, I get the following issues:

  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:996 @ body_test_motion()
  <Stack Trace> Player.gd:100 @ _physics_process()
E 0:11:34:719   body_set_state: Parameter "body" is null.
  <C++ Source>  modules/godot_physics_2d/godot_physics_server_2d.cpp:772 @ body_set_state()

This also repeats hundreds of times.

Steps to reproduce

Simply hit F5 to run the project, errors go bananas.

Minimal reproduction project (MRP)

https://www.dropbox.com/scl/fi/ovy04zj48mmf5quxgwji5/MRP.zip?rlkey=92krpqfdwu4kjjvlf3ut702jv&st=i8vb4a4a&dl=0

(couldn't reduce it below 10MB)

@Alex2782
Copy link
Member

Alex2782 commented Mar 5, 2025

Reproduced on MacOs.

Godot Editor 4.4 freezes, even in recovery mode.
With Godot Editor 4.3 I can open the project within 20 seconds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants