Created
August 28, 2019 09:19
-
-
Save ciwolsey/eeca96694ad5f2c5ad0c07a9426bdb4b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
interface INode{ } | |
[Serializable] | |
class RootNode : INode | |
{ | |
[SerializeReference] public INode left; | |
[SerializeReference] public INode right; | |
} | |
[Serializable] | |
class SubNode : RootNode | |
{ | |
[SerializeReference] INode parent; | |
} | |
[Serializable] | |
class LeafNode : INode | |
{ | |
[SerializeReference] public INode parent; | |
} | |
[CreateAssetMenu()] | |
class Testing : ScriptableObject | |
{ | |
[SerializeReference] | |
public List<RootNode> m_Trees; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment