示例#1
0
 internal void Destroy()
 {
     Debug.Assert( _game != null, "Destroy must be called only once." );
     OnDestroy();
     _game.GameItemDestroyed( this );
     _game = null;
 }
示例#2
0
 internal Village( Game g, string name )
     : base(g)
 {
     Debug.Assert( !String.IsNullOrWhiteSpace( name ) );
     _name = name;
     _villagers = new List<Villager>();
 }
示例#3
0
 protected GameItem( Game g )
 {
     if( g == null ) throw new ArgumentNullException( "g" );
     _game = g;
     _game.GameItemCreated( this );
 }