Urho.Shapes.Shape Class

Base class for the shapes in the namespace.

See Also: Shape

Syntax

public abstract class Shape : StaticModel

Remarks

You can subclass this class if you want to create your own shape.  

Shapes are components loaded from a model, and with a convenience Shape.Color property surfaced that controls the color of the shape.   The color control is implemented by using an Technique that is bundled in CoreData called Techniques/NoTextureAlpha.xml and the color is applied by setting the the MatDiffColor shader parameter.

To create your own shape, override the ModelResource property to return the path of the model.   The path should be a file that can be located in the CoreData package for your application.

Requirements

Namespace: Urho.Shapes
Assembly: Urho (in Urho.dll)
Assembly Versions: 1.0.0.0

The members of Urho.Shapes.Shape are listed below.

See Also: StaticModel

Protected Constructors

Constructs an instance of the type, for internal use. These types are created by calling Node.CreateComponent

Public Properties

ColorColor. Color for the shape.

Protected Properties

[read-only]
abstract
ModelResourceString. Returns the path of the model for this shape, for the shape to work, the MDL file in the CoreData package must exist.

Public Methods

override
OnAttachedToNode(Node)
Implements OnAttachedToNode.
override
OnCloned(Scene, Component)
override
OnDeserialize(IComponentDeserializer)
Deserialization that restores the shape from storage.
override
OnSerialize(IComponentSerializer)
Serialization that saves the shape from storage.