Jump to content

Crash Bug 3.6.3 - GUI Editor


Steve_Yorkshire

Recommended Posts

Keep getting a crash/lockup in the new 3.6.3. Stock code. Open GUI editor up and then close twice and it all crashes.

Note: not an issue in 3.6.2.


To reproduce method 1:

Start a level, start GUI editor (F10), close it, reopen GUI editor (F10), close it again and crash/lock.

The error which loops into eternity.

To reproduce method 2:

At MainMenu open GUI Editor, close it, open it again and close aghain and crash/lock.

To reproduce method 3:

Open GUI Editor once, then exit and quit Torque. Lots of errors but T3D will quit before it locks.


The error which loops to crash:

tools/guiEditor/scripts/guiEditorCanvas.ed.cs (223): Unknown command delete.
  Object (4479) MenuBuilder

 

The script: tools/guiEditor/scripts/guiEditorCanvas.ed.cs

/// Called before onSleep when the canvas content is changed
function GuiEditCanvas::onDestroyMenu(%this)
{
   if( !isObject( %this.menuBar ) )
      return;
 
   // Destroy menus      
   while( %this.menuBar.getCount() != 0 )
      %this.menuBar.getObject( 0 ).delete();//yorks - here be dragons!
 
   %this.menuBar.removeFromCanvas();
   %this.menuBar.delete();
}

 

Suggest:

http://media.tumblr.com/1e1d8ecea26aa3ce4e442c713e1e6004/tumblr_inline_mok7jhHaaZ1qz4rgp.png


Bonus Suggestion:

A dedicated bug forum for checking stuff might be useful.

Link to comment
Share on other sites

Looks like MenuBuilder is getting added on the 2nd time GUI Editor is opened - for reasons unknown to god nor nature. :roll:


Also note if you do get to quit before it crashes you get the errors:

tools/base/menuBar/menuBuilder.ed.cs (157): Unknown command removeFromMenuBar.
  Object (4359) MenuBuilder

 

I made a really crappy workaround which really needs a proper fix:

 

/// Called before onSleep when the canvas content is changed
function GuiEditCanvas::onDestroyMenu(%this)
{
   if( !isObject( %this.menuBar ) )
      return;
 
   // Destroy menus      
   while( %this.menuBar.getCount() != 0 )
      //%this.menuBar.getObject( 0 ).delete();//yorks out
   {//yorks in start
      %menu = %this.menuBar.getObject( 0 );
      %canDelete = isMethod(%menu.getClassName(), delete);
      if(%canDelete)
         %menu.delete();
      else
      {
         echo("\c2error removed " @ %menu);
         %this.menuBar.remove(%menu);
      }
   }//yorks in end
 
   %this.menuBar.removeFromCanvas();
   %this.menuBar.delete();
}
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...