Esempio n. 1
0
        /// <summary>
        /// Determines if this object equals the given object.
        /// </summary>
        /// <param name="s">The object to compare.</param>
        /// <returns>Whether this object equals the given object.</returns>
        public bool Equals(Symbol s)
        {
            // If parameter is null return false:
            if (s == null)
            {
                return false;
            }

            // Return true if the fields match:
            return (Name == s.Name) && (Id == s.Id);
        }
Esempio n. 2
0
File: Reel.cs Progetto: ajon542/GDK
 /// <summary>
 /// Initializes a new instance of the <see cref="ReelSymbol"/> class.
 /// </summary>
 /// <param name="symbol">The symbol.</param>
 /// <param name="weight">The weight of the symbol.</param>
 public ReelSymbol(Symbol symbol, int weight = 1)
 {
     Symbol = symbol;
     Weight = weight;
 }
Esempio n. 3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Symbol"/> class.
 /// </summary>
 /// <param name="other">The symbol to copy.</param>
 public Symbol(Symbol other)
 {
     Id = other.Id;
     Name = other.Name;
 }
Esempio n. 4
0
File: Reel.cs Progetto: ajon542/GDK
 /// <summary>
 /// Add a symbol to the reel strip.
 /// </summary>
 /// <param name="symbol">The symbol.</param>
 /// <param name="weight">The weight of the symbol.</param>
 public void AddSymbol(Symbol symbol, int weight = 1)
 {
     Strip.Add(new ReelSymbol(symbol, weight));
 }