Пример #1
0
    public override void OnInspectorGUI()
    {
        TileMapGen tile = (TileMapGen)target;

        if (DrawDefaultInspector())
        {
            if (tile.autoUpdate)
            {
                tile.DestroyChildren();
                tile.GenerateMap();
            }
        }
        if (GUILayout.Button("Generate"))
        {
            tile.DestroyChildren();
            tile.GenerateMap();
        }
    }
Пример #2
0
    void Start()
    {
        GenRef = GetComponent <TileMapGen>();

        print(IsSurrounded("Layer 0", new Vector3Int(0, 0, 0)));
    }
Пример #3
0
 public void OnEnable()
 {
     Gen        = (TileMapGen)target;
     labelStyle = new GUIStyle();
 }