here’s my code
using UnityEngine;
using System.Collections;
using System.Collections.Generic
public class World : MonoBehaviour {
private int size;
private byte[,,]content;
//0 nada
//1 bloco
protected Mesh mesh;
protected List<Vector3> vertices = new List<Vector3>();
protected List<int> triangles = new List<int>();
// Use this for initialization
void Start () {
content = new byte[size,size,size];
for (int x=0; x<size; x++) {
for (int z=0; z<size; z++) {
content [x,0,z] = 1;
}
}
mesh = new Mesh ();
GetComponent<MeshFilter> ().mesh = mesh;
}
// Update is called once per frame
void Update () {
}
}