Do not delete attached specs after compilation.

Also, copy them when copying the spec.

PiperOrigin-RevId: 688998464
Change-Id: I7229fd8032eafede582194ccf73ab4160fe06768
This commit is contained in:
Alessio Quaglino
2024-10-23 09:41:07 -07:00
committed by Copybara-Service
parent e14aebfd16
commit d17d9e835c
9 changed files with 95 additions and 10 deletions
+3
View File
@@ -1534,6 +1534,9 @@ MJAPI mjsMaterial* mjs_addMaterial(mjSpec* s, mjsDefault* def);
// Get spec from body.
MJAPI mjSpec* mjs_getSpec(mjsElement* element);
// Find spec (model asset) by name.
MJAPI mjSpec* mjs_findSpec(mjSpec* spec, const char* name);
// Find body in spec by name.
MJAPI mjsBody* mjs_findBody(mjSpec* s, const char* name);