85 lines
2.3 KiB
C#
85 lines
2.3 KiB
C#
using System.Collections.Generic;
|
|
using System.Collections.ObjectModel;
|
|
|
|
namespace BriarQueen.Data.Identifiers
|
|
{
|
|
public enum ItemKey
|
|
{
|
|
None = 0,
|
|
S_Key,
|
|
DirtyTeddyBear,
|
|
GoldAmulet,
|
|
}
|
|
|
|
public enum EnvironmentKey
|
|
{
|
|
None = 0,
|
|
C1CarNewspaper,
|
|
Codex,
|
|
}
|
|
|
|
public enum PuzzleSlotKey
|
|
{
|
|
None = 0,
|
|
}
|
|
|
|
public static class ItemIDs
|
|
{
|
|
private static readonly IReadOnlyDictionary<PuzzleSlotKey, string> _puzzleSlots =
|
|
new ReadOnlyDictionary<PuzzleSlotKey, string>(
|
|
new Dictionary<PuzzleSlotKey, string>
|
|
{
|
|
});
|
|
|
|
private static readonly IReadOnlyDictionary<EnvironmentKey, string> _environment =
|
|
new ReadOnlyDictionary<EnvironmentKey, string>(
|
|
new Dictionary<EnvironmentKey, string>
|
|
{
|
|
});
|
|
|
|
private static readonly IReadOnlyDictionary<ItemKey, string> _pickups =
|
|
new ReadOnlyDictionary<ItemKey, string>(
|
|
new Dictionary<ItemKey, string>
|
|
{
|
|
{ ItemKey.S_Key, "Item:Pickup:S_Key" },
|
|
{ ItemKey.DirtyTeddyBear, "Item:Pickup:DirtyTeddyBear" },
|
|
{ ItemKey.GoldAmulet, "Item:Pickup:GoldAmulet" },
|
|
});
|
|
|
|
public static string Get(ItemKey key)
|
|
{
|
|
return _pickups.TryGetValue(key, out var id) ? id : string.Empty;
|
|
}
|
|
|
|
public static string Get(EnvironmentKey key)
|
|
{
|
|
return _environment.TryGetValue(key, out var id) ? id : string.Empty;
|
|
}
|
|
|
|
public static string Get(PuzzleSlotKey key)
|
|
{
|
|
return _puzzleSlots.TryGetValue(key, out var id) ? id : string.Empty;
|
|
}
|
|
|
|
public static bool TryGet(ItemKey key, out string id)
|
|
{
|
|
return _pickups.TryGetValue(key, out id);
|
|
}
|
|
|
|
public static bool TryGet(EnvironmentKey key, out string id)
|
|
{
|
|
return _environment.TryGetValue(key, out id);
|
|
}
|
|
|
|
public static bool TryGet(PuzzleSlotKey key, out string id)
|
|
{
|
|
return _puzzleSlots.TryGetValue(key, out id);
|
|
}
|
|
|
|
public static IEnumerable<string> GetAllItemIDs()
|
|
{
|
|
return _pickups.Values;
|
|
}
|
|
}
|
|
}
|