<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: MEL command to open current scene without saving in Maya Forum</title>
    <link>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8845291#M26095</link>
    <description>&lt;P&gt;Hi, thanks for the reply.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Your script looks promising, but when I run it in Maya, nothing happens. I'm not really familiar with scripting in general, so I was wondering if I needed to insert or replace something in your script.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;</description>
    <pubDate>Tue, 11 Jun 2019 17:58:08 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2019-06-11T17:58:08Z</dc:date>
    <item>
      <title>MEL command to open current scene without saving</title>
      <link>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8792956#M26093</link>
      <description>&lt;P&gt;Is there a MEL command to open my current Maya scene again without saving? I'm using Maya 2016, and I'm fairly new at scripting in general.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Before exporting an animation for my game engine, I need to delete the namespace of my referenced character. However, I can't save the animation scene without the namespaces, otherwise the animation will be lost forever (but the namespace will be back). It means that each time I want to export, I need to:&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;1. Save my scene;&lt;BR /&gt;2. Delete namespaces (merge with root);&lt;/P&gt;
&lt;P&gt;3. Select my meshes and bones;&lt;BR /&gt;4. Export my selection;&lt;BR /&gt;5. Close my scene without saving;&lt;BR /&gt;6. Open same scene again.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For now, I found a way to do step 2-4:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;namespace -mergeNamespaceWithRoot -removeNamespace "model";
SelectAllPolygonGeometry;
select -add Root ;
ExportSelection&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't know why, but if I add "SaveScene" at the beginning, it will disregard the Namespace and ExportSelection commands. Also, I didn't find any MEL command that would "open scene", choose the current one automatically, then choose "Don't Save".&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;If possible, I'd like to create a button to do all of these steps in one click. The most important thing to me is to find a way to execute step 5 and 6.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Wed, 15 May 2019 15:04:17 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8792956#M26093</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-05-15T15:04:17Z</dc:date>
    </item>
    <item>
      <title>Re: MEL command to open current scene without saving</title>
      <link>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8834993#M26094</link>
      <description>&lt;P&gt;In case this is helpful, I have a script in my maya/scripts folder that will do something similar to what you're describing.&amp;nbsp; This 'reload' script checks the current scene's name (which is its filename), then forces Maya to open it (which will unload the current scene first as part of that process).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;reload.mel&lt;/P&gt;
&lt;PRE&gt;//This script forces a reload of the current file
global proc reload()
{
string $file = `file -q -sceneName`;
file -f -o $file;
}
&lt;/PRE&gt;</description>
      <pubDate>Wed, 05 Jun 2019 20:29:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8834993#M26094</guid>
      <dc:creator>tkaap2</dc:creator>
      <dc:date>2019-06-05T20:29:35Z</dc:date>
    </item>
    <item>
      <title>Re: MEL command to open current scene without saving</title>
      <link>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8845291#M26095</link>
      <description>&lt;P&gt;Hi, thanks for the reply.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Your script looks promising, but when I run it in Maya, nothing happens. I'm not really familiar with scripting in general, so I was wondering if I needed to insert or replace something in your script.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Tue, 11 Jun 2019 17:58:08 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8845291#M26095</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-06-11T17:58:08Z</dc:date>
    </item>
    <item>
      <title>Re: MEL command to open current scene without saving</title>
      <link>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8845583#M26096</link>
      <description>&lt;P&gt;Hi!&lt;/P&gt;
&lt;P&gt;To execute use simply:&lt;/P&gt;
&lt;PRE&gt;reload;&lt;/PRE&gt;
&lt;P&gt;All together here again:&lt;/P&gt;
&lt;PRE&gt;global proc reload()
{
string $file = `file -q -sceneName`;
file -f -o $file;
}

//Execute by using
reload;&lt;/PRE&gt;</description>
      <pubDate>Tue, 11 Jun 2019 19:43:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8845583#M26096</guid>
      <dc:creator>mspeer</dc:creator>
      <dc:date>2019-06-11T19:43:16Z</dc:date>
    </item>
    <item>
      <title>Re: MEL command to open current scene without saving</title>
      <link>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8845682#M26097</link>
      <description>&lt;P&gt;Hi!&lt;/P&gt;
&lt;P&gt;A simpler version that may better fit your needs:&lt;/P&gt;
&lt;PRE&gt;file -f -o `file -q -sceneName`;&lt;/PRE&gt;</description>
      <pubDate>Tue, 11 Jun 2019 20:32:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-forum/mel-command-to-open-current-scene-without-saving/m-p/8845682#M26097</guid>
      <dc:creator>mspeer</dc:creator>
      <dc:date>2019-06-11T20:32:30Z</dc:date>
    </item>
  </channel>
</rss>

