Allow AI to create objects via exact asset ID without specifying type#8509
Merged
Allow AI to create objects via exact asset ID without specifying type#8509
Conversation
When an `exact_asset_id` argument is provided, the asset is fetched directly from its id (using the already-loaded asset short headers) instead of running a search. The lookup fails gracefully if the asset does not exist or if its object type does not match the requested one. https://claude.ai/code/session_01GyeqJSciL54s5UzMbd987M
The type can now be derived from the existing target object (when replacing) or from the fetched asset (when `exact_asset_id` is used). Safety is preserved: any explicit `object_type` must agree with the existing object's type and with the fetched asset's type. A single early mismatch check replaces the two duplicated branches that used to live in createNewObject and replaceExistingObject. A from-scratch creation still requires an object type and fails explicitly if neither `object_type` nor `exact_asset_id` is provided. The asset search helper rejects searches without an object type. https://claude.ai/code/session_01GyeqJSciL54s5UzMbd987M
The previous post-install scan in createOrReplaceObject was wrong: because the asset's objects are already in the project by the time the scan runs, UsedObjectTypeFinder.scanProject always finds the type, so the flag was always false. useInstallAsset already computes this flag before inserting the objects (see NewObjectDialog.js). Propagate it through the AssetSearchAndInstallResult and consume it directly, so the flag reflects the project state prior to installation. https://claude.ai/code/session_01GyeqJSciL54s5UzMbd987M
NBForgeLab
added a commit
to NBForgeLab/GDevelop
that referenced
this pull request
Apr 18, 2026
* Make the home page navigation sidebar collapsible * Fix potential crashes in the scene editor * Improve logs in case of UseAfterFreeError Only show in developer changelog * Fix potential crashes in the scene editor Don't show in changelog * Display extension details side by side with the extension list on large screens (4ian#8482) * Fix hot-reloading of global object instances (4ian#8489) * Fix "Add or edit variables" button always creating variables for object variables (4ian#8493) * Fix "Add or edit variables" button opening scene variables instead of local variables (4ian#8496) * Add save/restore support for linked object relationships (4ian#8499) Fix 4ian#8497 * Fix potential crash during resource reloading (4ian#8500) * Make clear in Storage actions if a number or text is being written (4ian#8498) * Add "Reload Project" menu action (4ian#8501) Co-authored-by: Gleb Volkov <glebusheg@playtika.com> * Remove deprecated, unused GitHub workflow Don't show in changelog * Fix scene properties not usable via the variable action and condition (4ian#8504) * [Auto PR] Update translations (4ian#8474) * Bump newIDE version * Add experimental option in tabs context menu to open some editors (Event Sheets, Extensions...) into separate windows (4ian#8492) * Fix wavesurfer version (4ian#8508) * Allow AI to create objects via exact asset ID without specifying type (4ian#8509) * Fix crashes when using invalid object names in object folders * Support partial asset ID matching in asset search (4ian#8512) Don't show in changelog * Fix missing globally used resources when unloading a scene that uses these resources (4ian#8513) - It only happens when "Unload at scene exit" is selected in project settings and a global object share some resources with a scene object. * Fix tentatively crash in popped-out window when a theme is missing a color (4ian#8518) Fix 4ian#8517 --------- Co-authored-by: Florian Rival <Florian.rival@gmail.com> Co-authored-by: D8H <Davy.Helard@gmail.com> Co-authored-by: LuniMoon <103995399+LuniMoon@users.noreply.github.com> Co-authored-by: Gleb Volkov <glebusheg@playtika.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
NBForgeLab
added a commit
to NBForgeLab/GDevelop
that referenced
this pull request
Apr 18, 2026
* Make the home page navigation sidebar collapsible * Fix potential crashes in the scene editor * Improve logs in case of UseAfterFreeError Only show in developer changelog * Fix potential crashes in the scene editor Don't show in changelog * Display extension details side by side with the extension list on large screens (4ian#8482) * Fix hot-reloading of global object instances (4ian#8489) * Fix "Add or edit variables" button always creating variables for object variables (4ian#8493) * Fix "Add or edit variables" button opening scene variables instead of local variables (4ian#8496) * Add save/restore support for linked object relationships (4ian#8499) Fix 4ian#8497 * Fix potential crash during resource reloading (4ian#8500) * Make clear in Storage actions if a number or text is being written (4ian#8498) * Add "Reload Project" menu action (4ian#8501) * Remove deprecated, unused GitHub workflow Don't show in changelog * Fix scene properties not usable via the variable action and condition (4ian#8504) * [Auto PR] Update translations (4ian#8474) * Bump newIDE version * Add experimental option in tabs context menu to open some editors (Event Sheets, Extensions...) into separate windows (4ian#8492) * Fix wavesurfer version (4ian#8508) * Allow AI to create objects via exact asset ID without specifying type (4ian#8509) * Fix crashes when using invalid object names in object folders * Support partial asset ID matching in asset search (4ian#8512) Don't show in changelog * Fix missing globally used resources when unloading a scene that uses these resources (4ian#8513) - It only happens when "Unload at scene exit" is selected in project settings and a global object share some resources with a scene object. * Fix tentatively crash in popped-out window when a theme is missing a color (4ian#8518) Fix 4ian#8517 --------- Co-authored-by: Florian Rival <Florian.rival@gmail.com> Co-authored-by: D8H <Davy.Helard@gmail.com> Co-authored-by: LuniMoon <103995399+LuniMoon@users.noreply.github.com> Co-authored-by: Gleb Volkov <glebusheg@playtika.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.