Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class RootSection<T, TChild> : Section<T>
- where T : Section<T>
- where TChild : Section<TChild>
- {
- public List<TChild> ChildSection { get; } // duplicate
- }
- public class MiddleSection<T, TChild, TParent> : Section<T>
- where T : Section<T>
- where TChild : Section<TChild>
- where TParent : Section<TParent>
- {
- public List<TChild> ChildSection { get; } // duplicate
- public TParent Parent { get; } // duplicate
- }
- public class BottomSection<T, TParent> : Section<T>
- where T : Section<T>
- where TParent : Section<TParent>
- {
- public TParent Parent { get; } // duplicate
- }
- public class Section<T>
- where T : Section<T>
- {
- List<T> AdjacentSections { get; }
- }
- public class Map : RootSection<Map, Biome> { } // (T, TChild)
- public class Biome : MiddleSection<Biome, Landform, Map> { } // (T, TChild, TParent)
- public class Landform : MiddleSection<Landform, Tile, Biome> { } // (T, TChild, TParent)
- public class Tile : BottomSection<Tile, Landform> { } // (T, TParent)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement