Show / Hide Table of Contents

Interface IMyModel

Describes 3D model (mods interface)

Namespace: VRage.Game.ModAPI
Assembly: VRage.Game.dll
Syntax
public interface IMyModel

Properties

AssetName

File path of the model

Declaration
string AssetName { get; }
Property Value
Type Description
System.String

BoneMapping

Declaration
Vector3I[] BoneMapping { get; }
Property Value
Type Description
Vector3I[]

BoundingBox

Gets bounding box

Declaration
BoundingBox BoundingBox { get; }
Property Value
Type Description
BoundingBox

BoundingBoxSize

Gets bounding box size

Declaration
Vector3 BoundingBoxSize { get; }
Property Value
Type Description
Vector3

BoundingBoxSizeHalf

Gets bounding box size

Declaration
Vector3 BoundingBoxSizeHalf { get; }
Property Value
Type Description
Vector3

BoundingSphere

Gets bounding sphere

Declaration
BoundingSphere BoundingSphere { get; }
Property Value
Type Description
BoundingSphere

DataVersion

Get version of model

Declaration
int DataVersion { get; }
Property Value
Type Description
System.Int32

PatternScale

Used in texturing of armor blocks. Default is 1

Declaration
float PatternScale { get; }
Property Value
Type Description
System.Single

ScaleFactor

Scale of model. Default 1. Greater number - bigger model

Declaration
float ScaleFactor { get; }
Property Value
Type Description
System.Single

UniqueId

Gets id of model

Declaration
int UniqueId { get; }
Property Value
Type Description
System.Int32

Methods

GetDrawTechnique(Int32)

Gets VRageRender.Import.MyMeshDrawTechnique by triangle index

Declaration
MyMeshDrawTechnique GetDrawTechnique(int triangleIndex)
Parameters
Type Name Description
System.Int32 triangleIndex

Index of triangle

Returns
Type Description
VRageRender.Import.MyMeshDrawTechnique

Draw technique

GetDummies(IDictionary<String, IMyModelDummy>)

Gets the dummies from the model

Declaration
int GetDummies(IDictionary<string, IMyModelDummy> dummies)
Parameters
Type Name Description
System.Collections.Generic.IDictionary<System.String, IMyModelDummy> dummies

Dictionary of dummies, can be null to just return count

Returns
Type Description
System.Int32

Number of dummies in model

GetTriangle(Int32)

Gets the vertex indices that complete a triangle at the index

Declaration
IMyTriangleVertexIndices GetTriangle(int triangleIndex)
Parameters
Type Name Description
System.Int32 triangleIndex

Index of triangle

Returns
Type Description
IMyTriangleVertexIndices

Struct with 3 indexes of vertices

GetTrianglesCount()

Gets amount of triangles

Declaration
int GetTrianglesCount()
Returns
Type Description
System.Int32

Amount of triangles

GetVertex(Int32)

Gets the vertex

Declaration
Vector3 GetVertex(int vertexIndex)
Parameters
Type Name Description
System.Int32 vertexIndex
Returns
Type Description
Vector3

GetVertex(Int32, Int32, Int32, out Vector3, out Vector3, out Vector3)

Gets a set of three vertices

Declaration
void GetVertex(int vertexIndex1, int vertexIndex2, int vertexIndex3, out Vector3 v1, out Vector3 v2, out Vector3 v3)
Parameters
Type Name Description
System.Int32 vertexIndex1

Vertex index 1

System.Int32 vertexIndex2

Vertex index 2

System.Int32 vertexIndex3

Vertex index 3

Vector3 v1

Vertex value at index 1

Vector3 v2

Vertex value at index 2

Vector3 v3

Vertex value at index 3

GetVerticesCount()

Gets amount of vertices

Declaration
int GetVerticesCount()
Returns
Type Description
System.Int32

Amount of vertices

☀
☾
In This Article
Back to top
Generated by DocFX
☀
☾