SW 중심대학 OSS GIT 서버
박건태, 이승준, 고기완, 이준호
새로운 배포
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
using System.Collections;using System.Collections.Generic;using UnityEngine;
namespace ARLocation{ [CreateAssetMenu(fileName = "PrefabDb", menuName = "AR+GPS/PrefabDatabase")] public class Data : ScriptableObject { [System.Serializable] public class PrefabDatabaseEntry { /// <summary>
/// The `MeshId` associated with the prefab. Should match a `MeshId` from the data created
/// the Web Map Editor (https://editor.unity-ar-gps-location.com).
/// </summary>
public string MeshId;
/// <summary>
/// The prefab you want to associate with the `MeshId`.
/// </summary>
public GameObject Prefab; }
public List<PrefabDatabaseEntry> Entries;
public GameObject GetEntryById(string Id) { GameObject result = null;
foreach (var entry in Entries) { if (entry.MeshId == Id) { result = entry.Prefab; break; } }
return result; } }}
|