Manual     Reference     Scripting  
  
Scripting > Enumerations > PrimitiveType   
  • Menu
  • Overview
  • Runtime Classes
  • Attributes
  • Enumerations
  • Editor Classes
  • Attributes
  • Enumerations
  • History
  • Index
  • PrimitiveType
  • All Members
  • Values
  • Capsule
  • Cube
  • Cylinder
  • Plane
  • Sphere

PrimitiveType.Cylinder  

PrimitiveType.Cylinder

Description

A cylinder primitive

See Also: GameObject.CreatePrimitive

JavaScript
function Start () {
var cylinder : GameObject = GameObject.CreatePrimitive(PrimitiveType.Cylinder);
}

using UnityEngine;
using System.Collections;

public class example : MonoBehaviour {
void Start() {
GameObject cylinder = GameObject.CreatePrimitive(PrimitiveType.Cylinder);
}
}

import UnityEngine
import System.Collections

class example(MonoBehaviour):

def Start():
cylinder as GameObject = GameObject.CreatePrimitive(PrimitiveType.Cylinder)