Files
farmer-was-replaced/sunflowers.py

18 lines
541 B
Python

from __builtins__ import *
import utils
def place(width, height):
utils.plant_grid(width, height, [Entities.Sunflower], 0.75, True)
# Harvests all sunflowers in the specified area.
#
# The rules for sunflower harvesting is that we must harvest the flowers with the most petals first
# as doing so gives us an 8x bonus.
#
# Parameters:
# width (int): The number of columns in the grid.
# height (int): The number of rows in the grid.
# flowers (list): A list of sunflower entities to be harvested.
def harvest(width, height, flowers):