public float getHeight(float x, float y, float z)
    {
        if(x < 0 || y < 0 || z < 0 || x >= xyz[0] || y >= xyz[1] || z >= xyz[2])
        {
            return 1;
        }
        int tile = tiles[(int)x][(int)y][(int)z].type;
        switch (tile)
        {
            case 0: //empty
                return -1;
            case 1://Solid block
                return 1;
            //case 2://Floor
            //    return 0;
            default:
                return -1;
        }
                
        
    }