Tagged 'General Scripting'

help me make this work!!

Hay all forum member and maxScripter i’m newbie in maxscrpt and need help developing my script, bassiclly it based on copy paste modifier but im try to remodel it a little bit and get dizzy how it work so here is my problem !!
-------------------------------------------- ---------------------------------------------
rollout kie “Untitled”
(
button btn1 “Button” pos:[1,3] width:132 height:22
on btn1 pressed do
(
sel=selection as array
rollout kio “Temp”
(
multilistBox lbx1 “item” pos:[3,1] width:155 height:5 i
)
createDialog kio
)
)
createDialog kie

show vertices as dots

hello

I can't find how to uncheck "show vertices as dots" checkbox via maxscript...
Anybody ?

Select objects once at time and do an action once for each object

Hi!

I have some ojects in an unhidden layer and I'd like to select an object, do an action, select another, do the same action, and so on for all the objects inside the unhidden layer.

The action in my case is to apply a modifier (and change some parameter) that cannot be applied in the same time to all selected objects.

Thanks in advance.

I want to change the messageBox behaviour in my script

Hello,

I have a script that looks like this:

macroScript AutoBackToggle
	category:"Haider"
	buttonText:"AB-Toggle"
	toolTip:"AutoBackup Toggle"
(
	on isChecked do (autoBackup.enabled)
 
	on execute do 
	if autoBackup.enabled == true then 
	(
		autoBackup.enabled = false 
		/*print (autoBackup.enabled)*/
		messageBox "Autobackup disabled." title:"Autobackup State" beep:false
	)
	else 
	(
		autoBackup.enabled = true
		/*print (autoBackup.enabled)*/
		messageBox "Autobackup enabled." title:"Autobackup State" beep:false
	)
)

The Editable_Spline script consumes all available RAM - any help would be greatly appreciated

I'm using this code to remove all spline segments outside a certain object; however, on complex splines, it consumes all available RAM immediately and crashes 3ds Max.
Is there any way to make it significantly faster and less memory-intensive?
Appreciated in advance

(
    fn getMeshBoundingBox2D obj =
    (
        local bbMin = [1e9,1e9,0]
        local bbMax = [-1e9,-1e9,0]
 
        local t = obj.transform
        local vCount = getNumVerts obj
        for i = 1 to vCount do (
            local p = getVert obj i * t
            bbMin.x = amin bbMin.x p.x

Rename Object to Group name

I have a scene with with 1,400 single objects each within it's own group. the objects are named object001. 002,003 etc etc, and the group has the name I want the object to be.
Is this possible via maxscript ?

tia

Naming a material or map

Hi all

Really simple question, and no doubt my first of many for my new script idea!

I've written script to put a VrayHDRI map in to slots 1 & 2 of the material editor but I can't figure out how to name these maps.

How do I script that?

Cheers

Script_Butler.

Please, need help me optimising this script

Hi everyone,

I am new to max scripting and need help optimizing this script. Although this script works as intended I can't but help to think that there must be a better way. That is however beyond my skills to identify.

I wrote this script to check naming conventions.

1- go through everything in the scene

2- check the if the names are matching the given names i.e.(ch_*_A_*, Set_*_A_*, Prop_*_A_*, etc)

3- select everything that are not matching the giving names

4- isolate it

beforehand thank you all for helping a noob out.

/*
Version: v1.1

How can you apply the mod individually?

You can select multiple objects and apply a material to them. How ever apply a UVWmap modifier to the same selected objects the mod is applied to the group as a whole not independently.

This applies a cylindrical UVWmap to one object.

macros.run "Modifiers" "UVWmap"
$.modifiers[#UVW_Mapping].maptype = 1

How could you apply the mod to a select group individually?

detect unicode file names and rename them!

How to DETECT non-english characters inside file names and rename them???

Please help!