Files
vr-configurator/vr-configurator/Assets/Scripts/Models/BaseModelBehaviour.cs
2025-05-06 12:09:11 +02:00

26 lines
491 B
C#

using System;
using Unity.VisualScripting;
using UnityEngine;
//Only one should exist at the same time
public class BaseModelBehaviour : ModelBehaviour
{
public BaseModel BaseModel
{
get
{
if (Model is BaseModel bModel)
{
return bModel;
}
throw new InvalidCastException("model needs to be of type BaseModel");
}
set
{
Model = value;
}
}
}