Page 1 of 1

Toggle Drying Script (optimized)

Posted: 21 Nov 2009, 02:54
by lemec
Do you need a hotkey to toggle drying mode for brushes?

Create a custom panel button and Edit it.
Name the button something like: "Brush: Toggle Drying"

Set the first action entry to: "Embedded George Script"

Paste the following code in.

Code: Select all

PARAM NONE

tv_getactivetool
PARSE Result curTool toolArgs
dryVal = 0

WHILE (LEN(toolArgs) > 1)
	PARSE toolArgs curArg curParam toolArgs
	IF (CMP(curArg, "dry"))
		IF (curParam == 0)
			dryVal = 1
		ELSE
			dryVal = 0
		END
		tv_Cmd curTool Dry DryVal
	END
END
EDIT: Managed to shorten the script down significantly, thanks to a tip from Svengali

Re: Toggle Drying Script

Posted: 23 Nov 2009, 10:23
by Elodie
hanks for sharing your knowledge, Mark =)

Re: Toggle Drying Script

Posted: 23 Nov 2009, 16:09
by ZigOtto
Elodie wrote:hanks for sharing your knowledge, Mark =)
Tom ...?
Image
:arrow:

Re: Toggle Drying Script

Posted: 23 Nov 2009, 16:11
by Elodie
Wou, it takes me about 30 secondes to understand your joke XD

Re: Toggle Drying Script

Posted: 23 Nov 2009, 16:20
by ZigOtto
probably because you're faster when typing on your keyboard than when understanding your reading . :wink:

Re: Toggle Drying Script (optimized)

Posted: 24 Nov 2009, 08:18
by Elodie
:roll: