Sitni Sati Forums
A few scripting questions. - Printable Version

+- Sitni Sati Forums (https://forum.afterworks.com)
+-- Forum: Products (https://forum.afterworks.com/forumdisplay.php?fid=4)
+--- Forum: FumeFX [max] (https://forum.afterworks.com/forumdisplay.php?fid=8)
+--- Thread: A few scripting questions. (/showthread.php?tid=1184)



A few scripting questions. - neonshaun - 06-01-2011

So we've been having some serious network farts here that are stopping our sims in their tracks. After the sims stop, they cant be resumed because the last frame written out is corrupt and the fdc goes missing. My solution has been to write my stuff out locally, then copy it over to the network storage.

Our render blades only have 40gb free on each though, so I have to constantly be moving stuff over with post step. I'd like this to be completely automated... as in the artist just copies this to their maxscript, hits the check box, and renders.

The problem with this code is it chops off a piece of the output path every time it's run. Also, the fdc file is still written to the original networked location, not to c:/fumecache. Any ideas?

Code:
global FumeFXNode = ffx
global OrigPath = FumeFXNode.GetPath "default"
global LocalPath = "C:\fumecache"
global OutputName = filterString OrigPath "\\"
global BaseName = (OutputName[(OutputName.count)])
global BasePath = ""

for a = 1 to (OutputName.count-1) do
(
BasePath = BasePath + OutputName[a] + "\\"
)



fn PreSim = (
FumeFXNode.SetPath (LocalPath + "\\" + BaseName) "default"
)

fn PostSim = (
DosCommand ("copy /Y " + (LocalPath + "\\" + BaseName) + "* " + (BasePath))
FumeFXNode.SetPath (OrigPath) "default"
)

fn PostStep = (
DosCommand ("move /Y " + (LocalPath + "\\" + BaseName) + "*.fxd " + (BasePath))
)



Also, is there a function to add text to the selected fumefx windows maxscript section?

I'd like to have a toolbar button that would add this to the fumefx container each time.


Re: A few scripting questions. - sitnisati - 06-06-2011

Hello,

"After the sims stop, they cant be resumed because the last frame written out is corrupt and the fdc goes missing"

You can continue simulation from any fxd file if you have velocities and other fields in use exported, if that helps.

Kresimir


Re: A few scripting questions. - neonshaun - 06-06-2011

sitnisati Wrote:You can continue simulation from any fxd file if you have velocities and other fields in use exported, if that helps.

How can I continue a sim over backburner, though?

Back to that second question,
Is there a $.addScript "" command or something that I'm missing?


Re: A few scripting questions. - sitnisati - 06-10-2011

Hello,

I though you can continue sim locally just to finish it when situatins like that happen.

Kresimir


Re: A few scripting questions. - neonshaun - 06-20-2011

We've got too many long sims to continue... it doesn't make sense for us to tie up an artists workstation for days at a time...

as there an $.addScript function? Will there be?


Re: A few scripting questions. - sitnisati - 06-29-2011

There is not such command.. sorry.

Kresimir