示例#1
0
 /// <summary>
 /// Gets a reference to the specified house item in the player's house inventory. This can be used to access other information about the item.
 /// </summary>
 /// <param name="id">The id of the item.</param>
 /// <returns>A reference to the specified house item.</returns>
 public InventoryItem GetHouseItemById(int id) => HouseItems.Find(x => x.ID == id);
示例#2
0
 /// <summary>
 /// Gets a reference to the specified house item in the player's house inventory. This can be used to access other information about the item.
 /// </summary>
 /// <param name="name">The name of the house item</param>
 /// <returns>A reference to the specified house item.</returns>
 public InventoryItem GetHouseItemByName(string name) => HouseItems.Find(x => x.Name.Equals(name, StringComparison.OrdinalIgnoreCase));