|
|
@ -14,6 +14,7 @@ namespace gaemstone.Client.Systems; |
|
|
|
[Module] |
|
|
|
[Module] |
|
|
|
[DependsOn<gaemstone.Client.Systems.ImGuiManager>] |
|
|
|
[DependsOn<gaemstone.Client.Systems.ImGuiManager>] |
|
|
|
public partial class EntityInspector |
|
|
|
public partial class EntityInspector |
|
|
|
|
|
|
|
: IModuleLifetime |
|
|
|
{ |
|
|
|
{ |
|
|
|
[Tag] |
|
|
|
[Tag] |
|
|
|
public struct InspectorWindow { } |
|
|
|
public struct InspectorWindow { } |
|
|
@ -59,37 +60,30 @@ public partial class EntityInspector |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
[Path("/flecs/core/Module")] |
|
|
|
[Path("/flecs/core/Module")] |
|
|
|
// [Doc(Color = "#FFE4B2")] |
|
|
|
|
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(0), Set<Icon>(ForkAwesome.Archive)] |
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(0), Set<Icon>(ForkAwesome.Archive)] |
|
|
|
public struct Module { } |
|
|
|
public struct Module { } |
|
|
|
|
|
|
|
|
|
|
|
[Path("/flecs/system/System")] |
|
|
|
[Path("/flecs/system/System")] |
|
|
|
// [Doc(Color = "#FFB2B2")] |
|
|
|
|
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(1), Set<Icon>(ForkAwesome.Cog)] |
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(1), Set<Icon>(ForkAwesome.Cog)] |
|
|
|
public struct System { } |
|
|
|
public struct System { } |
|
|
|
|
|
|
|
|
|
|
|
[Path("/flecs/core/Observer")] |
|
|
|
[Path("/flecs/core/Observer")] |
|
|
|
// [Doc(Color = "#FFCCCC")] |
|
|
|
|
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(2), Set<Icon>(ForkAwesome.Eye)] |
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(2), Set<Icon>(ForkAwesome.Eye)] |
|
|
|
public struct Observer { } |
|
|
|
public struct Observer { } |
|
|
|
|
|
|
|
|
|
|
|
[Path("/gaemstone/Doc/Relation")] |
|
|
|
[Path("/gaemstone/Doc/Relation")] |
|
|
|
// [Doc(Color = "#B2FFCC")] |
|
|
|
|
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(3), Set<Icon>(ForkAwesome.ShareAlt)] |
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(3), Set<Icon>(ForkAwesome.ShareAlt)] |
|
|
|
public struct Relation { } |
|
|
|
public struct Relation { } |
|
|
|
|
|
|
|
|
|
|
|
[Path("/flecs/core/Component")] |
|
|
|
[Path("/flecs/core/Component")] |
|
|
|
// [Doc(Color = "#9999FF")] |
|
|
|
|
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(4), Set<Icon>(ForkAwesome.PencilSquare)] |
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(4), Set<Icon>(ForkAwesome.PencilSquare)] |
|
|
|
public struct Component { } |
|
|
|
public struct Component { } |
|
|
|
|
|
|
|
|
|
|
|
[Path("/gaemstone/Doc/Tag")] |
|
|
|
[Path("/gaemstone/Doc/Tag")] |
|
|
|
// [Doc(Color = "#B2CCFF")] |
|
|
|
|
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(5), Set<Icon>(ForkAwesome.Tag)] |
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(5), Set<Icon>(ForkAwesome.Tag)] |
|
|
|
public struct Tag { } |
|
|
|
public struct Tag { } |
|
|
|
|
|
|
|
|
|
|
|
[Path("/flecs/core/Prefab")] |
|
|
|
[Path("/flecs/core/Prefab")] |
|
|
|
// [Doc(Color = "#E4CCFF")] |
|
|
|
|
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(6), Set<Icon>(ForkAwesome.Cube)] |
|
|
|
[Add<Doc.DisplayType>, Set<Priority>(6), Set<Icon>(ForkAwesome.Cube)] |
|
|
|
public struct Prefab { } |
|
|
|
public struct Prefab { } |
|
|
|
|
|
|
|
|
|
|
@ -97,6 +91,21 @@ public partial class EntityInspector |
|
|
|
private const string DefaultWindowTitle = "Inspector Gadget"; |
|
|
|
private const string DefaultWindowTitle = "Inspector Gadget"; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public static void OnEnable<T>(Entity<T> module) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
var world = module.World; |
|
|
|
|
|
|
|
world.LookupPathOrNull("/flecs/core/Module")?.SetDocColor("#FFE4B2"); |
|
|
|
|
|
|
|
world.LookupPathOrNull("/flecs/system/System")?.SetDocColor("#FFB2B2"); |
|
|
|
|
|
|
|
world.LookupPathOrNull("/flecs/core/Observer")?.SetDocColor("#FFCCCC"); |
|
|
|
|
|
|
|
world.LookupPathOrNull("/gaemstone/Doc/Relation")?.SetDocColor("#B2FFCC"); |
|
|
|
|
|
|
|
world.LookupPathOrNull("/flecs/core/Component")?.SetDocColor("#9999FF"); |
|
|
|
|
|
|
|
world.LookupPathOrNull("/gaemstone/Doc/Tag")?.SetDocColor("#B2CCFF"); |
|
|
|
|
|
|
|
world.LookupPathOrNull("/flecs/core/Prefab")?.SetDocColor("#E4CCFF"); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public static void OnDisable<T>(Entity<T> module) { } |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
[System] |
|
|
|
[System] |
|
|
|
public static void ShowUIButton<T>(World<T> world, ImGuiData _) |
|
|
|
public static void ShowUIButton<T>(World<T> world, ImGuiData _) |
|
|
|
{ |
|
|
|
{ |
|
|
|