public InventoryKey(KeyColor color) { type = color.ToInventeryItemType(); }
public bool IsDoorOpenFor(ITileFieldPlayer player) { //A player is only allowed to open a door if he has the right key. return(player.HasItem(doorColor.ToInventeryItemType())); }