View Full Version : Macro Recorder question

10 October 2005, 02:31 AM

This is the first time I'm posting here, so apologies if I posted something I should not have. I searched around but couldn't find the answer to my queries, so I decided to take a more direct approach.

If my question has already been asked before, I apologise, and asked to be directed to the relevant thread.

Anyway, I have a scene where I have a section of a wall covered with tiles and bricks. I need to assign each of these tiles and bricks individual sub-material IDs and UVW Map modifier to each of these IDs.

When I first created the scene, I created the bricks and tiles as instances, so I could set the material IDs and the UVW map modifier to one object and have it instanced across the scene.

However, and I am not sure why, I discovered that my UVW map modifier warps and scales itself in a very strange manner when I rotate it. And the texture that I put onto the objects will not respond properly to my manipulations on the co-ordinates level.

I found that I could solve the problem if I create another object, attach the old object to the new object, and reset the UVW map modifier.

The problem I'm facing now though, is that in order to do any attaching I have to turn all those bricks and tiles into unique objects, and I'm faced with the prospect of having to set the UVW Map modifiers manually, one by one. This is extremely time consuming, so I thought I could use the Macro Recorder to record my steps for one of the bricks, and sort of copy the steps onto the next brick, saving time.

I tried to enable the macro recorder on the MaxScript listener, but it's not doing anything. It won't even record something as simple as a translation from point A to point B.

Can anyone let me know what I'm doing wrong with the Macro Recorder; is there someother thing I have to do before it will fire up properly (I'm totally alien to Maxscript and it's functions)? Or does anyone have another solution to my problem?

Thanks a lot for your help.

10 October 2005, 08:44 AM
Make one brick unique and do whatever you need to do to it.
Select all of your bricks making sure you select the brick you edited last then run this script

obj = selection[selection.count]
deselect obj

instanceReplace selection obj

Your problem will be fixed and all of your bricks will be reinstanced to your fixed brick.

CGTalk Moderation
10 October 2005, 08:44 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.