Legacy Documentation: Version 2018.2 (Go to current version)
LanguageEnglish
  • C#

TreeInstance

struct in UnityEngine

/

Implemented in:UnityEngine.TerrainModule

Description

Contains information about a tree placed in the Terrain game object.

This struct can be accessed from the TerrainData Object.

Properties

colorColor of this instance.
heightScaleHeight scale of this instance (compared to the prototype's size).
lightmapColorLightmap color calculated for this instance.
positionPosition of the tree.
prototypeIndexIndex of this instance in the TerrainData.treePrototypes array.
rotationRead-only.Rotation of the tree on X-Z plane (in radians).
widthScaleWidth scale of this instance (compared to the prototype's size).
对文档有任何疑问,请移步至开发者社区提问,我们将尽快为您解答