Ejemplo n.º 1
0
    void Plant()
    {
        GrassBehaviour tile = GameMasterScript.GetGrassTile(this.transform.position);

        if (tile.GetCanBePlantedOn())
        {
            PlantGrow plant = Instantiate(GameMasterScript.GetPlant(EPlantRarity.ECommon), tile.transform.position, Quaternion.identity);
            tile.PlantOnTile(plant);
        }
    }