May 4, 2011 at 12:52am
Now I have pretty much finished the patch, but everytime I open the patch, all of these things need to be set, and I know you can remember numbers using the preset thing, but is there a way to have all this information saved?
May 4, 2011 at 1:37am
autopattr and pattrstorage would be good for this.
Also, would the “Save Default-Valued Object Attributes” setting in the Patcher Inspector do the job? I haven’t tried it.
May 5, 2011 at 3:45pm
also with the autopattr object its default it set to restore data, meaning that when you reopen the patch it will load the last stored info.
May 5, 2011 at 10:17pm
@mharter, I think the Patcher Inspector setting you speak of is about object attributes (like color, font size, etc.) rather than the values they hold, so it’s for something different.
[preset] should be able to remember just about anything you need. When running from a patch using full Max, preset will remember new *stored* settings when you save the patch. When using Runtime or a standalone, it won’t, so you need to manually save with “write” and then use “read” to read in the .maxpresets file it saves.
You can auto-save this file behind the scenes with [closebang] if you want, and load it with [loadbang], though be sure you know the filepath where you’re saving them. Best to use “write” with no argument and force the user (or you) to save somewhere that you remember. (For filepath trickery look at the [sprintf] help file, it usually takes a few tries but can be done.)
the [pattr] system is much more robust (and has a bit more setup time), and allows interpolation, so you may or may not need this. it does require a separate data file, whereas [preset] can be saved with the patch on full Max, but can also use a separate file if you want multiple “banks”.
You must be logged in to reply to this topic.