22 lines
804 B
C#
22 lines
804 B
C#
// <auto-generated> File: CookwareDataAsset.cs
|
|
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using UnityEngine;
|
|
|
|
namespace DDD
|
|
{
|
|
[CreateAssetMenu(fileName = "InteractionDataAsset", menuName = "GoogleSheet/InteractionDataAsset")]
|
|
public class InteractionDataAsset : DataAsset<InteractionDataEntry>
|
|
{
|
|
public bool TryGetValueByTypeName(string interactionTypeName, string subsystemTypeName, out InteractionDataEntry interactionDataEntry)
|
|
{
|
|
var targetString = $"{interactionTypeName}.{subsystemTypeName}";
|
|
interactionDataEntry = _datas.FirstOrDefault(entry =>
|
|
string.Equals(entry.UnparsedInteractionType, targetString, StringComparison.Ordinal));
|
|
|
|
return interactionDataEntry != null;
|
|
}
|
|
}
|
|
} |