How can i replace all objects in a scene with a new object? I have a game world scene with 100’ish trees and a new tree i’ve imported that i want to use instead of the old tree models. CTRL+L and “link to object data” does not work, it will just remove all the old trees after its applied.
Any idea why this happens or how i can solve it?
Double check youe workflow; usually selecting all the old objects and the new one at last and then Object → Link TransferData ->Link Object Data will work like so:
Maybe: Check in edit mode if any faces are hidden for the new object ?
Is it actually removing them, or just moving them to a different spot? If the new tree has a different origin than the old, this could happen.
They’re gone. Let’s say they’re called “Trees” and the new tree i want to exchange them for is called “Tree1”. If i do Link to Object Data “Tree1” will be named “Trees” instead, that’s all that happens + they’re gone.
No the new tree does not have anything hidden.
I select the tree i want last so that it is highlighted.
It’s an imported game world file (Gothic 2 from 2001). So maybe it just doesn’t work like expected because it’s an imported file.
I asked ChatGPT and it made a script for it instead, but same thing seems to happen.
I guess i have to change them manually, one by one
I have nothing called that in Blender 4.0… I have MeshData, but that didn’t help.
Then, I would test something to narrow down the problem.
If you try to replace all the objects with a simple cube, does it work? If it does, you will know the new tree is the problem, if it doesn’t the old trees are the problem.
Ok. Yeah i’ve tried all the Link-stuff now and nothing works.
Just to be sure nothing is “bugged” because i’ve imported an entire game world + using .3ds files i also created a New scene with 4 basic capsules and one other basic object to replace them. Using the same method, which is described to work for replacing objects. This does not work either, they don’t disappear though, but they are not replaced, nothing happens. So it’s a function that just doesn’t seem to work. Maybe i’ll try the latest Blender.
Edit: tried it in Blender 3.6 since i had it installed. Nah, this does nothing. tried it in the most simple scene possible with just cubes and 1 sphere, nothing happens after ctrl+l, link object data. I make sure the last object is highlighted so it will be used as the replacement.
Okay that’s weird… because it works in 3.6 for me. Just thinking not trying: could it be there is a different reaction if in the prefs edit (or) the option link to Object Data is changed to Object ??
Well try this first
-
Add your new Tree Object manually to the scene and see if the scale and everything else is ok an fitting relative to your old scene.
-
Then select one of the old trees, and swap its mesh data manually in the properties panel under data
Does that work?
I installed Blender 4.2. Here it just works instantly.
The simple reason it doesn’t work in the other versions must be because some addon i use breaks it completely, at least its the only thing i can think of. I’ll have to find out which one it is…
No, it will just disappear.
i tried that, i let ChatGPT write a script. Same thing just happens, all trees apart from the one i want as replacement, disappears.
- Add your new Tree Object manually to the scene and see if the scale and everything else is ok an fitting relative to your old scene.
And this is also not visible?
i’ve imported the new tree, that works and yes it’s in the same scale as the trees i want replaced. I’ve used ctrl+A for location, scale etc. Maybe i don’t understand what you mean with “fitting relative to your old scene” though.
No you got it right, its mainly about the transform data.
But be aware that applying location is no good idea if the object isnt positioned at the world root pos, was that the case with the tree?
If it breaks in the second step I wrote the fault can just lie within the meshdata positions of the new mesh OR the transforms of the existing old data.
If you cant find the error there, strip the file down to a single “old” tree and eg the a cube as new one, save it as a new file, check if its still broken and load it up so we can have a look.
I’ve tried both with and without applying location, so its not that.
not sure how i would strip it down, it’s likely 100K of objects…
Select all, deselect one tree, delete ?
And Menu → File → Cleanup → Purge unused data.
So you might try without addons ??
Oh, didnt notice that. But thats strange. Try importing your addons to 4.2 and see it if still works.