Forum Moderators: wheatpenny Forum Coordinators: Guardian_Angel_671, Daddyo3d
DAZ|Studio F.A.Q (Last Updated: 2025 Feb 06 11:16 pm)
RHaseltine posted at 3:42 PM Sat, 16 July 2022 - #4441386
Ooohhhh thanks! I will give that a try!If you have the file names you just need DzContentMgr, specifically openNativeFile( filepath ) http://docs.daz3d.com/doku.php/public/software/dazstudio/4/referenceguide/scripting/api_reference/object_index/contentmgr_dz#a_1a43e46e9be7ac632990125dcd40721b1b
Looks like it doesn't work, I tried both DzContentMgr.openNativeFile(Filepath in "", merge=true) and openFile(Filepath in "", merge=true) . I also had selected the G8F figure in the scene before I ran the script...
syntax:
DzContentMgr.openNativeFile("D:\DAZ 3D Content Library\People\Genesis 8 Female\Characters\Madeline\Materials\Eyes\Eyes 02.duf", true)
Error:
Script Error: Line 1
TypeError: Result of expression 'DzContentMgr.openNativeFile' [undefined] is not a function.
Stack Trace: ()@:1
Error executing script on line: 1
Script executed in 0 secs 1 msecs.
-------------------------------
Do I need to make an instance of the DzContentMgr first?
This site uses cookies to deliver the best experience. Our own cookies make user accounts and other features possible. Third-party cookies are used to display relevant ads and to analyze how Renderosity is used. By using our site, you acknowledge that you have read and understood our Terms of Service, including our Cookie Policy and our Privacy Policy.
Hi all,
Is there a way in the script IDE to execute a preset (shader/pose/morph etc...) ? Like how a Windows/DOS .bat or Unix shell script can execute a series of OS commands in one fell swoop?
If so what does the syntax look like? I could just make a preset or scene subset to capture a series of changes to an object but i would like to automate the process for different Genesis characters by an automated script.
For example, can a DAZ script to apply a certain skin shader, then change the eye color using a different eye material preset and then execute the height preset of a character when a certain G3F in the scene is selected?
I've used the scripting language to traverse the bones of a figure and do much more complex object behavior manipulation but I don't know how to call a preset to execute from within a simple script. Can someone please share an example or even let me know if it can be done?
Thanks all!