您最多选择25个主题 主题必须以中文或者字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

45 行
1.3 KiB

using System;
using UnityEngine;
namespace Unity.Netcode
{
internal enum NetworkPrefabOverride
{
None,
Prefab,
Hash
}
/// <summary>
/// Class that represents a NetworkPrefab
/// </summary>
[Serializable]
internal class NetworkPrefab
{
/// <summary>
/// The override setttings for this NetworkPrefab
/// </summary>
public NetworkPrefabOverride Override;
/// <summary>
/// Asset reference of the network prefab
/// </summary>
public GameObject Prefab;
/// <summary>
/// Used when prefab is selected for the source prefab to override value (i.e. direct reference, the prefab is within the same project)
/// We keep a separate value as the user might want to have something different than the default Prefab for the SourcePrefabToOverride
/// </summary>
public GameObject SourcePrefabToOverride;
/// <summary>
/// Used when hash is selected for the source prefab to override value (i.e. a direct reference is not possible such as in a multi-project pattern)
/// </summary>
public uint SourceHashToOverride;
/// <summary>
/// The prefab to replace (override) the source prefab with
/// </summary>
public GameObject OverridingTargetPrefab;
}
}