Question by
clayton1314 · Jul 11, 2017 at 11:21 AM ·
meshfilter
I want do a mesh filter for plant growth what do I Input, Im new to c# and coding
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class PlantGrowth : MonoBehaviour {
void Start()
{
Mesh mesh = GetComponent<MeshFilter>().sharedMesh;
Mesh mesh2 = Instantiate(mesh);
GetComponent<MeshFilter>().sharedMesh = mesh2;
}
}
Comment
Your answer
Follow this Question
Related Questions
Heatmap Color Ramp on 3D model 1 Answer
a stencil mask problem that took me over 20hr for no answer... 0 Answers
How to get the name of a model file(fbx) contained in a certain prefab with scripts? 1 Answer
Help for Kinect ar. 0 Answers
Imported model's mesh reading differently than built-in unity meshes 0 Answers