コード例 #1
0
 // If the given item is a trasure, tally it off
 public void TallyTreasure(string itemID)
 {
     // Only tally items if they are treasure, not already seen and the cave is not closed
     if (ItemExists(itemID, "TallyTreasure") && itemLookup[itemID].isTreasure && !TreasuresSeen.Contains(itemID) && gameController.CurrentCaveStatus != CaveStatus.CLOSED)
     {
         TreasuresSeen.Add(itemID);
     }
 }
コード例 #2
0
 // Returns true if the given item is a treasure and has been seen by the player
 public bool TreasureWasSeen(string itemID)
 {
     return(ItemExists(itemID, "TreasureWasSeen") && TreasuresSeen.Contains(itemID));
 }