예제 #1
0
        /// <summary>
        /// Initializes a single actor
        /// </summary>
        /// <param name="name">
        /// A <see cref="System.String"/>
        /// </param>
        /// <returns>
        /// A <see cref="SongActor"/>
        /// </returns>
        public SongActor InitSingle (string name)
        {
            SongActor clone = new SongActor ();
            clone.SetPrototypeByColor (SongActor.Color.White);
            clone.AnchorPointFromGravity = Gravity.Center;
            clone.SetScaleWithGravity (1.0,1.0, Gravity.NorthWest);

            clone.Reactive = true;
            clone.Name = name;
            clone.Owner = null;
            clone.Hide ();

            song_actors.Add (clone);

            return clone;
        }
예제 #2
0
 /// <summary>
 /// Frees a given actor.
 /// </summary>
 /// <param name="actor">
 /// A <see cref="SongActor"/>
 /// </param>
 public void Free (SongActor actor)
 {
     actor.Hide ();
     actor.Owner = null;
     free_actors.Push (actor);
 }