Update ASCII code while maya is open

Update ASCII code while maya is open

robineAWQK5
Community Visitor Community Visitor
505 Views
2 Replies
Message 1 of 3

Update ASCII code while maya is open

robineAWQK5
Community Visitor
Community Visitor

Hello!


I was wondering if it would be possible to change the code of the scene via the ASCII while the scene is open, so basically that I could run a script that changes the code and it live updates in the scene you have open. 

 

Kind regards

 

506 Views
2 Replies
Replies (2)
Message 2 of 3

FirespriteNate
Advocate
Advocate

No, not really. The ASCII data saved in a .ma scene file on disk is really just like a "recipe" for the scene you want it to "build". It's all basically just MEL commands that are executed one by one on load. There is no link between the ASCII information in the file and the built scene once the load has finished. You can edit the ASCII by hand, or with code, sure, but that will not change anything inside Maya unless you reload the ascii file in full.

Just out of interest, how/why in your case would writing some code to modify the ASCII be any easier than writing some code to modify the scene data directly instead?

0 Likes
Message 3 of 3

matteo.dilena
Enthusiast
Enthusiast

Don't know what's @robineAWQK5 use case, but one thing that is way faster done that way is to blast away reference edits. It saved me a ton of time very often, as there seem to be issues with the reference edit editor within Maya, or the commands it calls. They can be incredibly slow!

0 Likes