Пример #1
0
 public Object CreateObject( string name, Model model = null )
 {
     Object obj = new Object( name );
       if( model != null ) {
     obj.mesh = model.mesh;
     obj.material = model.material;
       }
       this.objectList.Add( obj );
       return obj;
 }
Пример #2
0
 protected override void Dispose( bool disposing )
 {
     if( disposing ) {
     if( this.IsValid ) {
       Console.WriteLine( "~ResourceModel '{0}'", this.name );
       Resource.RemoveResource( this.id );
       this.IsValid = false;
       this.model.Dispose();
       this.model = null;
       Console.WriteLine( "~ResourceModel '{0}' done", this.name );
     }
       }
 }