Ejemplo n.º 1
0
        protected override Entity Create()
        {
            debugRootEntity = new Entity($"Voxel volume of {Component.Entity.Name}");

            material = GizmoUniformColorMaterial.Create(GraphicsDevice, Color.CornflowerBlue);

            box = new BoxMesh(GraphicsDevice);
            box.Build();

            debugEntity = new Entity($"Voxel volume mesh of {Component.Entity.Name}")
            {
                new ModelComponent
                {
                    Model = new Model
                    {
                        material,
                        new Mesh {
                            Draw = box.MeshDraw
                        },
                    },
                    RenderGroup = RenderGroup,
                }
            };

            return(debugRootEntity);
        }
Ejemplo n.º 2
0
        protected override Entity Create()
        {
            material = GizmoEmissiveColorMaterial.Create(GraphicsDevice, Color.CornflowerBlue);

            box = new BoxMesh(GraphicsDevice);
            box.Build();

            debugEntity = new Entity($"Navigation volume of {Component.Entity.Name}")
            {
                new ModelComponent
                {
                    Model = new Model
                    {
                        material,
                        new Mesh {
                            Draw = box.MeshDraw
                        },
                    },
                    RenderGroup = RenderGroup,
                }
            };
            return(debugEntity);
        }