Rename runtime projection base for items
This commit is contained in:
parent
75d0392d43
commit
93fa34dd09
6 changed files with 15 additions and 15 deletions
|
|
@ -1,53 +0,0 @@
|
|||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
||||
|
||||
using System;
|
||||
using Unity.Mathematics;
|
||||
|
||||
public interface INamedEntry
|
||||
{
|
||||
string EntryName { get; set; }
|
||||
}
|
||||
|
||||
public abstract class RuntimeProjectionEntry
|
||||
{
|
||||
public Guid ID = Guid.NewGuid();
|
||||
|
||||
public override int GetHashCode()
|
||||
{
|
||||
return ID.GetHashCode();
|
||||
}
|
||||
|
||||
public override bool Equals(object obj)
|
||||
{
|
||||
if (obj is RuntimeProjectionEntry entry) return entry.ID == ID;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public class RuntimeItemReference
|
||||
{
|
||||
public ItemData Value { get; private set; }
|
||||
public Guid ItemId;
|
||||
|
||||
public RuntimeItemReference()
|
||||
{
|
||||
}
|
||||
|
||||
public RuntimeItemReference(ItemData value)
|
||||
{
|
||||
SetValue(value);
|
||||
}
|
||||
|
||||
public void SetValue(ItemData value)
|
||||
{
|
||||
Value = value;
|
||||
ItemId = value?.ID ?? Guid.Empty;
|
||||
}
|
||||
}
|
||||
|
||||
public interface ITintInspector
|
||||
{
|
||||
float3 TintColor { get; }
|
||||
}
|
||||
Loading…
Reference in a new issue