Jonbojangles
02-07-2006, 11:56 PM
The user selects the file they want to merge in the object from.
Once the object is merged in, I want to select only that one object then position it
Problem is I am only able to select all of the objects. I am sure this is something easy, please help a noob out :)
rollout HelmModifier "Parameters"
(
button obj_button "Select File" width:180
button file_button "Select Helm" width:180
global File
on obj_button pressed do
(
File = getOpenFileName caption:"Select file to open" types:"3d Max File (*.max)|*.max|All Files (*.*)|*.*|" --Get the helm setup file name from the user
names = getmaxfileobjectnames File --Get a list of all of the helms inside of the file
mergemaxfile File #prompt names #select --Brings up standard merge dialog box Then asks if you want to overwrite files
select objects --Select all of the objects in the scene
unhide selection --Unhide the helm loaded in
deselect selection
selection.position = [0,0,0] -- Move the object into position
--getCurrentSelection (selection)
--file.count -- returns number of objects in the scene should be 90
-- objects.count -- should be 9
)
)
try (closerolloutfloater HelmModifier_f)catch()
HelmModifier_f = newrolloutfloater "Helm Helper" 220 120
addrollout HelmModifier HelmModifier_F
Once the object is merged in, I want to select only that one object then position it
Problem is I am only able to select all of the objects. I am sure this is something easy, please help a noob out :)
rollout HelmModifier "Parameters"
(
button obj_button "Select File" width:180
button file_button "Select Helm" width:180
global File
on obj_button pressed do
(
File = getOpenFileName caption:"Select file to open" types:"3d Max File (*.max)|*.max|All Files (*.*)|*.*|" --Get the helm setup file name from the user
names = getmaxfileobjectnames File --Get a list of all of the helms inside of the file
mergemaxfile File #prompt names #select --Brings up standard merge dialog box Then asks if you want to overwrite files
select objects --Select all of the objects in the scene
unhide selection --Unhide the helm loaded in
deselect selection
selection.position = [0,0,0] -- Move the object into position
--getCurrentSelection (selection)
--file.count -- returns number of objects in the scene should be 90
-- objects.count -- should be 9
)
)
try (closerolloutfloater HelmModifier_f)catch()
HelmModifier_f = newrolloutfloater "Helm Helper" 220 120
addrollout HelmModifier HelmModifier_F
