C# Class Axiom.Core.PrefabFactory

A factory class that can create various mesh prefabs.
This class is used by MeshManager to offload the loading of various prefab types to a central location.
Datei anzeigen Open project: WolfgangSt/axiom

Public Methods

Method Description
Create ( Axiom.Core.Mesh mesh ) : bool

If the given mesh has a known prefab resource name (e.g "Prefab_Plane") then this prefab will be created as a submesh of the given mesh.

Private Methods

Method Description
_createCube ( Axiom.Core.Mesh mesh ) : void

Creates a 100x100x100 cube as a submesh of the given mesh

_createPlane ( Axiom.Core.Mesh mesh ) : void

Creates a plane as a submesh of the given mesh

_createSphere ( Axiom.Core.Mesh mesh ) : void

Creates a sphere with a diameter of 100 units as a submesh of the given mesh

Method Details

Create() public static method

If the given mesh has a known prefab resource name (e.g "Prefab_Plane") then this prefab will be created as a submesh of the given mesh.
public static Create ( Axiom.Core.Mesh mesh ) : bool
mesh Axiom.Core.Mesh The mesh that the potential prefab will be created in.
return bool