Help & Feedback
Work in progress
Indespensible MaxScripts, Plugins and 3rd Party Tools
The allmighty FREE Resources Thread !
Maxforums member photo gallery index
Maxforums Member Tutorials
three cheers to maxforums...
101 Things you didnt know in Max...
A Face tutorial from MDB101 :D
Maxforums.org Members Gallery
SON OF POST YOURSELF
Dub's Maxscript Tutorial Index
Maxunderground news unavailable
Is there a way to find identical geo and turn it into intance
Like these guys:
All i found on scriptspot was requests like this:
it is strange because situation when you import geo with dead referency has to be common.
I mean i didnt found a single format that actually preserves referenced geometry.
read 728 times
5/10/2015 9:33:20 PM (last edit: 5/10/2015 9:40:26 PM)
If you only select the objects you want to be instances then you could run this code:
for i = selection.count to 2 by -1 do
xyz = selection[i].transform
newinstance = instance selection
newinstance.transform = xyz
Haven't tried it, but it should work.
read 719 times
5/10/2015 9:39:20 PM (last edit: 5/10/2015 9:39:20 PM)
Thx for the fast reply.
Max freezed. )))
Waiting but not sure it will ever unfreeze.
read 716 times
5/10/2015 9:51:44 PM (last edit: 5/10/2015 9:51:44 PM)
Maxscript is insanely slow at most things... Just wait 3-4 days.
(Seriously though, it's slow)
read 712 times
5/10/2015 10:05:26 PM (last edit: 5/10/2015 10:05:26 PM)
Oh dear :D
I think there's an option to disable automatic viewport updates.
Try adding disableSceneRedraw() at the start of the script and enableSceneRedraw() at the end.
read 710 times
5/10/2015 10:07:37 PM (last edit: 5/10/2015 10:10:11 PM)
)) I actually can drag maxscript window.
So it's not ataully freezed. It seems to be working.
But windows always shows stupid status "Not responding"
I mean is it that f. hard to recognise when program is working and when it crashed.
read 705 times
5/10/2015 10:11:32 PM (last edit: 5/10/2015 10:11:32 PM)
I finished and here is the result...
read 698 times
5/10/2015 10:25:59 PM (last edit: 5/10/2015 10:26:53 PM)
I don't get it, just ran it and it worked fine :S
Are you maybe working with layers and all the instances ended up in a hidden layer?
read 694 times
5/10/2015 10:29:11 PM (last edit: 5/10/2015 10:30:16 PM)
They all have same coordinates. Ops..
read 689 times
5/10/2015 10:40:08 PM (last edit: 5/10/2015 10:45:49 PM)
I am not really that good with max script but here is what I think should be the approach.
Pick 4 numbers at random in between 1 and the amount of vertices in the mesh.
then evaluate the difference of that 4 vertices to get some deltas.
Do the same for each model in the scene. It will be very unlikely to get the same deltas if the meshes are not exact duplicates.
That way you can get the identical ones and replace them with instances.
read 663 times
5/11/2015 6:37:42 AM (last edit: 5/11/2015 6:37:42 AM)
Thx for the idea.
It's really strange there is no script to find identical geo.
Because when you import scene from other formats referenced geo turns into unique objects.
So this kind of script had to be needed by many.
read 638 times
5/11/2015 11:51:17 AM (last edit: 5/11/2015 11:51:41 AM)
>>I mean is it that f. hard to recognise when program is working and when it crashed.
If you ignore errors, yes. From my experience with max SDK, many of them seem to be muted so max can be going on computing gibbberish data into other gibberish forever. Also max uses really derpy thread pools which when dependent on each other cant recognize when other has crashed and stall forever. Just chuck it up to max being max...
read 612 times
5/12/2015 5:20:03 PM (last edit: 5/12/2015 5:20:03 PM)
I've used this in the past:
"I flew over Egypt once"
read 602 times
5/12/2015 11:13:39 PM (last edit: 5/12/2015 11:13:39 PM)
Good observation. But still there is a difference between doing something (even wrong) and being frozen in some kind of a failure.
Yep, it's already in max.
Good thing. When i discovered it i was amazed same as when i discovered Replace function in Import.
But selecting is less of a problem.
I need to replace geo with instances.
Just used it.
Built-in "Select similar" DIDN'T work.
Script "Slect similar" did.
read 574 times
5/13/2015 6:01:48 PM (last edit: 5/13/2015 6:49:30 PM)
Yeah, the Max version of select similar does something different. I tried it, but had to use the script instead.
"I flew over Egypt once"
read 561 times
5/13/2015 9:50:33 PM (last edit: 5/13/2015 9:50:33 PM)
Open chat window