Claude Fable 5.1, seed 3
Claude Code · medium reasoning effort
Hay 22m produced, 7.34 points
Wood 298m produced, 8.47 points
Carrot 81.9m produced, 7.91 points
Pumpkin 2.93m produced, 6.47 points
Cactus 9.24m produced, 6.97 points
Power 35.1k produced, 4.54 points
Bone 4.38m produced, 6.64 points
Weird substance 34.2m produced, 7.53 points
Gold 1.23m produced, 6.09 points
Water 217k produced, 5.34 points
Fertilizer 9.72k produced, 3.99 points
Produced by the end of the run. Pips: points each resource adds to the score, one per tenfold.
- Score · economy-v1
- 71.30orders of magnitude · model mean 69.17
- On seed 3
- #3of 8 models
- Cost
- $14.14API-equivalent estimate
- Real time
- 27m 44swall clock, not scored
timeline
Score and what the agent did, over game time
Ticks under the axis: upgrade purchases.
Data table
| Game time | Score |
|---|---|
| 0s | 0.00 |
| 1h 00m | 26.1 |
| 2h 00m | 40.7 |
| 3h 00m | 49.7 |
| 4h 00m | 61.9 |
| 5h 00m | 67.2 |
| 6h 00m | 71.3 |
Said: the agent's own progress messages. Thought: its thinking as the agent reported it. Read: docs and research. Wrote: program saves. Running: which program the farm ran. Text sits at the game time it was written; the game is paused while the agent thinks. Dots open the step in the log below.
how-it-played
How it played
| Measure | This run | Model mean | Seed 3 mean |
|---|---|---|---|
| Resources opened | 11 of 11 | 11 of 11 | 9.9 of 11 |
| Study | 65 | 60 | 41 |
| Action overhead | 12% | 11% | 9% |
| Tool calls | 261 | 244 | 198 |
| Program writes | 29 | 29 | 29 |
| Program stints | 30 | 29 | 35 |
| Median stint | 5m 00s | 4m 39s | 8m 48s |
| Cost per point | $0.198 | $0.209 | $0.069 |
Farm idle 3% of samples; longest stint 1h 29m; 1 rejected write.
production
Production and holdings
Each resource on its own scale. Ticks: purchases of the upgrade that feeds it. On the log scale each tenfold rise is one point.
upgrades
Upgrade timeline
Every purchase, with what the agent was told
| Game time | Call | Unlocked | Result the agent saw |
|---|---|---|---|
| 1m 50s | {"upgrades":["loops","speed"]} | loops 1, speed 1 | Bought loops, now level 1. Paid hay 5. Its tutorial is docs page docs/scripting/while.md. |
| 13m 34s | {"upgrades":["expand","plant"]} | expand 1, plant 1 | Bought expand, now level 1. Paid hay 30. Its tutorial is docs page docs/unlocks/expand_1.md. |
| 16m 44s | {"upgrades":["expand","operators"]} | expand 2, operators 1 | Bought expand, now level 2. Paid wood 20. Its tutorial is docs page docs/unlocks/expand_1.md. |
| 19m 24s | {"upgrades":["carrots"]} | carrots 1 | Bought carrots, now level 1. Paid wood 50. Its tutorial is docs page docs/unlocks/carrots.md. |
| 20m 24s | {"upgrades":["senses"]} | senses 1 | Bought senses, now level 1. Paid hay 100. Its tutorial is docs page docs/unlocks/senses.md. |
| 22m 44s | {"upgrades":["variables","watering"]} | variables 1, watering 1 | Bought variables, now level 1. Paid carrot 35. Its tutorial is docs page docs/scripting/variables.md. |
| 23m 44s | {"upgrades":["functions"]} | functions 1, functions 1 | Bought functions, now level 1. Paid carrot 40. Its tutorial is docs page docs/scripting/functions.md. |
| 25m 26s | {"upgrades":["speed","trees"]} | speed 2, trees 1 | Bought speed, now level 2. Paid wood 20. Its tutorial is docs page docs/unlocks/speed.md. |
| 26m 26s | {"upgrades":["expand"]} | expand 3 | Bought expand, now level 3. Paid wood 30, carrot 20. Its tutorial is docs page docs/unlocks/expand_1.md. |
| 29m 06s | {"upgrades":["import","carrots"]} | import 1, carrots 2 | Bought import, now level 1. Paid carrot 80. Its tutorial is docs page docs/scripting/import.md. |
| 30m 00s | {"upgrades":["pumpkins"]} | pumpkins 1 | Bought pumpkins, now level 1. Paid wood 500, carrot 200. Its tutorial is docs page docs/unlocks/pumpkins.md. |
| 30m 50s | {"upgrades":["expand","speed"]} | expand 4, speed 3 | Bought expand, now level 4. Paid wood 100, carrot 50. Its tutorial is docs page docs/unlocks/expand_1.md. |
| 35m 50s | {"upgrades":["fertilizer"]} | fertilizer 1 | Bought fertilizer, now level 1. Paid wood 500. Its tutorial is docs page docs/unlocks/fertilizer.md. |
| 40m 30s | {"upgrades":["watering"]} | watering 2 | Bought watering, now level 2. Paid wood 200. Its tutorial is docs page docs/unlocks/watering.md. |
| 40m 40s | {"upgrades":["grass","debug","speed"]} | grass 2 | Bought grass, now level 2. Paid hay 300. |
| 41m 00s | {"upgrades":["expand","grass"]} | expand 5, grass 3 | Bought expand, now level 5. Paid pumpkin 1000. Its tutorial is docs page docs/unlocks/expand_1.md. |
| 46m 40s | {"upgrades":["carrots","fertilizer"]} | carrots 3, fertilizer 2 | Bought carrots, now level 3. Paid wood 1250. Its tutorial is docs page docs/unlocks/carrots.md. |
| 47m 37s | {"upgrades":["speed","trees"]} | speed 4, trees 2 | Bought speed, now level 4. Paid carrot 500. Its tutorial is docs page docs/unlocks/speed.md. |
| 47m 47s | {"upgrades":["debug"]} | debug 1 | Bought debug, now level 1. Paid hay 50, wood 50. Its tutorial is docs page docs/scripting/debug.md. |
| 50m 40s | {"upgrades":["sunflowers","watering"]} | sunflowers 1, watering 3 | Bought sunflowers, now level 1. Paid carrot 500. Its tutorial is docs page docs/unlocks/sunflowers.md. |
| 51m 20s | {"upgrades":["grass"]} | grass 4 | Bought grass, now level 4. Paid wood 2500. |
| 54m 20s | {"upgrades":["lists","watering"]} | lists 1, watering 4 | Bought lists, now level 1. Paid carrot 500. Its tutorial is docs page docs/scripting/lists.md. |
| 1h 00m | {"upgrades":["mazes","timing","utilities"]} | mazes 1, timing 1, utilities 1 | Bought mazes, now level 1. Paid weird_substance 1000. Its tutorial is docs page docs/unlocks/mazes.md. |
| 1h 03m | {"upgrades":["megafarm"]} | megafarm 1 | Bought megafarm, now level 1. Paid gold 2000. Its tutorial is docs page docs/unlocks/megafarm.md. |
| 1h 11m | {"upgrades":["carrots"]} | carrots 4 | Bought carrots, now level 4. Paid wood 6250. Its tutorial is docs page docs/unlocks/carrots.md. |
| 1h 19m | {"upgrades":["expand"]} | expand 6 | Bought expand, now level 6. Paid pumpkin 8000. Its tutorial is docs page docs/unlocks/expand_1.md. |
| 1h 25m | {"upgrades":["polyculture"]} | polyculture 1 | Bought polyculture, now level 1. Paid pumpkin 3000. Its tutorial is docs page docs/unlocks/polyculture.md. |
| 1h 26m | {"upgrades":["megafarm"]} | megafarm 2 | Bought megafarm, now level 2. Paid gold 8000. Its tutorial is docs page docs/unlocks/megafarm.md. |
| 1h 31m | {"upgrades":["speed","pumpkins"]} | speed 5, pumpkins 2 | Bought speed, now level 5. Paid carrot 1000. Its tutorial is docs page docs/unlocks/speed.md. |
| 1h 42m | {"upgrades":["trees"]} | trees 3 | Bought trees, now level 3. Paid hay 1200. Its tutorial is docs page docs/unlocks/trees.md. |
| 1h 53m | {"upgrades":["megafarm","cactus","dictionaries","grass"]} | megafarm 3, cactus 1, dictionaries 1, grass 5 | Bought megafarm, now level 3. Paid gold 32000. Its tutorial is docs page docs/unlocks/megafarm.md. |
| 1h 58m | {"upgrades":["dinosaurs","mazes"]} | dinosaurs 1, hats 1, mazes 2 | Bought dinosaurs, now level 1. Paid cactus 2000. Its tutorial is docs page docs/unlocks/dinosaurs.md. |
| 1h 58m | {"upgrades":["hats"]} | — | Could not buy hats: Already at maximum level. |
| 2h 04m | {"upgrades":["polyculture"]} | polyculture 2 | Bought polyculture, now level 2. Paid bone 10000. Its tutorial is docs page docs/unlocks/polyculture.md. |
| 2h 10m | {"upgrades":["dinosaurs"]} | dinosaurs 2, hats 1 | Bought dinosaurs, now level 2. Paid cactus 12000. Its tutorial is docs page docs/unlocks/dinosaurs.md. |
| 2h 20m | {"upgrades":["trees"]} | — | Could not buy trees: Not enough resources. |
| 2h 41m | {"upgrades":["trees","dinosaurs","mazes","polyculture"]} | trees 4, dinosaurs 3, hats 1, mazes 3, polyculture 3 | Bought trees, now level 4. Paid hay 4800. Its tutorial is docs page docs/unlocks/trees.md. |
| 3h 08m | {"upgrades":["pumpkins","carrots","grass","fertilizer","watering","trees","polyculture","megafarm"]} | pumpkins 3, carrots 5, grass 6, fertilizer 3, watering 5, trees 5 | Bought pumpkins, now level 3. Paid carrot 4000. Its tutorial is docs page docs/unlocks/pumpkins.md. |
| 3h 09m | {"upgrades":["pumpkins","watering"]} | pumpkins 4, watering 6 | Bought pumpkins, now level 4. Paid carrot 16000. Its tutorial is docs page docs/unlocks/pumpkins.md. |
| 3h 19m | {"upgrades":["megafarm","polyculture","carrots","grass","trees","pumpkins","cactus","fertilizer","watering"]} | megafarm 4, polyculture 4, carrots 6, grass 7, trees 6, pumpkins 5, cactus 2, fertilizer 4, watering 7 | Bought megafarm, now level 4. Paid gold 128000. Its tutorial is docs page docs/unlocks/megafarm.md. |
| 3h 29m | {"upgrades":["carrots","pumpkins","grass","watering"]} | carrots 7, pumpkins 6, watering 8 | Bought carrots, now level 7. Paid wood 781000. Its tutorial is docs page docs/unlocks/carrots.md. |
| 3h 32m | {"upgrades":["expand"]} | expand 7 | Bought expand, now level 7. Paid pumpkin 64000. Its tutorial is docs page docs/unlocks/expand_1.md. |
| 3h 42m | {"upgrades":["grass","trees","pumpkins"]} | grass 8, trees 7, pumpkins 7 | Bought grass, now level 8. Paid wood 1560000. |
| 3h 53m | {"upgrades":["cactus","dinosaurs","carrots"]} | cactus 3, dinosaurs 4, hats 1, carrots 8 | Bought cactus, now level 3. Paid pumpkin 120000. Its tutorial is docs page docs/unlocks/cactus.md. |
| 4h 03m | {"upgrades":["pumpkins","trees","watering","polyculture","mazes"]} | pumpkins 8, trees 8, watering 9 | Bought pumpkins, now level 8. Paid carrot 4100000. Its tutorial is docs page docs/unlocks/pumpkins.md. |
| 4h 13m | {"upgrades":["polyculture","mazes","grass"]} | polyculture 5, mazes 4, grass 9 | Bought polyculture, now level 5. Paid bone 1250000. Its tutorial is docs page docs/unlocks/polyculture.md. |
| 4h 24m | {"upgrades":["carrots","cactus"]} | — | Could not buy carrots: Not enough resources. |
| 4h 34m | {"upgrades":["carrots"]} | carrots 9 | Bought carrots, now level 9. Paid wood 19500000. Its tutorial is docs page docs/unlocks/carrots.md. |
| 4h 41m | {"upgrades":["expand"]} | expand 8 | Bought expand, now level 8. Paid pumpkin 512000. Its tutorial is docs page docs/unlocks/expand_1.md. |
| 4h 51m | {"upgrades":["pumpkins","trees"]} | pumpkins 9, trees 9 | Bought pumpkins, now level 9. Paid carrot 16400000. Its tutorial is docs page docs/unlocks/pumpkins.md. |
| 5h 12m | {"upgrades":["grass"]} | grass 10 | Bought grass, now level 10. Paid wood 39100000. |
| 5h 28m | {"upgrades":["cactus","megafarm"]} | cactus 4, megafarm 5 | Bought cactus, now level 4. Paid pumpkin 720000. Its tutorial is docs page docs/unlocks/cactus.md. |
| 5h 43m | {"upgrades":["carrots","mazes"]} | carrots 10, mazes 5 | Bought carrots, now level 10. Paid wood 97700000. Its tutorial is docs page docs/unlocks/carrots.md. |
Programs 30 writes, code as the agent wrote it
h0.py
r11m 10sRanFinal
harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest()- Write result the agent saw
Saved h0 (40 lines). Game time: 1m 20s elapsed, 5h 58m 40s of budget remaining.
- run_program at 1m 20s for 60s (agent saw)
Ran h0 for 20s of game time; it finished. Inventory change: hay +40. Game time: 1m 50s elapsed, 5h 58m 10s of budget remaining. Output: (none)
loop.py
r12m 00sRan
while True: harvest()- Write result the agent saw
Saved loop (2 lines). Game time: 2m 10s elapsed, 5h 57m 50s of budget remaining.
- run_program at 2m 10s for 40s (agent saw)
Ran loop for 40s of game time; it is still running. Inventory change: hay +1. Game time: 3m elapsed, 5h 57m of budget remaining. Output: (none)
- run_program at 9m 00s for 30s (agent saw)
Ran loop for 30s of game time; it is still running. Inventory change: hay +1. Game time: 9m 40s elapsed, 5h 50m 20s of budget remaining. Output: (none)
r212m 14sRan
while True: if can_harvest(): harvest()Changes from the previous revision
while True: - harvest() + if can_harvest(): + harvest()
- Write result the agent saw
Saved loop (3 lines). Game time: 12m 24s elapsed, 5h 47m 36s of budget remaining.
- run_program at 12m 24s for 60s (agent saw)
Ran loop for 1m of game time; it is still running. Inventory change: hay +120. Game time: 13m 34s elapsed, 5h 46m 26s of budget remaining. Output: (none)
h1.py
r19m 50sRanFinal
harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest() harvest()- Write result the agent saw
Saved h1 (313 lines). Game time: 10m elapsed, 5h 50m of budget remaining.
- run_program at 10m 00s for 200s (agent saw)
Ran h1 for 1m 44s of game time; it finished. Inventory change: no change. Game time: 11m 54s elapsed, 5h 48m 6s of budget remaining. Output: (none)
bush.py
r114m 44sRan
while True: if can_harvest(): harvest() plant(Entities.Bush) move(North)- Write result the agent saw
Saved bush (5 lines). Game time: 14m 54s elapsed, 5h 45m 6s of budget remaining.
- run_program at 14m 54s for 90s (agent saw)
Ran bush for 1m 30s of game time; it is still running. Inventory change: hay +7, wood +53. Game time: 16m 34s elapsed, 5h 43m 26s of budget remaining. Output: (none)
bush3.py
r117m 04sRan
while True: if can_harvest(): harvest() move(North) if can_harvest(): harvest() plant(Entities.Bush) move(North) if can_harvest(): harvest() plant(Entities.Bush) move(North) move(East) if can_harvest(): harvest() plant(Entities.Bush) move(North) if can_harvest(): harvest() plant(Entities.Bush) move(North) if can_harvest(): harvest() plant(Entities.Bush) move(North) move(East) if can_harvest(): harvest() plant(Entities.Bush) move(North) if can_harvest(): harvest() plant(Entities.Bush) move(North) if can_harvest(): harvest() plant(Entities.Bush) move(North) move(East)- Write result the agent saw
Saved bush3 (39 lines). Game time: 17m 14s elapsed, 5h 42m 46s of budget remaining.
- run_program at 17m 14s for 120s (agent saw)
Ran bush3 for 2m of game time; it is still running. Inventory change: hay +37, wood +106. Game time: 19m 24s elapsed, 5h 40m 36s of budget remaining. Output: (none)
farm3.py
r120m 54sRan
while True: if get_pos_x() == 2: if get_ground_type() != Grounds.Soil: till() if can_harvest(): harvest() if get_entity_type() != Entities.Carrot: plant(Entities.Carrot) if get_pos_x() == 1: if can_harvest(): harvest() if get_entity_type() != Entities.Bush: plant(Entities.Bush) if get_pos_x() == 0: if can_harvest(): harvest() move(North) if get_pos_y() == 0: move(East)- Write result the agent saw
Saved farm3 (19 lines). Game time: 21m 4s elapsed, 5h 38m 56s of budget remaining.
- run_program at 21m 04s for 90s (agent saw)
Ran farm3 for 1m 30s of game time; it is still running. Inventory change: carrot +39, hay +46, wood +16. Game time: 22m 44s elapsed, 5h 37m 16s of budget remaining. Output: (none)
farm.py
r126m 36sRan
def work(): x = get_pos_x() y = get_pos_y() want = Entities.Tree if (x + y) % 2 == 1: want = Entities.Carrot if x == 0: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass and get_entity_type() != want: plant(want) if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) while True: work() move(North) if get_pos_y() == 0: move(East)- Write result the agent saw
Saved farm (26 lines). Game time: 26m 46s elapsed, 5h 33m 14s of budget remaining.
- run_program at 26m 46s for 120s (agent saw)
Ran farm for 2m of game time; it is still running. Inventory change: carrot +129, hay -10, water -24, wood +529. Game time: 28m 56s elapsed, 5h 31m 4s of budget remaining. Output: (none)
—31m 20sRejected
def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) def mixed_tile(): x = get_pos_x() y = get_pos_y() want = Entities.Tree if (x + y) % 2 == 1: want = Entities.Carrot if x == 0: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def mixed_sweep(): n = get_world_size() for i in range(n): for j in range(n): mixed_tile() move(North) move(East) def pump_round(): n = get_world_size() done = False while not done: done = True for i in range(n): for j in range(n): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) done = False else: if not can_harvest(): done = False water() move(North) move(East) if num_items(Items.Carrot) < 2: return harvest() while True: if num_items(Items.Carrot) >= 120: pump_round() else: mixed_sweep()- Write result the agent saw
Stop the program before editing it.
r231m 40sRan
def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) def mixed_tile(): x = get_pos_x() y = get_pos_y() want = Entities.Tree if (x + y) % 2 == 1: want = Entities.Carrot if x == 0: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def mixed_sweep(): n = get_world_size() for i in range(n): for j in range(n): mixed_tile() move(North) move(East) def pump_round(): n = get_world_size() done = False while not done: done = True for i in range(n): for j in range(n): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) done = False else: if not can_harvest(): done = False water() move(North) move(East) if num_items(Items.Carrot) < 2: return harvest() while True: if num_items(Items.Carrot) >= 120: pump_round() else: mixed_sweep()Changes from the previous revision
- def work(): + def water(): + if get_water() < 0.5 and num_items(Items.Water) > 0: + use_item(Items.Water) + + def ensure(want): + e = get_entity_type() + if e == want: + return + if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: + harvest() + plant(want) + + def mixed_tile(): x = get_pos_x() y = get_pos_y() if can_harvest(): harvest() - if want != Entities.Grass and get_entity_type() != want: - plant(want) - if get_water() < 0.5 and num_items(Items.Water) > 0: - use_item(Items.Water) + if want != Entities.Grass: + ensure(want) + water() - while True: - work() - move(North) - if get_pos_y() == 0: + def mixed_sweep(): + n = get_world_size() + for i in range(n): + for j in range(n): + mixed_tile() + move(North) move(East) + + def pump_round(): + n = get_world_size() + done = False + while not done: + done = True + for i in range(n): + for j in range(n): + if get_ground_type() != Grounds.Soil: + till() + e = get_entity_type() + if e != Entities.Pumpkin: + ensure(Entities.Pumpkin) + done = False + else: + if not can_harvest(): + done = False + water() + move(North) + move(East) + if num_items(Items.Carrot) < 2: + return + harvest() + + while True: + if num_items(Items.Carrot) >= 120: + pump_round() + else: + mixed_sweep()
- Write result the agent saw
Saved farm (68 lines). Game time: 31m 50s elapsed, 5h 28m 10s of budget remaining.
- run_program at 31m 50s for 180s (agent saw)
Ran farm for 3m of game time; it is still running. Inventory change: carrot -40, hay -55, pumpkin +864, water -2, wood +68. Game time: 35m elapsed, 5h 25m of budget remaining. Output: (none)
r336m 10sRan
def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < 300: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def mixed_sweep(): n = get_world_size() for i in range(n): for j in range(n): mixed_tile() move(North) move(East) def pump_round(): n = get_world_size() done = False while not done: done = True for i in range(n): for j in range(n): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) done = False else: if not can_harvest(): done = False water() move(North) move(East) if num_items(Items.Carrot) < 2: return harvest() while True: if num_items(Items.Carrot) >= 120: pump_round() else: mixed_sweep()Changes from the previous revision
use_item(Items.Water) + def fert(): + if num_items(Items.Fertilizer) > 0: + use_item(Items.Fertilizer) + def ensure(want): e = get_entity_type() harvest() plant(want) + fert() def mixed_tile(): x = get_pos_x() y = get_pos_y() + e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: + if e == Entities.Carrot and not can_harvest(): + water() + return want = Entities.Carrot - if x == 0: + if num_items(Items.Hay) < 300: want = Entities.Grass if want == Entities.Carrot:
- Write result the agent saw
Saved farm (77 lines). Game time: 36m 20s elapsed, 5h 23m 40s of budget remaining.
- run_program at 36m 20s for 240s (agent saw)
Ran farm for 4m of game time; it is still running. Inventory change: carrot -90, fertilizer -2, hay +298, pumpkin +627, water -4, weird_substance +93, wood +1428. Game time: 40m 30s elapsed, 5h 19m 30s of budget remaining. Output: (none)
r441m 20sRan
PUMP_AT = 600 HAY_AT = 400 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def mixed_sweep(): n = get_world_size() for i in range(n): for j in range(n): mixed_tile() move(North) move(East) def pump_round(): n = get_world_size() done = False while not done: done = True for i in range(n): for j in range(n): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) done = False else: if not can_harvest(): done = False water() move(North) move(East) if num_items(Items.Carrot) < 2: return harvest() while True: if num_items(Items.Carrot) >= PUMP_AT: pump_round() else: mixed_sweep()Changes from the previous revision
+ PUMP_AT = 600 + HAY_AT = 400 + def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: return want = Entities.Carrot - if num_items(Items.Hay) < 300: + if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: while True: - if num_items(Items.Carrot) >= 120: + if num_items(Items.Carrot) >= PUMP_AT: pump_round() else:
- Write result the agent saw
Saved farm (80 lines). Game time: 41m 30s elapsed, 5h 18m 30s of budget remaining.
- run_program at 41m 30s for 300s (agent saw)
Ran farm for 5m of game time; it is still running. Inventory change: carrot +293, fertilizer -2, hay +210, water -4, weird_substance +71, wood +2473. Game time: 46m 40s elapsed, 5h 13m 20s of budget remaining. Output: (none)
r551m 40sRan
PUMP_AT = 600 HAY_AT = 400 SUN_AT = 200 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def mixed_sweep(): n = get_world_size() for i in range(n): for j in range(n): mixed_tile() move(North) move(East) def pump_round(): n = get_world_size() done = False while not done: done = True for i in range(n): for j in range(n): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) done = False else: if not can_harvest(): done = False water() move(North) move(East) if num_items(Items.Carrot) < 2: return harvest() def sun_round(): n = get_world_size() for i in range(n): for j in range(n): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() move(North) move(East) remaining = n * n while remaining > 10: best = 0 for i in range(n): for j in range(n): if get_entity_type() == Entities.Sunflower: m = measure() if m > best: best = m move(North) move(East) for i in range(n): for j in range(n): if remaining > 10 and get_entity_type() == Entities.Sunflower: if measure() == best: if can_harvest(): harvest() remaining -= 1 water() move(North) move(East) while True: if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: mixed_sweep()Changes from the previous revision
PUMP_AT = 600 HAY_AT = 400 + SUN_AT = 200 def water(): harvest() + def sun_round(): + n = get_world_size() + for i in range(n): + for j in range(n): + if get_ground_type() != Grounds.Soil: + till() + ensure(Entities.Sunflower) + water() + move(North) + move(East) + remaining = n * n + while remaining > 10: + best = 0 + for i in range(n): + for j in range(n): + if get_entity_type() == Entities.Sunflower: + m = measure() + if m > best: + best = m + move(North) + move(East) + for i in range(n): + for j in range(n): + if remaining > 10 and get_entity_type() == Entities.Sunflower: + if measure() == best: + if can_harvest(): + harvest() + remaining -= 1 + water() + move(North) + move(East) + while True: - if num_items(Items.Carrot) >= PUMP_AT: + if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: + sun_round() + elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else:
- Write result the agent saw
Saved farm (115 lines). Game time: 51m 50s elapsed, 5h 8m 10s of budget remaining.
- run_program at 51m 50s for 120s (agent saw)
Ran farm for 2m of game time; it is still running. Inventory change: carrot +98, fertilizer -4, power +348.81, water -8, weird_substance +171, wood +929. Game time: 54m elapsed, 5h 6m of budget remaining. Output: (none)
r654m 50sRan
PUMP_AT = 250 HAY_AT = 400 SUN_AT = 200 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def mixed_sweep(): n = get_world_size() for i in range(n): for j in range(n): mixed_tile() move(North) move(East) def pump_round(): n = get_world_size() done = False while not done: done = True for i in range(n): for j in range(n): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) done = False else: if not can_harvest(): done = False water() move(North) move(East) if num_items(Items.Carrot) < 2: return harvest() def sun_round(): n = get_world_size() for i in range(n): for j in range(n): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() move(North) move(East) remaining = n * n while remaining > 10: best = 0 for i in range(n): for j in range(n): if get_entity_type() == Entities.Sunflower: m = measure() if m > best: best = m move(North) move(East) for i in range(n): for j in range(n): if remaining > 10 and get_entity_type() == Entities.Sunflower: if measure() == best: if can_harvest(): harvest() remaining -= 1 water() move(North) move(East) while True: if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: mixed_sweep()Changes from the previous revision
- PUMP_AT = 600 + PUMP_AT = 250 HAY_AT = 400 SUN_AT = 200
- Write result the agent saw
Saved farm (115 lines). Game time: 55m elapsed, 5h 5m of budget remaining.
- run_program at 55m 00s for 300s (agent saw)
Ran farm for 5m of game time; it is still running. Inventory change: carrot +134, fertilizer -4, hay +28, power +218.54, pumpkin +2244, water -16, weird_substance +330, wood +2834. Game time: 1h 10s elapsed, 4h 59m 50s of budget remaining. Output: (none)
r71h 01mRan
PUMP_AT = 250 HAY_AT = 400 SUN_AT = 200 GOLD_AT = 2000 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def mixed_sweep(): n = get_world_size() for i in range(n): for j in range(n): mixed_tile() move(North) move(East) def pump_round(): n = get_world_size() done = False while not done: done = True for i in range(n): for j in range(n): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) done = False else: if not can_harvest(): done = False water() move(North) move(East) if num_items(Items.Carrot) < 2: return harvest() def sun_round(): n = get_world_size() for i in range(n): for j in range(n): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() move(North) move(East) remaining = n * n while remaining > 10: best = 0 for i in range(n): for j in range(n): if get_entity_type() == Entities.Sunflower: m = measure() if m > best: best = m move(North) move(East) for i in range(n): for j in range(n): if remaining > 10 and get_entity_type() == Entities.Sunflower: if measure() == best: if can_harvest(): harvest() remaining -= 1 water() move(North) move(East) def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 2000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False while True: if num_items(Items.Gold) < GOLD_AT and num_items(Items.Weird_Substance) >= 64: while num_items(Items.Weird_Substance) >= 16 and num_items(Items.Gold) < GOLD_AT: if not maze_round(): break elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: mixed_sweep()Changes from the previous revision
HAY_AT = 400 SUN_AT = 200 + GOLD_AT = 2000 def water(): move(East) + def maze_round(): + n = get_world_size() + amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) + if num_items(Items.Weird_Substance) < amount: + return False + if get_entity_type() != Entities.Bush: + if get_entity_type() != None: + harvest() + plant(Entities.Bush) + use_item(Items.Weird_Substance, amount) + dirs = [North, East, South, West] + d = 0 + steps = 0 + while get_entity_type() != Entities.Treasure and steps < 2000: + steps += 1 + r = (d + 1) % 4 + l = (d + 3) % 4 + if can_move(dirs[r]): + d = r + move(dirs[d]) + elif can_move(dirs[d]): + move(dirs[d]) + elif can_move(dirs[l]): + d = l + move(dirs[d]) + else: + d = (d + 2) % 4 + move(dirs[d]) + if get_entity_type() == Entities.Treasure: + harvest() + return True + harvest() + return False + while True: - if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: + if num_items(Items.Gold) < GOLD_AT and num_items(Items.Weird_Substance) >= 64: + while num_items(Items.Weird_Substance) >= 16 and num_items(Items.Gold) < GOLD_AT: + if not maze_round(): + break + elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Carrot) >= PUMP_AT:
- Write result the agent saw
Saved farm (154 lines). Game time: 1h 1m 10s elapsed, 4h 58m 50s of budget remaining.
- run_program at 1h 01m for 90s (agent saw)
Ran farm for 1m 30s of game time; it is still running. Inventory change: carrot +220, fertilizer -2, gold +1216, hay +328, power -60.68, water -10, weird_substance -13, wood +327. Game time: 1h 2m 50s elapsed, 4h 57m 10s of budget remaining. Output: (none)
r81h 04mRan
PUMP_AT = 250 HAY_AT = 400 SUN_AT = 200 GOLD_AT = 8000 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def goto(x, y): while get_pos_x() != x: move(East) while get_pos_y() != y: move(North) def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 2000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False while True: if num_items(Items.Gold) < GOLD_AT and num_items(Items.Weird_Substance) >= 64: while num_items(Items.Weird_Substance) >= 16 and num_items(Items.Gold) < GOLD_AT: if not maze_round(): break elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0)Changes from the previous revision
HAY_AT = 400 SUN_AT = 200 - GOLD_AT = 2000 + GOLD_AT = 8000 def water(): fert() + def goto(x, y): + while get_pos_x() != x: + move(East) + while get_pos_y() != y: + move(North) + def mixed_tile(): x = get_pos_x() water() - def mixed_sweep(): + def pump_tile(): + if get_ground_type() != Grounds.Soil: + till() + e = get_entity_type() + if e != Entities.Pumpkin: + ensure(Entities.Pumpkin) + water() + return False + water() + return can_harvest() + + def sun_plant_tile(): + if get_ground_type() != Grounds.Soil: + till() + ensure(Entities.Sunflower) + water() + if get_entity_type() == Entities.Sunflower: + return measure() + return 0 + + def worker(mode, k, D, best, cap): n = get_world_size() - for i in range(n): + if mode == 1: + done = False + while not done: + done = True + x = k + while x < n: + goto(x, 0) + for j in range(n): + if not pump_tile(): + done = False + move(North) + x += D + if num_items(Items.Carrot) < 2: + return 0 + return 0 + res = 0 + newbest = 0 + x = k + while x < n: + goto(x, 0) for j in range(n): - mixed_tile() + if mode == 0: + mixed_tile() + elif mode == 2: + m = sun_plant_tile() + if m != None and m > res: + res = m + elif mode == 3: + if get_entity_type() == Entities.Sunflower: + m = measure() + if m == best and res < cap and can_harvest(): + harvest() + res += 1 + else: + if m > newbest: + newbest = m + water() move(North) - move(East) + x += D + if mode == 3: + return [res, newbest] + return res + def run_all(mode, best, cap): + D = max_drones() + handles = [] + failed = [] + for k in range(1, D): + h = spawn_drone(worker, mode, k, D, best, cap) + if h == None: + failed.append(k) + else: + handles.append(h) + results = [worker(mode, 0, D, best, cap)] + for k in failed: + results.append(worker(mode, k, D, best, cap)) + for h in handles: + results.append(wait_for(h)) + return results + def pump_round(): - n = get_world_size() - done = False - while not done: - done = True - for i in range(n): - for j in range(n): - if get_ground_type() != Grounds.Soil: - till() - e = get_entity_type() - if e != Entities.Pumpkin: - ensure(Entities.Pumpkin) - done = False - else: - if not can_harvest(): - done = False - water() - move(North) - move(East) - if num_items(Items.Carrot) < 2: - return - harvest() + run_all(1, 0, 0) + if get_entity_type() == Entities.Pumpkin and can_harvest(): + harvest() def sun_round(): n = get_world_size() - for i in range(n): - for j in range(n): - if get_ground_type() != Grounds.Soil: - till() - ensure(Entities.Sunflower) - water() - move(North) - move(East) + rs = run_all(2, 0, 0) + best = 0 + for r in rs: + best = max(best, r) remaining = n * n - while remaining > 10: - best = 0 - for i in range(n): - for j in range(n): - if get_entity_type() == Entities.Sunflower: - m = measure() - if m > best: - best = m - move(North) - move(East) - for i in range(n): - for j in range(n): - if remaining > 10 and get_entity_type() == Entities.Sunflower: - if measure() == best: - if can_harvest(): - harvest() - remaining -= 1 - water() - move(North) - move(East) + while remaining > 10 and best > 0: + cap = (remaining - 10) // max_drones() + 1 + rs = run_all(3, best, cap) + h = 0 + nb = 0 + for r in rs: + h += r[0] + nb = max(nb, r[1]) + remaining -= h + if h == 0 and nb == 0: + break + best = nb def maze_round(): pump_round() else: - mixed_sweep() + run_all(0, 0, 0)
- Write result the agent saw
Saved farm (204 lines). Game time: 1h 4m 24s elapsed, 4h 55m 36s of budget remaining.
- run_program at 1h 04m for 180s (agent saw)
Ran farm for 3m of game time; it is still running. Inventory change: fertilizer +36, power -242.86, water +144. Game time: 1h 7m 34s elapsed, 4h 52m 26s of budget remaining. Output: (none)
r91h 08mRan
PUMP_AT = 250 HAY_AT = 400 SUN_AT = 200 GOLD_AT = 8000 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def goto(x, y): while get_pos_x() != x: if not move(East): harvest() while get_pos_y() != y: if not move(North): harvest() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() elif num_items(Items.Gold) < GOLD_AT and num_items(Items.Weird_Substance) >= 64: while num_items(Items.Weird_Substance) >= 16 and num_items(Items.Gold) < GOLD_AT: if not maze_round(): break elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0)Changes from the previous revision
def goto(x, y): while get_pos_x() != x: - move(East) + if not move(East): + harvest() while get_pos_y() != y: - move(North) + if not move(North): + harvest() def mixed_tile(): best = nb - def maze_round(): - n = get_world_size() - amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) - if num_items(Items.Weird_Substance) < amount: - return False - if get_entity_type() != Entities.Bush: - if get_entity_type() != None: - harvest() - plant(Entities.Bush) - use_item(Items.Weird_Substance, amount) + def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 - while get_entity_type() != Entities.Treasure and steps < 2000: + while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 return False + def maze_round(): + n = get_world_size() + amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) + if num_items(Items.Weird_Substance) < amount: + return False + if get_entity_type() != Entities.Bush: + if get_entity_type() != None: + harvest() + plant(Entities.Bush) + use_item(Items.Weird_Substance, amount) + return solve_maze() + while True: - if num_items(Items.Gold) < GOLD_AT and num_items(Items.Weird_Substance) >= 64: + e = get_entity_type() + if e == Entities.Hedge or e == Entities.Treasure: + solve_maze() + elif num_items(Items.Gold) < GOLD_AT and num_items(Items.Weird_Substance) >= 64: while num_items(Items.Weird_Substance) >= 16 and num_items(Items.Gold) < GOLD_AT: if not maze_round():
- Write result the agent saw
Saved farm (212 lines). Game time: 1h 8m 14s elapsed, 4h 51m 46s of budget remaining.
- run_program at 1h 08m for 180s (agent saw)
Ran farm for 3m of game time; it is still running. Inventory change: carrot +116, fertilizer -48, gold +2176, hay +192, power +94.04, water -176, weird_substance +107, wood +249. Game time: 1h 11m 24s elapsed, 4h 48m 36s of budget remaining. Output: (none)
r101h 26mRan
PUMP_AT = 1200 HAY_AT = 400 SUN_AT = 200 GOLD_AT = 40000 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def goto(x, y): while get_pos_x() != x: if not move(East): harvest() while get_pos_y() != y: if not move(North): harvest() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() elif num_items(Items.Gold) < GOLD_AT and num_items(Items.Weird_Substance) >= 64: while num_items(Items.Weird_Substance) >= 16 and num_items(Items.Gold) < GOLD_AT: if not maze_round(): break elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0)Changes from the previous revision
- PUMP_AT = 250 + PUMP_AT = 1200 HAY_AT = 400 SUN_AT = 200 - GOLD_AT = 8000 + GOLD_AT = 40000 def water():
- Write result the agent saw
Saved farm (212 lines). Game time: 1h 26m 41s elapsed, 4h 33m 19s of budget remaining.
- run_program at 1h 26m for 300s (agent saw)
Ran farm for 5m of game time; it is still running. Inventory change: carrot +1856, fertilizer +15, gold +4752, hay +720, power -234.38, water +60, weird_substance +265, wood +273. Game time: 1h 31m 51s elapsed, 4h 28m 9s of budget remaining. Output: Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- mixed_tile <- ensure <- fert use_item(Items.Fertilizer) ^^ --------------------------------------------------------------------
r111h 32mRan
PUMP_AT = 600 HAY_AT = 400 SUN_AT = 200 GOLD_AT = 40000 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def goto(x, y): while get_pos_x() != x: if not move(East): harvest() while get_pos_y() != y: if not move(North): harvest() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() elif num_items(Items.Gold) < GOLD_AT and num_items(Items.Weird_Substance) >= 64: while num_items(Items.Weird_Substance) >= 16 and num_items(Items.Gold) < GOLD_AT: if not maze_round(): break elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0)Changes from the previous revision
- PUMP_AT = 1200 + PUMP_AT = 600 HAY_AT = 400 SUN_AT = 200
- Write result the agent saw
Saved farm (212 lines). Game time: 1h 32m 21s elapsed, 4h 27m 39s of budget remaining.
- run_program at 1h 32m for 600s (agent saw)
Ran farm for 10m of game time; it is still running. Inventory change: carrot +1098, fertilizer -14, gold +15552, hay +352, power -684.16, pumpkin +1428, water -60, weird_substance -303, wood +303. Game time: 1h 42m 31s elapsed, 4h 17m 29s of budget remaining. Output: Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- pump_tile <- water use_item(Items.Water) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- pump_tile <- water use_item(Items.Water) ^^ --------------------------------------------------------------------
r121h 54mRan
PUMP_AT = 600 HAY_AT = 400 SUN_AT = 300 CACT_AT = 2000 WEIRD_HI = 300 WEIRD_LO = 100 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def goto(x, y): while get_pos_x() != x: if not move(East): harvest() while get_pos_y() != y: if not move(North): harvest() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def cact_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Cactus) water() def sort_line(dirn, n): for p in range(n - 1): swapped = False for q in range(n - 1): a = measure() b = measure(dirn) if a != None and b != None and a > b: swap(dirn) swapped = True move(dirn) move(dirn) if not swapped: return def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 if mode == 5: y = k while y < n: goto(0, y) sort_line(East, n) y += D return 0 if mode == 6: x = k while x < n: goto(x, 0) sort_line(North, n) x += D return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() elif mode == 4: cact_tile() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def cact_round(): run_all(4, 0, 0) run_all(5, 0, 0) run_all(6, 0, 0) if get_entity_type() == Entities.Cactus and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() elif num_items(Items.Weird_Substance) >= WEIRD_HI: while num_items(Items.Weird_Substance) >= WEIRD_LO: if not maze_round(): break elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Pumpkin) >= CACT_AT: cact_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0)Changes from the previous revision
PUMP_AT = 600 HAY_AT = 400 - SUN_AT = 200 - GOLD_AT = 40000 + SUN_AT = 300 + CACT_AT = 2000 + WEIRD_HI = 300 + WEIRD_LO = 100 def water(): return 0 + def cact_tile(): + if get_ground_type() != Grounds.Soil: + till() + ensure(Entities.Cactus) + water() + + def sort_line(dirn, n): + for p in range(n - 1): + swapped = False + for q in range(n - 1): + a = measure() + b = measure(dirn) + if a != None and b != None and a > b: + swap(dirn) + swapped = True + move(dirn) + move(dirn) + if not swapped: + return + def worker(mode, k, D, best, cap): n = get_world_size() return 0 return 0 + if mode == 5: + y = k + while y < n: + goto(0, y) + sort_line(East, n) + y += D + return 0 + if mode == 6: + x = k + while x < n: + goto(x, 0) + sort_line(North, n) + x += D + return 0 res = 0 newbest = 0 newbest = m water() + elif mode == 4: + cact_tile() move(North) x += D harvest() + def cact_round(): + run_all(4, 0, 0) + run_all(5, 0, 0) + run_all(6, 0, 0) + if get_entity_type() == Entities.Cactus and can_harvest(): + harvest() + def sun_round(): n = get_world_size() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() - elif num_items(Items.Gold) < GOLD_AT and num_items(Items.Weird_Substance) >= 64: - while num_items(Items.Weird_Substance) >= 16 and num_items(Items.Gold) < GOLD_AT: + elif num_items(Items.Weird_Substance) >= WEIRD_HI: + while num_items(Items.Weird_Substance) >= WEIRD_LO: if not maze_round(): break elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() + elif num_items(Items.Pumpkin) >= CACT_AT: + cact_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round()
- Write result the agent saw
Saved farm (259 lines). Game time: 1h 55m 2s elapsed, 4h 4m 58s of budget remaining.
- run_program at 1h 55m for 180s (agent saw)
Ran farm for 3m of game time; it is still running. Inventory change: cactus +19944, fertilizer +25, gold +4896, power -282.14, pumpkin -288, water +102, weird_substance +384. Game time: 1h 58m 12s elapsed, 4h 1m 48s of budget remaining. Output: (none)
r131h 59mRan
PUMP_AT = 600 HAY_AT = 400 SUN_AT = 300 CACT_AT = 2000 WEIRD_HI = 300 WEIRD_LO = 100 DINO_CACT = 4000 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def goto(x, y): while get_pos_x() != x: if not move(East): harvest() while get_pos_y() != y: if not move(North): harvest() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def cact_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Cactus) water() def clear_tile(): if get_entity_type() != None: harvest() if get_ground_type() == Grounds.Soil: till() def sort_line(dirn, n): for p in range(n - 1): swapped = False for q in range(n - 1): a = measure() b = measure(dirn) if a != None and b != None and a > b: swap(dirn) swapped = True move(dirn) move(dirn) if not swapped: return def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 if mode == 5: y = k while y < n: goto(0, y) sort_line(East, n) y += D return 0 if mode == 6: x = k while x < n: goto(x, 0) sort_line(North, n) x += D return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() elif mode == 4: cact_tile() elif mode == 7: clear_tile() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def cact_round(): run_all(4, 0, 0) run_all(5, 0, 0) run_all(6, 0, 0) if get_entity_type() == Entities.Cactus and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def dino_dir(): x = get_pos_x() y = get_pos_y() n = get_world_size() if x == 0: if y == 0: return East return South if y % 2 == 0: if x < n - 1: return East return North if x > 1: return West if y == n - 1: return West return North def dino_round(): run_all(7, 0, 0) goto(0, 0) change_hat(Hats.Dinosaur_Hat) steps = 0 limit = get_world_size() * get_world_size() * 90 while steps < limit: if not move(dino_dir()): break steps += 1 change_hat(Hats.Gray_Hat) def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() elif num_items(Items.Weird_Substance) >= WEIRD_HI: while num_items(Items.Weird_Substance) >= WEIRD_LO: if not maze_round(): break elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Cactus) >= DINO_CACT and num_items(Items.Bone) < num_items(Items.Cactus) / 4: dino_round() elif num_items(Items.Pumpkin) >= CACT_AT: cact_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0)Changes from the previous revision
WEIRD_HI = 300 WEIRD_LO = 100 + DINO_CACT = 4000 def water(): water() + def clear_tile(): + if get_entity_type() != None: + harvest() + if get_ground_type() == Grounds.Soil: + till() + def sort_line(dirn, n): for p in range(n - 1): elif mode == 4: cact_tile() + elif mode == 7: + clear_tile() move(North) x += D best = nb + def dino_dir(): + x = get_pos_x() + y = get_pos_y() + n = get_world_size() + if x == 0: + if y == 0: + return East + return South + if y % 2 == 0: + if x < n - 1: + return East + return North + if x > 1: + return West + if y == n - 1: + return West + return North + + def dino_round(): + run_all(7, 0, 0) + goto(0, 0) + change_hat(Hats.Dinosaur_Hat) + steps = 0 + limit = get_world_size() * get_world_size() * 90 + while steps < limit: + if not move(dino_dir()): + break + steps += 1 + change_hat(Hats.Gray_Hat) + def solve_maze(): dirs = [North, East, South, West] elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() + elif num_items(Items.Cactus) >= DINO_CACT and num_items(Items.Bone) < num_items(Items.Cactus) / 4: + dino_round() elif num_items(Items.Pumpkin) >= CACT_AT: cact_round()
- Write result the agent saw
Saved farm (300 lines). Game time: 1h 59m 32s elapsed, 4h 28s of budget remaining.
- run_program at 1h 59m for 240s (agent saw)
Ran farm for 3m 55s of game time; it stopped with an error: Hats.Gray_Hat must be unlocked before this can be used. Inventory change: cactus -286, carrot -144, fertilizer -7, gold +4032, hay +2224, power +501.46, water -44, weird_substance -100. Game time: 2h 3m 37s elapsed, 3h 56m 23s of budget remaining. Output: Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- water use_item(Items.Water) ^^ -------------------------------------------------------------------- Error: Hats.Gray_Hat must be unlocked before this can be used. In: dino_round change_hat(Hats.Gray_Hat) ^^ --------------------------------------------------------------------- Runtime error at 2h 03m (telemetry; not shown to the agent)
Hats.Gray_Hat must be unlocked before this can be used.
r142h 04mRan
PUMP_AT = 600 HAY_AT = 400 SUN_AT = 300 CACT_AT = 2000 WEIRD_HI = 300 WEIRD_LO = 100 DINO_CACT = 4000 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) fert() def goto(x, y): while get_pos_x() != x: if not move(East): harvest() while get_pos_y() != y: if not move(North): harvest() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def cact_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Cactus) water() def clear_tile(): if get_entity_type() != None: harvest() if get_ground_type() == Grounds.Soil: till() def sort_line(dirn, n): for p in range(n - 1): swapped = False for q in range(n - 1): a = measure() b = measure(dirn) if a != None and b != None and a > b: swap(dirn) swapped = True move(dirn) move(dirn) if not swapped: return def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 if mode == 5: y = k while y < n: goto(0, y) sort_line(East, n) y += D return 0 if mode == 6: x = k while x < n: goto(x, 0) sort_line(North, n) x += D return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() elif mode == 4: cact_tile() elif mode == 7: clear_tile() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def cact_round(): run_all(4, 0, 0) run_all(5, 0, 0) run_all(6, 0, 0) if get_entity_type() == Entities.Cactus and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def dino_dir(): x = get_pos_x() y = get_pos_y() n = get_world_size() if x == 0: if y == 0: return East return South if y % 2 == 0: if x < n - 1: return East return North if x > 1: return West if y == n - 1: return West return North def dino_round(): run_all(7, 0, 0) goto(0, 0) change_hat(Hats.Dinosaur_Hat) steps = 0 limit = get_world_size() * get_world_size() * 90 while steps < limit: if not move(dino_dir()): break steps += 1 change_hat(Hats.Straw_Hat) def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() elif num_items(Items.Weird_Substance) >= WEIRD_HI: while num_items(Items.Weird_Substance) >= WEIRD_LO: if not maze_round(): break elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Cactus) >= DINO_CACT and num_items(Items.Bone) < num_items(Items.Cactus) / 4: dino_round() elif num_items(Items.Pumpkin) >= CACT_AT: cact_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0)Changes from the previous revision
break steps += 1 - change_hat(Hats.Gray_Hat) + change_hat(Hats.Straw_Hat) def solve_maze():
- Write result the agent saw
Saved farm (300 lines). Game time: 2h 4m 48s elapsed, 3h 55m 12s of budget remaining.
- run_program at 2h 04m for 300s (agent saw)
Ran farm for 5m of game time; it is still running. Inventory change: cactus +16056, fertilizer -5, gold +15264, power -414.63, pumpkin -288, water +96, weird_substance +3384. Game time: 2h 10m 8s elapsed, 3h 49m 52s of budget remaining. Output: (none)
r152h 20mRan
PUMP_AT = 600 HAY_AT = 400 SUN_AT = 300 CACT_AT = 2000 WEIRD_HI = 300 MAZE_BATCH = 4 DINO_CACT = 4000 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) if want != Entities.Cactus: fert() def goto(x, y): while get_pos_x() != x: if not move(East): harvest() while get_pos_y() != y: if not move(North): harvest() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def cact_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Cactus) water() def clear_tile(): if get_entity_type() != None: harvest() if get_ground_type() == Grounds.Soil: till() def sort_line(dirn, n): for p in range(n - 1): swapped = False for q in range(n - 1): a = measure() b = measure(dirn) if a != None and b != None and a > b: swap(dirn) swapped = True move(dirn) move(dirn) if not swapped: return def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 if mode == 5: y = k while y < n: goto(0, y) sort_line(East, n) y += D return 0 if mode == 6: x = k while x < n: goto(x, 0) sort_line(North, n) x += D return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() elif mode == 4: cact_tile() elif mode == 7: clear_tile() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def cact_round(): run_all(4, 0, 0) run_all(5, 0, 0) run_all(6, 0, 0) if get_entity_type() == Entities.Cactus and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def dino_dir(): x = get_pos_x() y = get_pos_y() n = get_world_size() if x == 0: if y == 0: return East return South if y % 2 == 0: if x < n - 1: return East return North if x > 1: return West if y == n - 1: return West return North def dino_round(): run_all(7, 0, 0) goto(0, 0) change_hat(Hats.Dinosaur_Hat) steps = 0 limit = get_world_size() * get_world_size() * 90 while steps < limit: if not move(dino_dir()): break steps += 1 change_hat(Hats.Straw_Hat) def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() elif num_items(Items.Weird_Substance) >= WEIRD_HI: for i in range(MAZE_BATCH): if not maze_round(): break elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Cactus) >= DINO_CACT and num_items(Items.Bone) < num_items(Items.Cactus) / 4: dino_round() elif num_items(Items.Pumpkin) >= CACT_AT: cact_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0)Changes from the previous revision
CACT_AT = 2000 WEIRD_HI = 300 - WEIRD_LO = 100 + MAZE_BATCH = 4 DINO_CACT = 4000 harvest() plant(want) - fert() + if want != Entities.Cactus: + fert() def goto(x, y): solve_maze() elif num_items(Items.Weird_Substance) >= WEIRD_HI: - while num_items(Items.Weird_Substance) >= WEIRD_LO: + for i in range(MAZE_BATCH): if not maze_round(): break
- Write result the agent saw
Saved farm (301 lines). Game time: 2h 20m 58s elapsed, 3h 39m 2s of budget remaining.
- run_program at 2h 21m for 600s (agent saw)
Ran farm for 10m of game time; it is still running. Inventory change: carrot -288, fertilizer -168, gold +19872, power +693.92, water -241, weird_substance -576. Game time: 2h 31m 18s elapsed, 3h 28m 42s of budget remaining. Output: (none)
r162h 31mRan
PUMP_AT = 600 HAY_AT = 400 SUN_AT = 300 CACT_AT = 2000 WEIRD_HI = 300 MAZE_BATCH = 3 DINO_CACT = 4000 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) if want != Entities.Cactus: fert() def goto(x, y): while get_pos_x() != x: if not move(East): harvest() while get_pos_y() != y: if not move(North): harvest() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def cact_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Cactus) water() def clear_tile(): if get_entity_type() != None: harvest() if get_ground_type() == Grounds.Soil: till() def sort_line(dirn, n): for p in range(n - 1): swapped = False for q in range(n - 1): a = measure() b = measure(dirn) if a != None and b != None and a > b: swap(dirn) swapped = True move(dirn) move(dirn) if not swapped: return def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 if mode == 5: y = k while y < n: goto(0, y) sort_line(East, n) y += D return 0 if mode == 6: x = k while x < n: goto(x, 0) sort_line(North, n) x += D return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() elif mode == 4: cact_tile() elif mode == 7: clear_tile() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def cact_round(): run_all(4, 0, 0) run_all(5, 0, 0) run_all(6, 0, 0) if get_entity_type() == Entities.Cactus and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def dino_dir(): x = get_pos_x() y = get_pos_y() n = get_world_size() if x == 0: if y == 0: return East return South if y % 2 == 0: if x < n - 1: return East return North if x > 1: return West if y == n - 1: return West return North def dino_round(): run_all(7, 0, 0) goto(0, 0) change_hat(Hats.Dinosaur_Hat) steps = 0 limit = get_world_size() * get_world_size() * 90 while steps < limit: if not move(dino_dir()): break steps += 1 change_hat(Hats.Straw_Hat) def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() if num_items(Items.Weird_Substance) >= WEIRD_HI: for i in range(MAZE_BATCH): if not maze_round(): break if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Cactus) >= DINO_CACT and num_items(Items.Bone) < num_items(Items.Cactus) / 4: dino_round() elif num_items(Items.Pumpkin) >= CACT_AT: cact_round() elif num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0)Changes from the previous revision
CACT_AT = 2000 WEIRD_HI = 300 - MAZE_BATCH = 4 + MAZE_BATCH = 3 DINO_CACT = 4000 if e == Entities.Hedge or e == Entities.Treasure: solve_maze() - elif num_items(Items.Weird_Substance) >= WEIRD_HI: + if num_items(Items.Weird_Substance) >= WEIRD_HI: for i in range(MAZE_BATCH): if not maze_round(): break - elif num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: + if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() elif num_items(Items.Cactus) >= DINO_CACT and num_items(Items.Bone) < num_items(Items.Cactus) / 4:
- Write result the agent saw
Saved farm (301 lines). Game time: 2h 31m 38s elapsed, 3h 28m 22s of budget remaining.
- run_program at 2h 31m for 600s (agent saw)
Ran farm for 10m of game time; it is still running. Inventory change: bone +40898, cactus +186052, carrot -288, fertilizer -1, gold +10656, hay +2304, power -272.28, pumpkin -2880, water -648, weird_substance -392. Game time: 2h 41m 58s elapsed, 3h 18m 2s of budget remaining. Output: Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- water use_item(Items.Water) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: sun_round <- run_all <- worker <- water use_item(Items.Water) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- cact_tile <- water use_item(Items.Water) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- cact_tile <- water use_item(Items.Water) ^^ --------------------------------------------------------------------
r172h 42mRan
PUMP_AT = 400 HAY_AT = 400 SUN_AT = 300 WEIRD_HI = 300 MAZE_BATCH = 3 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) if want != Entities.Cactus: fert() def goto(x, y): while get_pos_x() != x: if not move(East): harvest() while get_pos_y() != y: if not move(North): harvest() def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def cact_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Cactus) water() def clear_tile(): if get_entity_type() != None: harvest() if get_ground_type() == Grounds.Soil: till() def sort_line(dirn, n): for p in range(n - 1): swapped = False for q in range(n - 1): a = measure() b = measure(dirn) if a != None and b != None and a > b: swap(dirn) swapped = True move(dirn) move(dirn) if not swapped: return def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 if mode == 5: y = k while y < n: goto(0, y) sort_line(East, n) y += D return 0 if mode == 6: x = k while x < n: goto(x, 0) sort_line(North, n) x += D return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() elif mode == 4: cact_tile() elif mode == 7: clear_tile() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def cact_round(): run_all(4, 0, 0) run_all(5, 0, 0) run_all(6, 0, 0) if get_entity_type() == Entities.Cactus and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def dino_dir(): x = get_pos_x() y = get_pos_y() n = get_world_size() if x == 0: if y == 0: return East return South if y % 2 == 0: if x < n - 1: return East return North if x > 1: return West if y == n - 1: return West return North def dino_round(): run_all(7, 0, 0) goto(0, 0) change_hat(Hats.Dinosaur_Hat) steps = 0 limit = get_world_size() * get_world_size() * 90 while steps < limit: if not move(dino_dir()): break steps += 1 change_hat(Hats.Straw_Hat) def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() cycle = 0 while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() if num_items(Items.Weird_Substance) >= WEIRD_HI: for i in range(MAZE_BATCH): if not maze_round(): break if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() step = cycle % 6 cycle += 1 if step == 0 or step == 3: if num_items(Items.Pumpkin) >= 300: cact_round() else: run_all(0, 0, 0) elif step == 1: if num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0) elif step == 4: if num_items(Items.Cactus) >= 400: dino_round() else: run_all(0, 0, 0) else: run_all(0, 0, 0)Changes from the previous revision
- PUMP_AT = 600 + PUMP_AT = 400 HAY_AT = 400 SUN_AT = 300 - CACT_AT = 2000 WEIRD_HI = 300 MAZE_BATCH = 3 - DINO_CACT = 4000 def water(): return solve_maze() + cycle = 0 while True: e = get_entity_type() if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() - elif num_items(Items.Cactus) >= DINO_CACT and num_items(Items.Bone) < num_items(Items.Cactus) / 4: - dino_round() - elif num_items(Items.Pumpkin) >= CACT_AT: - cact_round() - elif num_items(Items.Carrot) >= PUMP_AT: - pump_round() + step = cycle % 6 + cycle += 1 + if step == 0 or step == 3: + if num_items(Items.Pumpkin) >= 300: + cact_round() + else: + run_all(0, 0, 0) + elif step == 1: + if num_items(Items.Carrot) >= PUMP_AT: + pump_round() + else: + run_all(0, 0, 0) + elif step == 4: + if num_items(Items.Cactus) >= 400: + dino_round() + else: + run_all(0, 0, 0) else: run_all(0, 0, 0)
- Write result the agent saw
Saved farm (311 lines). Game time: 2h 42m 28s elapsed, 3h 17m 32s of budget remaining.
- run_program at 2h 42m for 600s (agent saw)
Ran farm for 10m of game time; it is still running. Inventory change: fertilizer +120, power -377.52, pumpkin -168, water +432. Game time: 2h 52m 38s elapsed, 3h 7m 22s of budget remaining. Output: (none)
r182h 52mRan
PUMP_AT = 400 HAY_AT = 400 SUN_AT = 300 WEIRD_HI = 300 MAZE_BATCH = 3 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) if want != Entities.Cactus: fert() def goto(x, y): fails = 0 while get_pos_x() != x: if not move(East): fails += 1 harvest() if fails > 3: change_hat(Hats.Straw_Hat) while get_pos_y() != y: if not move(North): fails += 1 harvest() if fails > 3: change_hat(Hats.Straw_Hat) def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def cact_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Cactus) water() def clear_tile(): if get_entity_type() != None: harvest() if get_ground_type() == Grounds.Soil: till() def sort_line(dirn, n): for p in range(n - 1): swapped = False for q in range(n - 1): a = measure() b = measure(dirn) if a != None and b != None and a > b: swap(dirn) swapped = True move(dirn) move(dirn) if not swapped: return def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 if mode == 5: y = k while y < n: goto(0, y) sort_line(East, n) y += D return 0 if mode == 6: x = k while x < n: goto(x, 0) sort_line(North, n) x += D return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() elif mode == 4: cact_tile() elif mode == 7: clear_tile() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def cact_round(): run_all(4, 0, 0) run_all(5, 0, 0) run_all(6, 0, 0) if get_entity_type() == Entities.Cactus and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def dino_dir(): x = get_pos_x() y = get_pos_y() n = get_world_size() if x == 0: if y == 0: return East return South if y % 2 == 0: if x < n - 1: return East return North if x > 1: return West if y == n - 1: return West return North def dino_round(): run_all(7, 0, 0) goto(0, 0) change_hat(Hats.Dinosaur_Hat) steps = 0 limit = get_world_size() * get_world_size() * 90 while steps < limit: if not move(dino_dir()): break steps += 1 change_hat(Hats.Straw_Hat) def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() change_hat(Hats.Straw_Hat) cycle = 0 while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() if num_items(Items.Weird_Substance) >= WEIRD_HI: for i in range(MAZE_BATCH): if not maze_round(): break if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() step = cycle % 6 cycle += 1 if step == 0 or step == 3: if num_items(Items.Pumpkin) >= 300: cact_round() else: run_all(0, 0, 0) elif step == 1: if num_items(Items.Carrot) >= PUMP_AT: pump_round() else: run_all(0, 0, 0) elif step == 4: if num_items(Items.Cactus) >= 400: dino_round() else: run_all(0, 0, 0) else: run_all(0, 0, 0)Changes from the previous revision
def goto(x, y): + fails = 0 while get_pos_x() != x: if not move(East): + fails += 1 harvest() + if fails > 3: + change_hat(Hats.Straw_Hat) while get_pos_y() != y: if not move(North): + fails += 1 harvest() + if fails > 3: + change_hat(Hats.Straw_Hat) def mixed_tile(): return solve_maze() + change_hat(Hats.Straw_Hat) cycle = 0 while True:
- Write result the agent saw
Saved farm (319 lines). Game time: 2h 53m 8s elapsed, 3h 6m 52s of budget remaining.
- run_program at 2h 53m for 300s (agent saw)
Ran farm for 5m of game time; it is still running. Inventory change: bone +81992, cactus +61163, carrot -288, fertilizer -168, gold +6912, hay +10608, power +744.03, pumpkin -864, water -511, weird_substance -16, wood -960. Game time: 2h 58m 18s elapsed, 3h 1m 42s of budget remaining. Output: …------------------------------------------------------------ Warning: Didn't have the required items to plant Entities.Carrot. In: worker <- mixed_tile <- ensure plant(want) ^^ -------------------------------------------------------------------- Warning: Didn't have the required items to plant Entities.Carrot. In: worker <- mixed_tile <- ensure plant(want) ^^ -------------------------------------------------------------------- Warning: Didn't have the required items to plant Entities.Carrot. In: worker <- mixed_tile <- ensure plant(want) ^^ -------------------------------------------------------------------- Warning: Didn't have the required items to plant Entities.Carrot. In: worker <- mixed_tile <- ensure plant(want) ^^ -------------------------------------------------------------------- Warning: Didn't have the required items to plant Entities.Carrot. In: worker <- mixed_tile <- ensure plant(want) ^^ -------------------------------------------------------------------- Warning: Didn't have the required items to plant Entities.Carrot. In: worker <- mixed_tile <- ensure plant(want) ^^ -------------------------------------------------------------------- Warning: Didn't have the required items to plant Entities.Carrot. In: worker <- mixed_tile <- ensure plant(want) ^^ -------------------------------------------------------------------- Warning: Didn't have the required items to plant Entities.Carrot. In: worker <- mixed_tile <- ensure plant(want) ^^ -------------------------------------------------------------------- Warning: Didn't have the required items to plant Entities.Carrot. In: worker <- mixed_tile <- ensure plant(want) ^^ -------------------------------------------------------------------- Warning: Didn't have the required items to plant Entities.Carrot. In: worker <- mixed_tile <- ensure plant(want) ^^ --------------------------------------------------------------------
r192h 58mRan
PUMP_AT = 400 HAY_AT = 400 WOOD_AT = 300 SUN_AT = 300 WEIRD_HI = 300 MAZE_BATCH = 3 MIXED_BLOCK = 4 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) if want != Entities.Cactus: fert() def goto(x, y): fails = 0 while get_pos_x() != x: if not move(East): fails += 1 harvest() if fails > 3: change_hat(Hats.Straw_Hat) while get_pos_y() != y: if not move(North): fails += 1 harvest() if fails > 3: change_hat(Hats.Straw_Hat) def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT or num_items(Items.Wood) < WOOD_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def cact_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Cactus) water() def clear_tile(): if get_entity_type() != None: harvest() if get_ground_type() == Grounds.Soil: till() def sort_line(dirn, n): for p in range(n - 1): swapped = False for q in range(n - 1): a = measure() b = measure(dirn) if a != None and b != None and a > b: swap(dirn) swapped = True move(dirn) move(dirn) if not swapped: return def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 if mode == 5: y = k while y < n: goto(0, y) sort_line(East, n) y += D return 0 if mode == 6: x = k while x < n: goto(x, 0) sort_line(North, n) x += D return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() elif mode == 4: cact_tile() elif mode == 7: clear_tile() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def mixed_block(): for i in range(MIXED_BLOCK): run_all(0, 0, 0) def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def cact_round(): run_all(4, 0, 0) run_all(5, 0, 0) run_all(6, 0, 0) if get_entity_type() == Entities.Cactus and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def dino_dir(): x = get_pos_x() y = get_pos_y() n = get_world_size() if x == 0: if y == 0: return East return South if y % 2 == 0: if x < n - 1: return East return North if x > 1: return West if y == n - 1: return West return North def dino_round(): run_all(7, 0, 0) goto(0, 0) change_hat(Hats.Dinosaur_Hat) steps = 0 limit = get_world_size() * get_world_size() * 90 while steps < limit: if not move(dino_dir()): break steps += 1 change_hat(Hats.Straw_Hat) def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 3000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() change_hat(Hats.Straw_Hat) cycle = 0 while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() if num_items(Items.Weird_Substance) >= WEIRD_HI: for i in range(MAZE_BATCH): if not maze_round(): break if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() step = cycle % 6 cycle += 1 if step == 0 and num_items(Items.Pumpkin) >= 300: cact_round() elif step == 2 and num_items(Items.Carrot) >= PUMP_AT: pump_round() elif step == 4 and num_items(Items.Cactus) >= 400: dino_round() else: mixed_block()Changes from the previous revision
PUMP_AT = 400 HAY_AT = 400 + WOOD_AT = 300 SUN_AT = 300 WEIRD_HI = 300 MAZE_BATCH = 3 + MIXED_BLOCK = 4 def water(): return want = Entities.Carrot - if num_items(Items.Hay) < HAY_AT: + if num_items(Items.Hay) < HAY_AT or num_items(Items.Wood) < WOOD_AT: want = Entities.Grass if want == Entities.Carrot: return results + def mixed_block(): + for i in range(MIXED_BLOCK): + run_all(0, 0, 0) + def pump_round(): run_all(1, 0, 0) step = cycle % 6 cycle += 1 - if step == 0 or step == 3: - if num_items(Items.Pumpkin) >= 300: - cact_round() - else: - run_all(0, 0, 0) - elif step == 1: - if num_items(Items.Carrot) >= PUMP_AT: - pump_round() - else: - run_all(0, 0, 0) - elif step == 4: - if num_items(Items.Cactus) >= 400: - dino_round() - else: - run_all(0, 0, 0) + if step == 0 and num_items(Items.Pumpkin) >= 300: + cact_round() + elif step == 2 and num_items(Items.Carrot) >= PUMP_AT: + pump_round() + elif step == 4 and num_items(Items.Cactus) >= 400: + dino_round() else: - run_all(0, 0, 0) + mixed_block()
- Write result the agent saw
Saved farm (316 lines). Game time: 2h 58m 38s elapsed, 3h 1m 22s of budget remaining.
- run_program at 2h 58m for 600s (agent saw)
Ran farm for 10m of game time; it is still running. Inventory change: bone +163592, cactus +59920, carrot +53708, fertilizer -4, gold +21312, hay +29288, power +405.31, pumpkin +2550, water -19, weird_substance +8690, wood +177108. Game time: 3h 8m 48s elapsed, 2h 51m 12s of budget remaining. Output: Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: mixed_block <- run_all <- worker <- mixed_tile <- ensure <- ... use_item(Items.Fertilizer) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: pump_round <- run_all <- worker <- pump_tile <- water <- ... use_item(Items.Water) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- pump_tile <- water use_item(Items.Water) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- pump_tile <- water use_item(Items.Water) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- mixed_tile <- ensure <- fert use_item(Items.Fertilizer) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- cact_tile <- water use_item(Items.Water) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- water use_item(Items.Water) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- water use_item(Items.Water) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- water use_item(Items.Water) ^^ --------------------------------------------------------------------
r203h 42mRan
PUMP_AT = 400 HAY_AT = 400 WOOD_AT = 300 SUN_AT = 300 WEIRD_HI = 300 MAZE_BATCH = 8 MIXED_BLOCK = 4 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) if want != Entities.Cactus: fert() def goto(x, y): fails = 0 while get_pos_x() != x: if not move(East): fails += 1 harvest() if fails > 3: change_hat(Hats.Straw_Hat) while get_pos_y() != y: if not move(North): fails += 1 harvest() if fails > 3: change_hat(Hats.Straw_Hat) def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT or num_items(Items.Wood) < WOOD_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def cact_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Cactus) water() def clear_tile(): if get_entity_type() != None: harvest() if get_ground_type() == Grounds.Soil: till() def sort_line(dirn, n): for p in range(n - 1): swapped = False for q in range(n - 1): a = measure() b = measure(dirn) if a != None and b != None and a > b: swap(dirn) swapped = True move(dirn) move(dirn) if not swapped: return def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 if mode == 5: y = k while y < n: goto(0, y) sort_line(East, n) y += D return 0 if mode == 6: x = k while x < n: goto(x, 0) sort_line(North, n) x += D return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() elif mode == 4: cact_tile() elif mode == 7: clear_tile() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def mixed_block(): for i in range(MIXED_BLOCK): run_all(0, 0, 0) def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def cact_round(): run_all(4, 0, 0) run_all(5, 0, 0) run_all(6, 0, 0) if get_entity_type() == Entities.Cactus and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def dino_dir(): x = get_pos_x() y = get_pos_y() n = get_world_size() if x == 0: if y == 0: return East return South if y % 2 == 0: if x < n - 1: return East return North if x > 1: return West if y == n - 1: return West return North def dino_round(): run_all(7, 0, 0) goto(0, 0) change_hat(Hats.Dinosaur_Hat) steps = 0 limit = get_world_size() * get_world_size() * 90 while steps < limit: if not move(dino_dir()): break steps += 1 change_hat(Hats.Straw_Hat) def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 4000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() change_hat(Hats.Straw_Hat) cycle = 0 while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() if num_items(Items.Weird_Substance) >= WEIRD_HI: for i in range(MAZE_BATCH): if not maze_round(): break if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() step = cycle % 6 cycle += 1 if step == 0 and num_items(Items.Pumpkin) >= 600: cact_round() elif step == 2 and num_items(Items.Carrot) >= PUMP_AT: pump_round() elif step == 4 and num_items(Items.Cactus) >= 600: dino_round() else: mixed_block()Changes from the previous revision
SUN_AT = 300 WEIRD_HI = 300 - MAZE_BATCH = 3 + MAZE_BATCH = 8 MIXED_BLOCK = 4 d = 0 steps = 0 - while get_entity_type() != Entities.Treasure and steps < 3000: + while get_entity_type() != Entities.Treasure and steps < 4000: steps += 1 r = (d + 1) % 4 step = cycle % 6 cycle += 1 - if step == 0 and num_items(Items.Pumpkin) >= 300: + if step == 0 and num_items(Items.Pumpkin) >= 600: cact_round() elif step == 2 and num_items(Items.Carrot) >= PUMP_AT: pump_round() - elif step == 4 and num_items(Items.Cactus) >= 400: + elif step == 4 and num_items(Items.Cactus) >= 600: dino_round() else:
- Write result the agent saw
Saved farm (316 lines). Game time: 3h 42m 55s elapsed, 2h 17m 5s of budget remaining.
- run_program at 3h 42m for 600s (agent saw)
Ran farm for 10m of game time; it is still running. Inventory change: cactus +130616, carrot +785536, fertilizer +189, gold +40960, hay +475200, power +363.58, pumpkin +94208, water +6079, weird_substance +364116, wood +4017920. Game time: 3h 53m 5s elapsed, 2h 6m 55s of budget remaining. Output: Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- sun_plant_tile <- ensure <- fert use_item(Items.Fertilizer) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- mixed_tile <- ensure <- fert use_item(Items.Fertilizer) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- mixed_tile <- ensure <- fert use_item(Items.Fertilizer) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- mixed_tile <- ensure <- fert use_item(Items.Fertilizer) ^^ --------------------------------------------------------------------
r215h 13mRan
PUMP_AT = 400 HAY_AT = 400 WOOD_AT = 300 SUN_AT = 300 WEIRD_HI = 300 MAZE_BATCH = 8 MIXED_BLOCK = 4 def water(): if get_water() < 0.5 and num_items(Items.Water) > 0: use_item(Items.Water) def fert(): if num_items(Items.Fertilizer) > 0: use_item(Items.Fertilizer) def ensure(want): e = get_entity_type() if e == want: return if e != None and e != Entities.Grass and e != Entities.Dead_Pumpkin: harvest() plant(want) if want != Entities.Cactus: fert() def goto(x, y): fails = 0 while get_pos_x() != x: if not move(East): fails += 1 harvest() if fails > 3: change_hat(Hats.Straw_Hat) while get_pos_y() != y: if not move(North): fails += 1 harvest() if fails > 3: change_hat(Hats.Straw_Hat) def mixed_tile(): x = get_pos_x() y = get_pos_y() e = get_entity_type() want = Entities.Tree if (x + y) % 2 == 1: if e == Entities.Carrot and not can_harvest(): water() return want = Entities.Carrot if num_items(Items.Hay) < HAY_AT or num_items(Items.Wood) < WOOD_AT: want = Entities.Grass if want == Entities.Carrot: if get_ground_type() != Grounds.Soil: till() if want != Entities.Carrot: if get_ground_type() == Grounds.Soil: till() if can_harvest(): harvest() if want != Entities.Grass: ensure(want) water() def pump_tile(): if get_ground_type() != Grounds.Soil: till() e = get_entity_type() if e != Entities.Pumpkin: ensure(Entities.Pumpkin) water() return False water() return can_harvest() def sun_plant_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Sunflower) water() if get_entity_type() == Entities.Sunflower: return measure() return 0 def cact_tile(): if get_ground_type() != Grounds.Soil: till() ensure(Entities.Cactus) water() def sort_line(dirn, n): for p in range(n - 1): swapped = False for q in range(n - 1): a = measure() b = measure(dirn) if a != None and b != None and a > b: swap(dirn) swapped = True move(dirn) move(dirn) if not swapped: return def worker(mode, k, D, best, cap): n = get_world_size() if mode == 1: done = False while not done: done = True x = k while x < n: goto(x, 0) for j in range(n): if not pump_tile(): done = False move(North) x += D if num_items(Items.Carrot) < 2: return 0 return 0 if mode == 5: y = k while y < n: goto(0, y) sort_line(East, n) y += D return 0 if mode == 6: x = k while x < n: goto(x, 0) sort_line(North, n) x += D return 0 res = 0 newbest = 0 x = k while x < n: goto(x, 0) for j in range(n): if mode == 0: mixed_tile() elif mode == 2: m = sun_plant_tile() if m != None and m > res: res = m elif mode == 3: if get_entity_type() == Entities.Sunflower: m = measure() if m == best and res < cap and can_harvest(): harvest() res += 1 else: if m > newbest: newbest = m water() elif mode == 4: cact_tile() move(North) x += D if mode == 3: return [res, newbest] return res def run_all(mode, best, cap): D = max_drones() handles = [] failed = [] for k in range(1, D): h = spawn_drone(worker, mode, k, D, best, cap) if h == None: failed.append(k) else: handles.append(h) results = [worker(mode, 0, D, best, cap)] for k in failed: results.append(worker(mode, k, D, best, cap)) for h in handles: results.append(wait_for(h)) return results def mixed_block(): for i in range(MIXED_BLOCK): run_all(0, 0, 0) def pump_round(): run_all(1, 0, 0) if get_entity_type() == Entities.Pumpkin and can_harvest(): harvest() def cact_round(): run_all(4, 0, 0) run_all(5, 0, 0) run_all(6, 0, 0) if get_entity_type() == Entities.Cactus and can_harvest(): harvest() def sun_round(): n = get_world_size() rs = run_all(2, 0, 0) best = 0 for r in rs: best = max(best, r) remaining = n * n while remaining > 10 and best > 0: cap = (remaining - 10) // max_drones() + 1 rs = run_all(3, best, cap) h = 0 nb = 0 for r in rs: h += r[0] nb = max(nb, r[1]) remaining -= h if h == 0 and nb == 0: break best = nb def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 while get_entity_type() != Entities.Treasure and steps < 6000: steps += 1 r = (d + 1) % 4 l = (d + 3) % 4 if can_move(dirs[r]): d = r move(dirs[d]) elif can_move(dirs[d]): move(dirs[d]) elif can_move(dirs[l]): d = l move(dirs[d]) else: d = (d + 2) % 4 move(dirs[d]) if get_entity_type() == Entities.Treasure: harvest() return True harvest() return False def maze_round(): n = get_world_size() amount = n * 2 ** (num_unlocked(Unlocks.Mazes) - 1) if num_items(Items.Weird_Substance) < amount: return False if get_entity_type() != Entities.Bush: if get_entity_type() != None: harvest() plant(Entities.Bush) use_item(Items.Weird_Substance, amount) return solve_maze() change_hat(Hats.Straw_Hat) cycle = 0 while True: e = get_entity_type() if e == Entities.Hedge or e == Entities.Treasure: solve_maze() if num_items(Items.Weird_Substance) >= WEIRD_HI: for i in range(MAZE_BATCH): if not maze_round(): break if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() step = cycle % 4 cycle += 1 if step == 0 and num_items(Items.Pumpkin) >= 2000: cact_round() elif step == 2 and num_items(Items.Carrot) >= PUMP_AT: pump_round() else: mixed_block()Changes from the previous revision
water() - def clear_tile(): - if get_entity_type() != None: - harvest() - if get_ground_type() == Grounds.Soil: - till() - def sort_line(dirn, n): for p in range(n - 1): elif mode == 4: cact_tile() - elif mode == 7: - clear_tile() move(North) x += D best = nb - def dino_dir(): - x = get_pos_x() - y = get_pos_y() - n = get_world_size() - if x == 0: - if y == 0: - return East - return South - if y % 2 == 0: - if x < n - 1: - return East - return North - if x > 1: - return West - if y == n - 1: - return West - return North - - def dino_round(): - run_all(7, 0, 0) - goto(0, 0) - change_hat(Hats.Dinosaur_Hat) - steps = 0 - limit = get_world_size() * get_world_size() * 90 - while steps < limit: - if not move(dino_dir()): - break - steps += 1 - change_hat(Hats.Straw_Hat) - def solve_maze(): dirs = [North, East, South, West] d = 0 steps = 0 - while get_entity_type() != Entities.Treasure and steps < 4000: + while get_entity_type() != Entities.Treasure and steps < 6000: steps += 1 r = (d + 1) % 4 if num_items(Items.Power) < SUN_AT and num_items(Items.Carrot) >= 100: sun_round() - step = cycle % 6 + step = cycle % 4 cycle += 1 - if step == 0 and num_items(Items.Pumpkin) >= 600: + if step == 0 and num_items(Items.Pumpkin) >= 2000: cact_round() elif step == 2 and num_items(Items.Carrot) >= PUMP_AT: pump_round() - elif step == 4 and num_items(Items.Cactus) >= 600: - dino_round() else: mixed_block()
- Write result the agent saw
Saved farm (276 lines). Game time: 5h 13m 12s elapsed, 46m 48s of budget remaining.
- run_program at 5h 13m for 900s (agent saw)
Ran farm for 15m of game time; it is still running. Inventory change: cactus +937024, carrot +7543224, fertilizer -224, gold +127776, hay +2785024, power +2581.01, pumpkin +677344, water +17690, weird_substance +3566032, wood +34993664. Game time: 5h 28m 22s elapsed, 31m 38s of budget remaining. Output: Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- pump_tile <- ensure <- fert use_item(Items.Fertilizer) ^^ -------------------------------------------------------------------- Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- sun_plant_tile <- ensure <- fert use_item(Items.Fertilizer) ^^ --------------------------------------------------------------------
hat.py
r12h 04mRanFinal
change_hat(Hats.Straw_Hat) print(num_items(Items.Bone))- Write result the agent saw
Saved hat (2 lines). Game time: 2h 4m 17s elapsed, 3h 55m 43s of budget remaining.
- run_program at 2h 04m for 10s (agent saw)
Ran hat for 1s of game time; it finished. Inventory change: bone +20449, power -0.03, water +1. Game time: 2h 4m 38s elapsed, 3h 55m 22s of budget remaining. Output: 20449
log
Step by step
- 0ssaidI'll start by observing the farm and checking the docs and research menu.
- 0s
observeresult
Game time: 10s elapsed, 5h 59m 50s of budget remaining. Program: none running. Inventory: empty. Farm 1x1. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Gr=grass. y= 0 _Gr3* Recent output: (none)
- 10s
docs_listresult
docs/home.md General Info unlocks/auto_unlock Auto Unlock unlocks/cactus Cactus unlocks/carrots Carrots unlocks/costs Costs unlocks/debug Debug unlocks/debug_2 Debug_2 unlocks/dictionaries Dictionaries unlocks/dinosaurs Dinosaurs unlocks/expand Expand unlocks/fertilizer Fertilizer unlocks/functions Functions unlocks/grass Grass unlocks/hats Hats unlocks/import Import unlocks/leaderb…
- 20s
researchresult
auto_unlock (Auto Unlock) level 0/1; cost pumpkin 5000; requires costs ## Auto Unlock Automatically unlock things. unlock(Unlocks.Megafarm) cactus (Cactus) level 0/6; cost pumpkin 5000; requires pumpkins ## Cactus Cactus! plant(Entities.Cactus) carrots (Carrots) level 0/10; cost wood 50; requires plant ## Carrots Till the soil and plant carrots. till() plant(Entities.Carrot) costs (Costs) le…
- 30s
docs_readpath="docs/home.md"result
## General Info [External Editor](docs/external_editor.md) [First Program](docs/first_program.md) [Getting Started](docs/getting_started.md) [Loading Backups](docs/backup.md) [Credits](docs/credits.md) ## Programming [Comments](docs/scripting/comments.md) ## Unlocks [Grass](unlocks/grass) ## Built-in Functions [do_a_flip](functions/do_a_flip) [harvest]…
- 40s
docs_readpath="docs/first_program.md"result
# First Program ## Text editor All programming is done in code windows. Each code window corresponds to a text file containing code. You can rename the file by clicking on its name at the top of the window. The code can be edited like in any text editor as long as it's not running. You can execute the program directly by pressing the green play button in the code window.  You c…
- 50s
docs_readpath="unlocks/grass"result
## Grass Increases the yield of grass. 100% => 200% ### Unlock Cost [Current cost: hay=300] Game time: 1m elapsed, 5h 59m of budget remaining.
- 1m 00s
docs_readpath="functions/harvest"result
harvest() Harvests the entity under the drone. If you harvest an entity that can't be harvested, it will be destroyed. returns True if an entity was removed, False otherwise. takes 200 ticks to execute if an entity was removed, 1 tick otherwise. example: harvest() Game time: 1m 10s elapsed, 5h 58m 50s of budget remaining.
- 1m 10s
write_programname="h0" · evidenceresult
Saved h0 (40 lines). Game time: 1m 20s elapsed, 5h 58m 40s of budget remaining.
- 1m 20s
run_programname="h0" seconds=60result
Ran h0 for 20s of game time; it finished. Inventory change: hay +40. Game time: 1m 50s elapsed, 5h 58m 10s of budget remaining. Output: (none)
- 1m 50s
buy_upgradeupgrades=["loops","speed"] · evidenceresult
Bought loops, now level 1. Paid hay 5. Its tutorial is docs page docs/scripting/while.md. Bought speed, now level 1. Paid hay 20. Its tutorial is docs page docs/unlocks/speed.md. Game time: 2m elapsed, 5h 58m of budget remaining.
- 2m 00s
write_programname="loop" · evidenceresult
Saved loop (2 lines). Game time: 2m 10s elapsed, 5h 57m 50s of budget remaining.
- 2m 10s
run_programname="loop" seconds=40result
Ran loop for 40s of game time; it is still running. Inventory change: hay +1. Game time: 3m elapsed, 5h 57m of budget remaining. Output: (none)
- 3m 00ssaidHarvest loop is running but barely producing hay — checking the farm state to see why.
- 3m 00s
observeresult
Game time: 3m 10s elapsed, 5h 56m 50s of budget remaining. Program: loop (running). Inventory: hay 16. Farm 1x1. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Gr=grass. y= 0 _Gr2* Recent output: (none)
- 3m 10s
waitseconds=300 until_resources={"hay":30}result
Waited 5m (time up). Program: loop running. Inventory change: no change. Game time: 8m 20s elapsed, 5h 51m 40s of budget remaining.
- 8m 20s
stop_programresult
Program stopped. Game time: 8m 30s elapsed, 5h 51m 30s of budget remaining.
- 8m 30s
inspect_tilex=0 y=0result
(0,0) `x = 0, y = 0` ### `Entities.Grass` Total grow time: 0.5 seconds Grown 100% When harvested, gives: ### `Grounds.Grassland` Water level: 0 Yield: hay 1 Game time: 8m 40s elapsed, 5h 51m 20s of budget remaining.
- 8m 40s
docs_readpath="docs/scripting/while.md"result
# While Loop You have unlocked the `while` loop and the values `True` and `False`. The `while` loop keeps executing the loop body as long as the condition is `True`. `while condition: #loop body` Don't worry about creating infinite loops. The delays in the execution will prevent the program from freezing. ## For Beginners Perhaps you have already tried to put several `harvest()` calls in a row…
- 8m 50s
docs_readpath="objects/grass"result
## Grass Grows automatically on grassland. Harvest it to obtain Items.Hay. Base growth time between 0.5 and 0.5 seconds. Can grow on soil or grassland. Game time: 9m elapsed, 5h 51m of budget remaining.
- 9m 00s
run_programname="loop" seconds=30result
Ran loop for 30s of game time; it is still running. Inventory change: hay +1. Game time: 9m 40s elapsed, 5h 50m 20s of budget remaining. Output: (none)
- 9m 40s
observeresult
Game time: 9m 50s elapsed, 5h 50m 10s of budget remaining. Program: loop (running). Inventory: hay 17. Farm 1x1. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Gr=grass. y= 0 _Gr2* Recent output: (none)
- 9m 50ssaidThe while loop appears to harvest grass before it regrows (destroying it), while the straight-line program worked. I'll use a long straight-line harvester to earn enough hay for expand/plant/senses.
- 9m 50s
write_programname="h1" · evidenceresult
Saved h1 (313 lines). Game time: 10m elapsed, 5h 50m of budget remaining.
- 10m 00s
run_programname="h1" seconds=200result
Ran h1 for 1m 44s of game time; it finished. Inventory change: no change. Game time: 11m 54s elapsed, 5h 48m 6s of budget remaining. Output: (none)
- 11m 54s
docs_readpath="functions/do_a_flip"result
do_a_flip() Makes the drone do a flip! This action is not affected by speed upgrades. returns None takes 1s to execute. example: while True: do_a_flip() Game time: 12m 4s elapsed, 5h 47m 56s of budget remaining. - 12m 04s
docs_readpath="docs/unlocks/speed.md"result
# Speed Upgrade The execution speed has been doubled. The problem is that the drone now harvests faster than the grass can grow resulting in no harvest at all. To deal with this [if](docs/scripting/if.md) branches and the [can_harvest](functions/can_harvest) function are now unlocked. ## Checking Before Harvesting So far we only had `True` and `False` as conditions, which is of course not very us…
- 12m 14ssaidGot it — `can_harvest()` and `if` are unlocked. Fixing the loop now.
- 12m 14s
write_programname="loop" · evidenceresult
Saved loop (3 lines). Game time: 12m 24s elapsed, 5h 47m 36s of budget remaining.
- 12m 24s
run_programname="loop" seconds=60result
Ran loop for 1m of game time; it is still running. Inventory change: hay +120. Game time: 13m 34s elapsed, 5h 46m 26s of budget remaining. Output: (none)
- 13m 34ssaidNow at ~137 hay. Buying expand + plant and reading their docs in parallel.
- 13m 34s
buy_upgradeupgrades=["expand","plant"] · evidenceresult
Bought expand, now level 1. Paid hay 30. Its tutorial is docs page docs/unlocks/expand_1.md. Bought plant, now level 1. Paid hay 50. Its tutorial is docs page docs/unlocks/plant.md. Game time: 13m 44s elapsed, 5h 46m 16s of budget remaining.
- 13m 44s
docs_readpath="unlocks/expand"result
## Expand Expands the farm. This also clears the farm. 1x3 => 3x3 ### Unlock Cost [Current cost: wood=20] [Tutorial](docs/unlocks/expand_1.md) Game time: 13m 54s elapsed, 5h 46m 6s of budget remaining.
- 13m 54s
docs_readpath="unlocks/plant"result
## Plant Unlocks planting. plant(Entities.Bush) [Tutorial](docs/unlocks/plant.md) Game time: 14m 4s elapsed, 5h 45m 56s of budget remaining.
- 14m 04s
docs_readpath="docs/unlocks/expand_1.md"result
# Expand 1 Your farm has grown! This space is not much use if you can't move the drone, so there is a new function `move()` that moves the drone. `move()` requires that you specify the direction in which you want the drone to move. There are four new constants for this: `North, East, South, West` For example, `move(North)` will move the drone one square to the north. If you move over the edge of…
- 14m 14s
docs_readpath="docs/unlocks/plant.md"result
# Plant Grass is nice because it grows automatically. All other plants have to be planted with the `plant()` function. The only plant you can plant right now is a bush. You can pass the type of plant you want to plant to the function like this: `plant(Entities.Bush)` This will plant a bush under the drone. Call `clear()` to reset the farm to all grass and reset the drone position. It seems tha…
- 14m 24s
observeresult
Game time: 14m 34s elapsed, 5h 45m 26s of budget remaining. Program: loop (running). Inventory: hay 176. Farm 1x3. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Gr=grass. y= 2 _Gr3 y= 1 _Gr3 y= 0 _Gr1* Recent output: (none)
- 14m 34s
docs_searchquery="bush"result
docs/home.md: …functions/plant) [tap](functions/tap) ## Items [Hay](items/hay) [Wood](items/wood) ## Entities [Bush](objects/bush) [Grass](objects/grass) ## Grounds [Grassland](objects/grassland) [Soil](objects/soil)… unlocks/lists: …## Lists Use lists to store lots of values. plants = [Entities.Grass, Entities.Bush, Entities.Tree] for p in plants: plant(p) move(North) ### Unlock Cost [Current cos…
- 14m 44s
write_programname="bush" · evidenceresult
Saved bush (5 lines). Game time: 14m 54s elapsed, 5h 45m 6s of budget remaining.
- 14m 54s
run_programname="bush" seconds=90result
Ran bush for 1m 30s of game time; it is still running. Inventory change: hay +7, wood +53. Game time: 16m 34s elapsed, 5h 43m 26s of budget remaining. Output: (none)
- 16m 34s
docs_readpath="objects/bush"result
## Bush A small bush that drops Items.Wood. Base growth time between 3.2 and 4.8 seconds. Can grow on grassland or soil. For more related information see: [Plant](docs/unlocks/plant.md) Game time: 16m 44s elapsed, 5h 43m 16s of budget remaining.
- 16m 44ssaidHave ~183 hay, 53 wood. Buying expand (3x3) + operators now; carrots once wood reaches 50 again.
- 16m 44s
buy_upgradeupgrades=["expand","operators"] · evidenceresult
Bought expand, now level 2. Paid wood 20. Its tutorial is docs page docs/unlocks/expand_1.md. Bought operators, now level 1. Paid hay 150, wood 10. Its tutorial is docs page docs/scripting/operators.md. Game time: 16m 54s elapsed, 5h 43m 6s of budget remaining.
- 16m 54s
docs_readpath="unlocks/senses"result
## Senses The drone can see what's under it and where it is. if get_pos_x() < 5 and num_items(Items.Wood) < 200: plant(Entities.Bush) ### Unlock Cost [Current cost: hay=100] Game time: 17m 4s elapsed, 5h 42m 56s of budget remaining. - 17m 04s
write_programname="bush3" · evidenceresult
Saved bush3 (39 lines). Game time: 17m 14s elapsed, 5h 42m 46s of budget remaining.
- 17m 14s
run_programname="bush3" seconds=120result
Ran bush3 for 2m of game time; it is still running. Inventory change: hay +37, wood +106. Game time: 19m 24s elapsed, 5h 40m 36s of budget remaining. Output: (none)
- 19m 24s
buy_upgradeupgrades=["carrots"] · evidenceresult
Bought carrots, now level 1. Paid wood 50. Its tutorial is docs page docs/unlocks/carrots.md. Game time: 19m 34s elapsed, 5h 40m 26s of budget remaining.
- 19m 34s
docs_readpath="unlocks/carrots"result
## Carrots Increases the yield and cost of carrots. 100% => 200% ### Unlock Cost [Current cost: wood=250] [Tutorial](docs/unlocks/carrots.md) Game time: 19m 44s elapsed, 5h 40m 16s of budget remaining.
- 19m 44s
docs_readpath="docs/scripting/operators.md"result
# Operators arithmetic operators: `+, -, *, /, //, %, **` comparison operators: `==, !=, <=, >=, <, >` boolean operators: `not, and, or` Note: All numbers in the game are floating point numbers. So all arithmetic operators are floating point operators. `//` is defined to just floor the number after the division. For assignment operators you need to unlock the "Variables" unlock. ## Introduction…
- 19m 54s
docs_readpath="docs/unlocks/carrots.md"result
# Carrots Before you can plant carrots with `plant(Entities.Carrot)`, you have to till the soil. This will change the ground to `Grounds.Soil`. To till the soil, simply call `till()`. Calling `till()` again will change it back to `Grounds.Grassland`. Planting carrots costs wood and hay. These items will be automatically removed when calling `plant(Entities.Carrot)`. You can see the cost of any p…
- 20m 04s
docs_searchquery="growth time"result
objects/bush: …## Bush A small bush that drops Items.Wood. Base growth time between 3.2 and 4.8 seconds. Can grow on grassland or soil. For more related information see: [Plant](docs/unlocks/plant.md)… objects/carrot: …## Carrot Carrots! Base growth time between 4.8 and 7.2 seconds. Can grow on soil. ### Plant Cost [Current cost: hay=1, wood=1] For more related information see: [Carrots](docs/unlo…
- 20m 14s
waitseconds=120 until_resources={"hay":100}result
Waited 0s (hay reached 146). Program: bush3 running. Inventory change: no change. Game time: 20m 24s elapsed, 5h 39m 36s of budget remaining.
- 20m 24ssaidBuying senses (hay 146 now) and reading its tutorial so I can write a position-aware 3x3 program with grass, bushes, and carrots.
- 20m 24s
buy_upgradeupgrades=["senses"] · evidenceresult
Bought senses, now level 1. Paid hay 100. Its tutorial is docs page docs/unlocks/senses.md. Game time: 20m 34s elapsed, 5h 39m 26s of budget remaining.
- 20m 34s
docs_readpath="docs/unlocks/senses.md"result
# Senses The drone can see now! The functions `get_pos_x()` and `get_pos_y()` return the current x and y position of the drone. At the start position they are both `0`. The x position increases by `1` every tile towards `East` and the y position increases by `1` every tile towards `North`. `num_items(item)` returns how many of an item you have. For example `num_items(Items.Hay)` returns how muc…
- 20m 44s
observeresult
Game time: 20m 54s elapsed, 5h 39m 6s of budget remaining. Program: bush3 (running). Inventory: hay 49, wood 213. Farm 3x3. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Bu=bush, Gr=grass. y= 2 _Bu3 _Bu2 _Bu1 y= 1 _Gr3 _Bu3 _Bu1 y= 0 _Bu3 _Bu2 _Bu3* Recent output: …
- 20m 54s
write_programname="farm3" · evidenceresult
Saved farm3 (19 lines). Game time: 21m 4s elapsed, 5h 38m 56s of budget remaining.
- 21m 04s
run_programname="farm3" seconds=90result
Ran farm3 for 1m 30s of game time; it is still running. Inventory change: carrot +39, hay +46, wood +16. Game time: 22m 44s elapsed, 5h 37m 16s of budget remaining. Output: (none)
- 22m 44ssaidBuying variables and watering now; reading their tutorials in the same step.
- 22m 44s
buy_upgradeupgrades=["variables","watering"] · evidenceresult
Bought variables, now level 1. Paid carrot 35. Its tutorial is docs page docs/scripting/variables.md. Bought watering, now level 1. Paid wood 50. Its tutorial is docs page docs/unlocks/watering.md. Game time: 22m 54s elapsed, 5h 37m 6s of budget remaining.
- 22m 54s
docs_readpath="unlocks/watering"result
## Watering Receive more water. 0.1/s => 0.2/s ### Unlock Cost [Current cost: wood=200] [Tutorial](docs/unlocks/watering.md) Game time: 23m 4s elapsed, 5h 36m 56s of budget remaining.
- 23m 04s
docs_readpath="unlocks/trees"result
## Trees Unlocks trees. plant(Entities.Trees) ### Unlock Cost [Current cost: wood=50, carrot=70] Game time: 23m 14s elapsed, 5h 36m 46s of budget remaining.
- 23m 14s
docs_readpath="docs/unlocks/watering.md"result
# Watering Plants grow faster when they are watered. The ground has a water level ranging from `0` to `1`. The function `get_water()` returns the water level of the ground it is over. The growth speed of a plant scales linearly from 1x speed at water level 0 to 5x speed at water level 1. The ground dries up over time: On average, it loses 1% of its current water per second, but there is some ran…
- 23m 24s
docs_readpath="docs/scripting/variables.md"result
# Variables Variables can be thought of as named containers that can hold a value. The `=` operator is used to declare a variable and store a value in it. `variable_name = value` The left hand side of the operator is the variable name. You can give it any name you want. The right hand side is an expression whose resulting value will be stored in the variable. Declare a variable named `a` and st…
- 23m 34s
waitseconds=120 until_resources={"carrot":40}result
Waited 0s (carrot reached 40). Program: farm3 running. Inventory change: no change. Game time: 23m 44s elapsed, 5h 36m 16s of budget remaining.
- 23m 44s
buy_upgradeupgrades=["functions"] · evidenceresult
Bought functions, now level 1. Paid carrot 40. Its tutorial is docs page docs/scripting/functions.md. Game time: 23m 54s elapsed, 5h 36m 6s of budget remaining.
- 23m 54s
docs_readpath="unlocks/pumpkins"result
## Pumpkins Pumpkins! plant(Entities.Pumpkin) ### Unlock Cost [Current cost: wood=500, carrot=200] Game time: 24m 4s elapsed, 5h 35m 56s of budget remaining.
- 24m 04s
docs_readpath="unlocks/sunflowers"result
## Sunflowers Sunflowers and Power. plant(Entities.Sunflowers) ### Unlock Cost [Current cost: carrot=500] Game time: 24m 14s elapsed, 5h 35m 46s of budget remaining.
- 24m 14s
waitseconds=120 until_resources={"carrot":70}result
Waited 52s (carrot reached 70). Program: farm3 running. Inventory change: carrot +49, hay +15, water +5, wood +18. Game time: 25m 16s elapsed, 5h 34m 44s of budget remaining.
- 25m 16s
researchresult
auto_unlock (Auto Unlock) level 0/1; cost pumpkin 5000; requires costs ## Auto Unlock Automatically unlock things. unlock(Unlocks.Megafarm) cactus (Cactus) level 0/6; cost pumpkin 5000; requires pumpkins ## Cactus Cactus! plant(Entities.Cactus) carrots (Carrots) level 1/10; cost wood 250; can buy now; tutorial docs/unlocks/carrots.md ## Carrots Increases the yield and cost of carrots. 100% =…
- 25m 26ssaidBuying speed (cheap at 20 wood) and trees now; reading the trees and functions docs alongside.
- 25m 26s
buy_upgradeupgrades=["speed","trees"] · evidenceresult
Bought speed, now level 2. Paid wood 20. Its tutorial is docs page docs/unlocks/speed.md. Bought trees, now level 1. Paid wood 50, carrot 70. Its tutorial is docs page docs/unlocks/trees.md. Game time: 25m 36s elapsed, 5h 34m 24s of budget remaining.
- 25m 36s
docs_readpath="docs/scripting/functions.md"result
# Functions Use the `def` keyword to define a new function: `def f(arg1, arg2 = False): #function code` You can use the call operator `()` to call the function: `f(42)` Also see [Scopes](docs/scripting/scopes.md) to learn about local and global variables in functions. ## Introduction You've already seen built-in functions like `harvest()`. You can also define your own functions which allows st…
- 25m 46s
docs_searchquery="tree"result
docs/home.md: …md) [Plant](docs/unlocks/plant.md) [Senses](docs/unlocks/senses.md) [Speed](docs/unlocks/speed.md) [Trees](docs/unlocks/trees.md) [Variables](docs/scripting/variables.md) [Watering](docs/unlocks/watering.md) ## Built-in Functions [can_harvest](functions/can_harvest) [clear](fun… unlocks/lists: …## Lists Use lists to store lots of values. plants = [Entities.Grass, Entities.Bush, Enti…
- 25m 56s
waitseconds=120 until_resources={"carrot":20}result
Waited 0s (carrot reached 44). Program: farm3 running. Inventory change: no change. Game time: 26m 6s elapsed, 5h 33m 54s of budget remaining.
- 26m 06s
docs_searchquery="world_size"result
docs/home.md: … [get_pos_x](functions/get_pos_x) [get_pos_y](functions/get_pos_y) [get_water](functions/get_water) [get_world_size](functions/get_world_size) [harvest](functions/harvest) [move](functions/move) [num_items](functions/num_items) [num_unlocked](functions/num_unlocked) [pet_the_pigg… unlocks/debug_2: …## Debug_2 Functions to temporarily slow down the execution and make the farm smaller…
- 26m 16s
docs_readpath="docs/unlocks/trees.md"result
# Trees [Trees](objects/tree) are a better way to get wood than bushes. They give 5 wood each. Like bushes, they can be planted on grass or soil. Trees like to have some space and planting them right next to each other will slow down their growth. The growing time is doubled for each tree that is on a tile directly to the north, east, west or south of it. So if you plant trees on every tile, they…
- 26m 26s
buy_upgradeupgrades=["expand"] · evidenceresult
Bought expand, now level 3. Paid wood 30, carrot 20. Its tutorial is docs page docs/unlocks/expand_1.md. Game time: 26m 36s elapsed, 5h 33m 24s of budget remaining.
- 26m 36s
write_programname="farm" · evidenceresult
Saved farm (26 lines). Game time: 26m 46s elapsed, 5h 33m 14s of budget remaining.
- 26m 46s
run_programname="farm" seconds=120result
Ran farm for 2m of game time; it is still running. Inventory change: carrot +129, hay -10, water -24, wood +529. Game time: 28m 56s elapsed, 5h 31m 4s of budget remaining. Output: (none)
- 28m 56s
observeresult
Game time: 29m 6s elapsed, 5h 30m 54s of budget remaining. Program: farm (running). Inventory: hay 187, wood 819, carrot 206. Farm 4x4. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Gr=grass, Tr=tree, Ca=carrot. y= 3 _Gr3 _Tr3 #Ca3 _Tr1 y= 2 _Tr3 #Ca3 _Tr3 #Ca1 y= 1…
- 29m 06s
buy_upgradeupgrades=["import","carrots"] · evidenceresult
Bought import, now level 1. Paid carrot 80. Its tutorial is docs page docs/scripting/import.md. Bought carrots, now level 2. Paid wood 250. Its tutorial is docs page docs/unlocks/carrots.md. Game time: 29m 16s elapsed, 5h 30m 44s of budget remaining.
- 29m 16s
waitseconds=120 until_resources={"carrot":200}result
Waited 24s (carrot reached 207). Program: farm running. Inventory change: carrot +50, hay -16, water +1, wood +136. Game time: 29m 50s elapsed, 5h 30m 10s of budget remaining.
- 29m 50s
researchresult
auto_unlock (Auto Unlock) level 0/1; cost pumpkin 5000; requires costs ## Auto Unlock Automatically unlock things. unlock(Unlocks.Megafarm) cactus (Cactus) level 0/6; cost pumpkin 5000; requires pumpkins ## Cactus Cactus! plant(Entities.Cactus) carrots (Carrots) level 2/10; cost wood 1250; available, not affordable; tutorial docs/unlocks/carrots.md ## Carrots Increases the yield and cost of …
- 30m 00ssaidBuying pumpkins now and reading its docs; expand to 6x6 and speed next once carrots recover.
- 30m 00s
buy_upgradeupgrades=["pumpkins"] · evidenceresult
Bought pumpkins, now level 1. Paid wood 500, carrot 200. Its tutorial is docs page docs/unlocks/pumpkins.md. Game time: 30m 10s elapsed, 5h 29m 50s of budget remaining.
- 30m 10s
docs_readpath="docs/unlocks/pumpkins.md"result
# Pumpkins [Pumpkins](objects/pumpkin) grow like carrots on tilled soil. Planting them costs carrots. When all the pumpkins in a square are fully grown, they will grow together to form a giant pumpkin. Unfortunately, pumpkins have a 20% chance of dying once they are fully grown, so you will need to replant the dead ones if you want them to merge. When a pumpkin dies, it leaves behind a dead pum…
- 30m 20s
docs_readpath="objects/pumpkin"result
## Pumpkin Pumpkins grow together when they are next to other fully grown pumpkins. About 1 in 5 pumpkins dies when it grows up. Base growth time between 0.2 and 3.8 seconds. Can grow on soil. ### Plant Cost [Current cost: carrot=1] For more related information see: [Pumpkins](docs/unlocks/pumpkins.md) Game time: 30m 30s elapsed, 5h 29m 30s of budget remaining.
- 30m 30s
docs_readpath="docs/unlocks/expand_2.md"result
# Expand 2 Your farm has expanded again! Now the tiles are no longer in a nice row, so you need to find a way to traverse a square grid. With the `while` loop this is not possible until you unlock senses and operators. It is time to introduce the `for` loop. You can read all about the `for` loop on the [For Loop](docs/scripting/for.md) page, but for now you will only need it to repeat code a fix…
- 30m 40s
waitseconds=120 until_resources={"carrot":50}result
Waited 0s (carrot reached 163). Program: farm running. Inventory change: no change. Game time: 30m 50s elapsed, 5h 29m 10s of budget remaining.
- 30m 50s
buy_upgradeupgrades=["expand","speed"] · evidenceresult
Bought expand, now level 4. Paid wood 100, carrot 50. Its tutorial is docs page docs/unlocks/expand_1.md. Bought speed, now level 3. Paid wood 50, carrot 50. Its tutorial is docs page docs/unlocks/speed.md. Game time: 31m elapsed, 5h 29m of budget remaining.
- 31m 00s
docs_searchquery="dead"result
docs/home.md: …n](items/pumpkin) [Water](items/water) ## Entities [Bush](objects/bush) [Carrot](objects/carrot) [Dead_Pumpkin](objects/dead_pumpkin) [Grass](objects/grass) [Pumpkin](objects/pumpkin) [Tree](objects/tree) ## Grounds [Grassland](objects/grassland) [Soil](objects/soil)… docs/unlocks/pumpkins.md: … pumpkin. Unfortunately, pumpkins have a 20% chance of dying once they are fully grown, s…
- 31m 10s
docs_readpath="docs/scripting/for.md"result
# For Loop The `for` loop works like in Python. (Called a foreach loop in some languages, not to be confused with the C-style for loop, which is a different thing). `for i in sequence: #do something with i` Similar to the `while` loop, the `for` loop also repeatedly calls a block of code. Instead of looping based on a condition, it executes the loop body once for each element in a sequence. ##…
- 31m 20s
write_programname="farm" · evidenceresult
Stop the program before editing it.
- 31m 30s
stop_programresult
Program stopped. Game time: 31m 40s elapsed, 5h 28m 20s of budget remaining.
- 31m 40s
write_programname="farm" · evidenceresult
Saved farm (68 lines). Game time: 31m 50s elapsed, 5h 28m 10s of budget remaining.
- 31m 50ssaidRunning the new 6x6 mode-switching program (trees/carrots/grass, with pumpkin rounds when carrots pile up).
- 31m 50s
run_programname="farm" seconds=180result
Ran farm for 3m of game time; it is still running. Inventory change: carrot -40, hay -55, pumpkin +864, water -2, wood +68. Game time: 35m elapsed, 5h 25m of budget remaining. Output: (none)
- 35m 00s
observeresult
Game time: 35m 10s elapsed, 5h 24m 50s of budget remaining. Program: farm (running). Inventory: hay 29, wood 727, carrot 111, pumpkin 864. Farm 6x6. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Gr=grass, Tr=tree, Ca=carrot. y= 5 _Gr3 _Tr1 #-- #-- #Ca3 _Tr2 y= 4 _T…
- 35m 10s
docs_readpath="unlocks/fertilizer"result
## Fertilizer Grow plants instantly. use_item(Items.Fertilizer) ### Unlock Cost [Current cost: wood=500] Game time: 35m 20s elapsed, 5h 24m 40s of budget remaining.
- 35m 20s
docs_readpath="unlocks/mazes"result
## Mazes A maze with a treasure in the middle. if get_entity_type() == Entities.Treasure: harvest() ### Unlock Cost [Current cost: weird_substance=1000] Game time: 35m 30s elapsed, 5h 24m 30s of budget remaining. - 35m 30s
docs_readpath="unlocks/megafarm"result
## Megafarm More drones! spawn_drone(task) ### Unlock Cost [Current cost: gold=2000] Game time: 35m 40s elapsed, 5h 24m 20s of budget remaining.
- 35m 40sthoughtHay has crashed to 29 since carrots eat hay, so I'll adjust odd-parity tiles to dynamically pick grass or carrots based on hay stock. I'm also buying fertilizer with 727 wood to unlock the mazes → gold → megafarm path.
- 35m 40s
stop_programresult
Program stopped. Game time: 35m 50s elapsed, 5h 24m 10s of budget remaining.
- 35m 50s
buy_upgradeupgrades=["fertilizer"] · evidenceresult
Bought fertilizer, now level 1. Paid wood 500. Its tutorial is docs page docs/unlocks/fertilizer.md. Game time: 36m elapsed, 5h 24m of budget remaining.
- 36m 00s
docs_readpath="docs/unlocks/fertilizer.md"result
# Fertilizer At some point, waiting for the plants to grow is just not efficient enough anymore. Similar to water, you will automatically receive 1 fertilizer every 10 seconds, doubling with each upgrade. Fertilizer can make plants grow instantly. `use_item(Items.Fertilizer)` reduces the remaining growing time of the plant under the drone by 2 seconds. This has some side effects. Plants grown w…
- 36m 10s
write_programname="farm" · evidenceresult
Saved farm (77 lines). Game time: 36m 20s elapsed, 5h 23m 40s of budget remaining.
- 36m 20s
run_programname="farm" seconds=240result
Ran farm for 4m of game time; it is still running. Inventory change: carrot -90, fertilizer -2, hay +298, pumpkin +627, water -4, weird_substance +93, wood +1428. Game time: 40m 30s elapsed, 5h 19m 30s of budget remaining. Output: (none)
- 40m 30s
buy_upgradeupgrades=["watering"] · evidenceresult
Bought watering, now level 2. Paid wood 200. Its tutorial is docs page docs/unlocks/watering.md. Game time: 40m 40s elapsed, 5h 19m 20s of budget remaining.
- 40m 40s
buy_upgradeupgrades=["grass","debug","speed"] · evidenceresult
Bought grass, now level 2. Paid hay 300. Could not buy debug: Not enough resources. Could not buy speed: Not enough resources. Game time: 40m 50s elapsed, 5h 19m 10s of budget remaining.
- 40m 50s
researchresult
auto_unlock (Auto Unlock) level 0/1; cost pumpkin 5000; requires costs ## Auto Unlock Automatically unlock things. unlock(Unlocks.Megafarm) cactus (Cactus) level 0/6; cost pumpkin 5000; available, not affordable ## Cactus Cactus! plant(Entities.Cactus) carrots (Carrots) level 2/10; cost wood 1250; can buy now; tutorial docs/unlocks/carrots.md ## Carrots Increases the yield and cost of carrot…
- 41m 00ssaidBuying expand (8x8) and grass level 3, and raising the pumpkin-round carrot threshold so carrots accumulate for the speed upgrade (500 carrots).
- 41m 00s
buy_upgradeupgrades=["expand","grass"] · evidenceresult
Bought expand, now level 5. Paid pumpkin 1000. Its tutorial is docs page docs/unlocks/expand_1.md. Bought grass, now level 3. Paid wood 500. Game time: 41m 10s elapsed, 5h 18m 50s of budget remaining.
- 41m 10s
stop_programresult
Program stopped. Game time: 41m 20s elapsed, 5h 18m 40s of budget remaining.
- 41m 20s
write_programname="farm" · evidenceresult
Saved farm (80 lines). Game time: 41m 30s elapsed, 5h 18m 30s of budget remaining.
- 41m 30s
run_programname="farm" seconds=300result
Ran farm for 5m of game time; it is still running. Inventory change: carrot +293, fertilizer -2, hay +210, water -4, weird_substance +71, wood +2473. Game time: 46m 40s elapsed, 5h 13m 20s of budget remaining. Output: (none)
- 46m 40s
buy_upgradeupgrades=["carrots","fertilizer"] · evidenceresult
Bought carrots, now level 3. Paid wood 1250. Its tutorial is docs page docs/unlocks/carrots.md. Bought fertilizer, now level 2. Paid wood 1500. Its tutorial is docs page docs/unlocks/fertilizer.md. Game time: 46m 50s elapsed, 5h 13m 10s of budget remaining.
- 46m 50s
observeresult
Game time: 47m elapsed, 5h 13m of budget remaining. Program: farm (running). Inventory: hay 397, wood 1189, carrot 456, pumpkin 491, weird_substance 193, water 1. Farm 8x8. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Gr=grass, Tr=tree, Ca=carrot. y= 7 _Gr3 _Tr3 #Ca3 _…
- 47m 00s
waitseconds=120 until_resources={"carrot":500}result
Waited 26s (carrot reached 500). Program: farm running. Inventory change: carrot +44, fertilizer -1, hay +12, water -1, weird_substance +6, wood +137. Game time: 47m 37s elapsed, 5h 12m 23s of budget remaining.
- 47m 37s
buy_upgradeupgrades=["speed","trees"] · evidenceresult
Bought speed, now level 4. Paid carrot 500. Its tutorial is docs page docs/unlocks/speed.md. Bought trees, now level 2. Paid hay 300. Its tutorial is docs page docs/unlocks/trees.md. Game time: 47m 47s elapsed, 5h 12m 13s of budget remaining.
- 47m 47ssaidSpeed 4 and trees 2 bought. Next: debug (cheap, unlocks timing path), then wait for 500 carrots for sunflowers.
- 47m 47s
buy_upgradeupgrades=["debug"] · evidenceresult
Bought debug, now level 1. Paid hay 50, wood 50. Its tutorial is docs page docs/scripting/debug.md. Game time: 47m 57s elapsed, 5h 12m 3s of budget remaining.
- 47m 57s
waitseconds=300 until_resources={"carrot":500}result
Waited 2m 34s (carrot reached 500). Program: farm running. Inventory change: carrot +484, hay +252, weird_substance +194, wood +3680. Game time: 50m 40s elapsed, 5h 9m 20s of budget remaining.
- 50m 40s
buy_upgradeupgrades=["sunflowers","watering"] · evidenceresult
Bought sunflowers, now level 1. Paid carrot 500. Its tutorial is docs page docs/unlocks/sunflowers.md. Bought watering, now level 3. Paid wood 800. Its tutorial is docs page docs/unlocks/watering.md. Game time: 50m 50s elapsed, 5h 9m 10s of budget remaining.
- 50m 50s
docs_readpath="docs/unlocks/sunflowers.md"result
# Sunflowers [Sunflowers](objects/sunflower) collect the power of the sun. You can harvest that power. Planting them works exactly like planting carrots or pumpkins. Harvesting a grown sunflower yields power. If there are at least 10 sunflowers on the farm and you harvest the one with the largest number of petals you get `8` times more power! If you harvest a sunflower while there is another s…
- 51m 00s
docs_readpath="objects/sunflower"result
## Sunflower Sunflowers collect the power from the sun. Harvesting them will give you Items.Power. If you harvest a sunflower with the maximum number of petals you get bonus power. Base growth time between 5.6 and 8.4 seconds. Can grow on soil. ### Plant Cost [Current cost: carrot=1] For more related information see: [Sunflowers](docs/unlocks/sunflowers.md) Game time: 51m 10s elapsed, 5h 8m 50s…
- 51m 10s
researchresult
auto_unlock (Auto Unlock) level 0/1; cost pumpkin 5000; requires costs ## Auto Unlock Automatically unlock things. unlock(Unlocks.Megafarm) cactus (Cactus) level 0/6; cost pumpkin 5000; available, not affordable ## Cactus Cactus! plant(Entities.Cactus) carrots (Carrots) level 3/10; cost wood 6250; available, not affordable; tutorial docs/unlocks/carrots.md ## Carrots Increases the yield and …
- 51m 20ssaidPlan: buy grass 4 (2500 wood); add a sunflower round (power doubles drone speed) to the farm program; lower pumpkin threshold later after lists. Writing the program now alongside the purchase.
- 51m 20s
buy_upgradeupgrades=["grass"] · evidenceresult
Bought grass, now level 4. Paid wood 2500. Game time: 51m 30s elapsed, 5h 8m 30s of budget remaining.
- 51m 30s
stop_programresult
Program stopped. Game time: 51m 40s elapsed, 5h 8m 20s of budget remaining.
- 51m 40s
write_programname="farm" · evidenceresult
Saved farm (115 lines). Game time: 51m 50s elapsed, 5h 8m 10s of budget remaining.
- 51m 50s
run_programname="farm" seconds=120result
Ran farm for 2m of game time; it is still running. Inventory change: carrot +98, fertilizer -4, power +348.81, water -8, weird_substance +171, wood +929. Game time: 54m elapsed, 5h 6m of budget remaining. Output: (none)
- 54m 00s
observeresult
Game time: 54m 10s elapsed, 5h 5m 50s of budget remaining. Program: farm (running). Inventory: hay 423, wood 5296, carrot 486, pumpkin 491, weird_substance 725, power 342.06. Farm 8x8. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Ca=carrot, Tr=tree, Gr=grass. y= 7 #Ca3 _…
- 54m 10s
waitseconds=300 until_resources={"carrot":500}result
Waited 0s (carrot reached 518). Program: farm running. Inventory change: no change. Game time: 54m 20s elapsed, 5h 5m 40s of budget remaining.
- 54m 20ssaidBuying lists (500 carrots) and watering 4 (3200 wood); reading lists docs in parallel. After that I'll lower the pumpkin threshold.
- 54m 20s
buy_upgradeupgrades=["lists","watering"] · evidenceresult
Bought lists, now level 1. Paid carrot 500. Its tutorial is docs page docs/scripting/lists.md. Bought watering, now level 4. Paid wood 3200. Its tutorial is docs page docs/unlocks/watering.md. Game time: 54m 30s elapsed, 5h 5m 30s of budget remaining.
- 54m 30s
docs_readpath="docs/scripting/lists.md"result
# Lists Lists are an easy way to store multiple values in a single variable. You can create new lists like this: `some_list = [2, True, Items.Hay]` The list now contains the values `2`, `True` and `Items.Hay`. A list can also be empty: `empty_list = []` You can access an element of a list by its index. The index is `0` for the first element, `1` for the second element, `2` for the third... pl…
- 54m 40s
stop_programresult
Program stopped. Game time: 54m 50s elapsed, 5h 5m 10s of budget remaining.
- 54m 50s
write_programname="farm" · evidenceresult
Saved farm (115 lines). Game time: 55m elapsed, 5h 5m of budget remaining.
- 55m 00s
run_programname="farm" seconds=300result
Ran farm for 5m of game time; it is still running. Inventory change: carrot +134, fertilizer -4, hay +28, power +218.54, pumpkin +2244, water -16, weird_substance +330, wood +2834. Game time: 1h 10s elapsed, 4h 59m 50s of budget remaining. Output: (none)
- 1h 00msaidPumpkins ~2700, weird substance ~1050. Buying mazes, timing, and utilities, and reading the mazes tutorial.
- 1h 00m
buy_upgradeupgrades=["mazes","timing","utilities"] · evidenceresult
Bought mazes, now level 1. Paid weird_substance 1000. Its tutorial is docs page docs/unlocks/mazes.md. Bought timing, now level 1. Paid pumpkin 1000. Its tutorial is docs page docs/unlocks/timing.md. Bought utilities, now level 1. Paid pumpkin 1000. Game time: 1h 20s elapsed, 4h 59m 40s of budget remaining.
- 1h 00m
docs_readpath="docs/unlocks/mazes.md"result
# Mazes `Items.Weird_Substance`, which is obtained by [fertilizing](docs/unlocks/fertilizer.md) plants, has a strange effect on bushes. If the drone is over a bush and you call `use_item(Items.Weird_Substance, amount)` the bush will grow into a maze of hedges. The size of the maze depends on the amount of `Items.Weird_Substance` used (the second argument of the `use_item()` call). Without maze upg…
- 1h 00m
docs_readpath="docs/unlocks/timing.md"result
# Timing If you really want to optimize your methods you need to understand how time is measured in this game. This unlock is all about that. ## New Functions There are two useful functions to measure how long things take: `get_time()` returns the time in seconds since the start of the game. `get_tick_count()` returns the number of ticks performed since the start of execution. These two functi…
- 1h 00mthoughtI'll switch to a maze mode to accumulate gold toward the 2000-gold megafarm, while keeping pumpkin/carrot production going for the level 2 pumpkins, speed, and polyculture goals. Writing the maze mode logic into the farm program now.
- 1h 00m
stop_programresult
Program stopped. Game time: 1h 50s elapsed, 4h 59m 10s of budget remaining.
- 1h 00m
docs_readpath="functions/can_move"result
can_move(direction) Checks if the drone can move in the specified direction. returns True if the drone can move, False otherwise. takes 1 tick to execute. example: if can_move(North): move(North) For more related information see: [Mazes](docs/unlocks/mazes.md) Game time: 1h 1m elapsed, 4h 59m of budget remaining. - 1h 01m
write_programname="farm" · evidenceresult
Saved farm (154 lines). Game time: 1h 1m 10s elapsed, 4h 58m 50s of budget remaining.
- 1h 01m
run_programname="farm" seconds=90result
Ran farm for 1m 30s of game time; it is still running. Inventory change: carrot +220, fertilizer -2, gold +1216, hay +328, power -60.68, water -10, weird_substance -13, wood +327. Game time: 1h 2m 50s elapsed, 4h 57m 10s of budget remaining. Output: (none)
- 1h 02msaidGold is flowing fast from mazes (+1216 in 90s). Waiting for 2000 gold, then buying megafarm.
- 1h 02m
waitseconds=300 until_resources={"gold":2000}result
Waited 24s (gold reached 2048). Program: farm running. Inventory change: fertilizer +4, gold +512, power -16.06, water +19, weird_substance -56. Game time: 1h 3m 24s elapsed, 4h 56m 36s of budget remaining.
- 1h 03m
buy_upgradeupgrades=["megafarm"] · evidenceresult
Bought megafarm, now level 1. Paid gold 2000. Its tutorial is docs page docs/unlocks/megafarm.md. Game time: 1h 3m 34s elapsed, 4h 56m 26s of budget remaining.
- 1h 03m
docs_readpath="docs/unlocks/megafarm.md"result
# Mega Farm This incredibly powerful unlock gives you access to multiple drones. As before, you still start with just one drone. Additional drones must first be spawned and will disappear after the program terminates. Each drone runs its own separate program. New drones can be spawned using the `spawn_drone(function)` function. `def drone_function(): move(North) do_a_flip() spawn_drone… - 1h 03m
docs_readpath="functions/spawn_drone"result
spawn_drone(function, *args) Spawns a new drone in the same position as the drone that ran the spawn_drone(function, *args) command. The new drone then begins executing the specified function. The rest of the arguments are copied and passed into the specified function. After the drone is done, it will disappear automatically. returns the handle of the new drone or None if all drones are already s…
- 1h 03m
researchresult
auto_unlock (Auto Unlock) level 0/1; cost pumpkin 5000; requires costs ## Auto Unlock Automatically unlock things. unlock(Unlocks.Megafarm) cactus (Cactus) level 0/6; cost pumpkin 5000; available, not affordable ## Cactus Cactus! plant(Entities.Cactus) carrots (Carrots) level 3/10; cost wood 6250; can buy now; tutorial docs/unlocks/carrots.md ## Carrots Increases the yield and cost of carrot…
- 1h 04m
stop_programresult
Program stopped. Game time: 1h 4m 14s elapsed, 4h 55m 46s of budget remaining.
- 1h 04msaidMegafarm gives 2 drones now (next level: 8000 gold → 4). Rewriting the farm program for multi-drone column workers, with a gold target of 8000.
- 1h 04m
write_programname="farm" · evidenceresult
Saved farm (204 lines). Game time: 1h 4m 24s elapsed, 4h 55m 36s of budget remaining.
- 1h 04m
run_programname="farm" seconds=180result
Ran farm for 3m of game time; it is still running. Inventory change: fertilizer +36, power -242.86, water +144. Game time: 1h 7m 34s elapsed, 4h 52m 26s of budget remaining. Output: (none)
- 1h 07msaidNothing produced in 3 minutes — something is stuck. Checking the farm state.
- 1h 07m
observeresult
Game time: 1h 7m 44s elapsed, 4h 52m 16s of budget remaining. Program: farm (running). Inventory: hay 727, wood 7393, carrot 261, pumpkin 2202, weird_substance 49, gold 112, water 171, fertilizer 43, power 132.82. Farm 8x8. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: He=h…
- 1h 07m
observeresult
Game time: 1h 7m 54s elapsed, 4h 52m 6s of budget remaining. Program: farm (running). Inventory: hay 727, wood 7393, carrot 261, pumpkin 2202, weird_substance 49, gold 112, water 179, fertilizer 45, power 119.32. Farm 8x8. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: He=he…
- 1h 07mthoughtFound the issue: the drone got stuck because the previous program was stopped mid-maze, causing the new program's `goto` loop to run endlessly against a hedge wall. I'll fix this by detecting any leftover maze at the start of the loop and solving it first.
- 1h 07m
stop_programresult
Program stopped. Game time: 1h 8m 4s elapsed, 4h 51m 56s of budget remaining.
- 1h 08m
write_programname="farm" · evidenceresult
Saved farm (212 lines). Game time: 1h 8m 14s elapsed, 4h 51m 46s of budget remaining.
- 1h 08m
run_programname="farm" seconds=180result
Ran farm for 3m of game time; it is still running. Inventory change: carrot +116, fertilizer -48, gold +2176, hay +192, power +94.04, water -176, weird_substance +107, wood +249. Game time: 1h 11m 24s elapsed, 4h 48m 36s of budget remaining. Output: (none)
- 1h 11msaidWorking again: +2176 gold, sunflowers replenished power. Buying carrots level 4 (6250 wood) and letting it run.
- 1h 11m
buy_upgradeupgrades=["carrots"] · evidenceresult
Bought carrots, now level 4. Paid wood 6250. Its tutorial is docs page docs/unlocks/carrots.md. Game time: 1h 11m 34s elapsed, 4h 48m 26s of budget remaining.
- 1h 11m
waitseconds=300result
Waited 5m (time up). Program: farm running. Inventory change: carrot -213, fertilizer -7, gold +2304, hay -496, power +53.17, pumpkin +4134, water -32, weird_substance -101, wood -77. Game time: 1h 16m 44s elapsed, 4h 43m 16s of budget remaining.
- 1h 16m
observeresult
Game time: 1h 16m 54s elapsed, 4h 43m 6s of budget remaining. Program: farm (running). Inventory: hay 399, wood 1528, carrot 284, pumpkin 6336, weird_substance 46, gold 4912, power 225.99. Farm 8x8. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Ca=carrot, Tr=tree, Gr=grass.…
- 1h 16m
docs_readpath="unlocks/polyculture"result
## Polyculture Use companion planting to increase the yield. plant_type, (x, y) = get_companion() ### Unlock Cost [Current cost: pumpkin=3000] Game time: 1h 17m 4s elapsed, 4h 42m 56s of budget remaining.
- 1h 17m
docs_readpath="objects/carrot"result
## Carrot Carrots! Base growth time between 4.8 and 7.2 seconds. Can grow on soil. ### Plant Cost [Current cost: hay=8, wood=8] For more related information see: [Carrots](docs/unlocks/carrots.md) Game time: 1h 17m 14s elapsed, 4h 42m 46s of budget remaining.
- 1h 17m
waitseconds=600 until_resources={"pumpkin":8000}result
Waited 2m 15s (pumpkin reached 8205). Program: farm running. Inventory change: carrot +42, gold +1088, power +270.48, pumpkin +1113, weird_substance -28, wood -61. Game time: 1h 19m 40s elapsed, 4h 40m 20s of budget remaining.
- 1h 19msaidBuying expand (12x12) now; the program sizes itself from `get_world_size()` so it adapts.
- 1h 19m
buy_upgradeupgrades=["expand"] · evidenceresult
Bought expand, now level 6. Paid pumpkin 8000. Its tutorial is docs page docs/unlocks/expand_1.md. Game time: 1h 19m 50s elapsed, 4h 40m 10s of budget remaining.
- 1h 19m
waitseconds=300result
Waited 5m (time up). Program: farm running. Inventory change: carrot +5, fertilizer +8, gold +1440, power +598.77, pumpkin +3367, weird_substance +19, wood +610. Game time: 1h 25m elapsed, 4h 35m of budget remaining.
- 1h 25m
buy_upgradeupgrades=["polyculture"] · evidenceresult
Bought polyculture, now level 1. Paid pumpkin 3000. Its tutorial is docs page docs/unlocks/polyculture.md. Game time: 1h 25m 10s elapsed, 4h 34m 50s of budget remaining.
- 1h 25m
docs_readpath="docs/unlocks/polyculture.md"result
# Polyculture You may have already noticed that sometimes plants yield more when planted together. Grass, bushes, trees, and carrots yield more when they have the right plant companion. Companion preference is different for each individual plant and cannot be predicted. Fortunately, the companion preference of the plant under the drone can be measured using `get_companion()`. It returns a tuple wh…
- 1h 25m
observeresult
Game time: 1h 25m 30s elapsed, 4h 34m 30s of budget remaining. Program: farm (running). Inventory: hay 447, wood 3797, carrot 205, pumpkin 572, weird_substance 293, gold 7440, power 1159.68. Farm 12x12. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entities: Ca=carrot, Tr=tree, Gr=gr…
- 1h 25m
waitseconds=300 until_resources={"gold":8000}result
Waited 21s (gold reached 8016). Program: farm running. Inventory change: fertilizer +5, gold +432, power -14.45, water +17, weird_substance -24. Game time: 1h 26m 1s elapsed, 4h 33m 59s of budget remaining.
- 1h 26msaidGold hit 8000 — buying megafarm level 2 (4 drones) and checking the next costs. Then I'll raise the pumpkin threshold so carrots accumulate for speed 5 and pumpkins 2 (1000 each).
- 1h 26m
buy_upgradeupgrades=["megafarm"] · evidenceresult
Bought megafarm, now level 2. Paid gold 8000. Its tutorial is docs page docs/unlocks/megafarm.md. Game time: 1h 26m 11s elapsed, 4h 33m 49s of budget remaining.
- 1h 26m
researchresult
auto_unlock (Auto Unlock) level 0/1; cost pumpkin 5000; requires costs ## Auto Unlock Automatically unlock things. unlock(Unlocks.Megafarm) cactus (Cactus) level 0/6; cost pumpkin 5000; available, not affordable ## Cactus Cactus! plant(Entities.Cactus) carrots (Carrots) level 4/10; cost wood 31200; available, not affordable; tutorial docs/unlocks/carrots.md ## Carrots Increases the yield and…
- 1h 26m
stop_programresult
Program stopped. Game time: 1h 26m 31s elapsed, 4h 33m 29s of budget remaining.
- 1h 26msaidNext steps: set PUMP_AT=1200 (accumulate carrots for speed 5 / pumpkins 2), GOLD_AT=40000 (toward 8 drones), then run. Write and run are sequential, so writing first.
- 1h 26m
write_programname="farm" · evidenceresult
Saved farm (212 lines). Game time: 1h 26m 41s elapsed, 4h 33m 19s of budget remaining.
- 1h 26m
run_programname="farm" seconds=300result
Ran farm for 5m of game time; it is still running. Inventory change: carrot +1856, fertilizer +15, gold +4752, hay +720, power -234.38, water +60, weird_substance +265, wood +273. Game time: 1h 31m 51s elapsed, 4h 28m 9s of budget remaining. Output: Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- mixed_tile <- ensure <- fert use_item(Items.Fertilizer) ^^ … - 1h 31msaidCarrots hit ~2060 — buying speed 5 and pumpkins 2 together now.
- 1h 31m
buy_upgradeupgrades=["speed","pumpkins"] · evidenceresult
Bought speed, now level 5. Paid carrot 1000. Its tutorial is docs page docs/unlocks/speed.md. Bought pumpkins, now level 2. Paid carrot 1000. Its tutorial is docs page docs/unlocks/pumpkins.md. Game time: 1h 32m 1s elapsed, 4h 27m 59s of budget remaining.
- 1h 32m
stop_programresult
Program stopped. Game time: 1h 32m 11s elapsed, 4h 27m 49s of budget remaining.
- 1h 32mthoughtI'll set PUMP_AT to roughly 600 to reflect the higher carrot cost of pumpkins, then rerun before accumulating pumpkins for the cactus (5000) and dictionaries (2500). For now I can only make the write change; the run depends on it finishing first.
- 1h 32m
write_programname="farm" · evidenceresult
Saved farm (212 lines). Game time: 1h 32m 21s elapsed, 4h 27m 39s of budget remaining.
- 1h 32m
run_programname="farm" seconds=600result
Ran farm for 10m of game time; it is still running. Inventory change: carrot +1098, fertilizer -14, gold +15552, hay +352, power -684.16, pumpkin +1428, water -60, weird_substance -303, wood +303. Game time: 1h 42m 31s elapsed, 4h 17m 29s of budget remaining. Output: Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- pump_tile <- water use_item(Items.Water) ^^ … - 1h 42m
observeresult
Game time: 1h 42m 41s elapsed, 4h 17m 19s of budget remaining. Program: farm (running). Inventory: hay 2479, wood 3925, carrot 1159, pumpkin 2000, weird_substance 111, gold 21328, water 68, fertilizer 18, power 161.72. Farm 12x12. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone. Entitie…
- 1h 42msaidMaze mode is eating most of the drone time (gold 21k, 8 drones at 32k). Buying trees 3 with spare hay, then waiting for 32k gold.
- 1h 42m
buy_upgradeupgrades=["trees"] · evidenceresult
Bought trees, now level 3. Paid hay 1200. Its tutorial is docs page docs/unlocks/trees.md. Game time: 1h 42m 51s elapsed, 4h 17m 9s of budget remaining.
- 1h 42m
waitseconds=900 until_resources={"gold":32000}result
Waited 10m 41s (gold reached 32128). Program: farm running. Inventory change: carrot -784, fertilizer -21, gold +10368, hay -880, power +602.21, pumpkin +22026, water -80, weird_substance -16, wood +9666. Game time: 1h 53m 42s elapsed, 4h 6m 18s of budget remaining.
- 1h 53m
buy_upgradeupgrades=["megafarm","cactus","dictionaries","grass"] · evidenceresult
Bought megafarm, now level 3. Paid gold 32000. Its tutorial is docs page docs/unlocks/megafarm.md. Bought cactus, now level 1. Paid pumpkin 5000. Its tutorial is docs page docs/unlocks/cactus.md. Bought dictionaries, now level 1. Paid pumpkin 2500. Its tutorial is docs page docs/scripting/dicts.md. Bought grass, now level 5. Paid wood 12500. Game time: 1h 53m 52s elapsed, 4h 6m 8s of budget remain…
- 1h 53m
docs_readpath="docs/unlocks/cactus.md"result
# Cactus Like other plants, [cacti](objects/cactus) can be grown on soil and harvested as usual. However, they come in various sizes and have a strange sense of order. If you harvest a fully-grown cactus and all neighboring cacti are in sorted order, it will also harvest all neighboring cacti recursively. A cactus is considered to be in sorted order if all neighboring cacti to the `North` and `…
- 1h 54m
docs_readpath="objects/cactus"result
## Cactus Cacti come in 10 different sizes. When harvested adjacent cacti that are "sorted" will also be harvested. Base growth time between 1 and 1 seconds. Can grow on soil. ### Plant Cost [Current cost: pumpkin=2] Game time: 1h 54m 12s elapsed, 4h 5m 48s of budget remaining.
- 1h 54m
docs_readpath="unlocks/dinosaurs"result
## Dinosaurs Majestic ancient creatures. ### Unlock Cost [Current cost: cactus=2000] Game time: 1h 54m 22s elapsed, 4h 5m 38s of budget remaining.
- 1h 54mthoughtPlanting all 144 tiles with 2 pumpkins each and sorting rows then columns via swap lets me harvest 20,736 cactus in one go. I'll add a parallel cactus-sorting round across the 8 drones and trim maze time accordingly.
- 1h 54m
stop_programresult
Program stopped. Game time: 1h 54m 32s elapsed, 4h 5m 28s of budget remaining.
- 1h 54m
docs_readpath="functions/swap"result
swap(direction) Swaps the entity under the drone with the entity next to the drone in the specified direction. Doesn't work on all entities. Also works if one (or both) of the entities are None. returns True if it succeeded, False otherwise. takes 200 ticks to execute on success, 1 tick otherwise. example: swap(North) For more related information see: [Cactus](docs/unlocks/cactus.md) Game time…
- 1h 54m
docs_readpath="functions/measure"result
measure(direction = None) Can measure some values on some entities. The effect of this depends on the entity. If direction is not None it measures the neighboring entity in the given direction. returns the number of petals of a sunflower. returns the next position for a treasure or apple. returns the size of a cactus. returns a mysterious number for a pumpkin. returns None for all other entitie…
- 1h 54m
write_programname="farm" · evidenceresult
Saved farm (259 lines). Game time: 1h 55m 2s elapsed, 4h 4m 58s of budget remaining.
- 1h 55m
run_programname="farm" seconds=180result
Ran farm for 3m of game time; it is still running. Inventory change: cactus +19944, fertilizer +25, gold +4896, power -282.14, pumpkin -288, water +102, weird_substance +384. Game time: 1h 58m 12s elapsed, 4h 1m 48s of budget remaining. Output: (none)
- 1h 58msaidCactus round worked: +19,944 cactus. Buying dinosaurs (2000) and mazes 2 (12000 cactus, doubles gold per maze), and reading the dinosaur docs.
- 1h 58m
buy_upgradeupgrades=["dinosaurs","mazes"] · evidenceresult
Bought dinosaurs, now level 1. Paid cactus 2000. Its tutorial is docs page docs/unlocks/dinosaurs.md. Bought mazes, now level 2. Paid cactus 12000. Its tutorial is docs page docs/unlocks/mazes.md. Game time: 1h 58m 22s elapsed, 4h 1m 38s of budget remaining.
- 1h 58m
docs_readpath="docs/unlocks/dinosaurs.md"result
# Dinosaurs Dinosaurs are ancient, majestic creatures that can be farmed for ancient bones. Unfortunately dinosaurs have gone extinct a long time ago, so the best we can do now is dressing up as one. For this purpose you have received the new dinosaur hat. The hat can be equipped with `change_hat(Hats.Dinosaur_Hat)` Unfortunately it doesn't quite look like on the advertisement... If you equip …
- 1h 58m
observeresult
Game time: 1h 58m 42s elapsed, 4h 1m 18s of budget remaining. Program: farm (running). Inventory: hay 2543, wood 965, carrot 1237, pumpkin 17960, cactus 5944, weird_substance 339, gold 7184, water 163, fertilizer 41, power 298.52. Farm 12x12. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a dr…
- 1h 58m
buy_upgradeupgrades=["hats"] · evidenceresult
Could not buy hats: Already at maximum level.
- 1h 58m
docs_readpath="objects/apple"result
## Apple Dinosaurs love them apparently. ### Plant Cost [Current cost: cactus=2] For more related information see: [Dinosaurs](docs/unlocks/dinosaurs.md) Game time: 1h 59m 2s elapsed, 4h 58s of budget remaining.
- 1h 59m
docs_readpath="docs/unlocks/hats.md"result
# Hats You have unlocked a few new hat colors for your drone. Equip them like this: `change_hat(Hats.Gray_Hat) do_a_flip() change_hat(Hats.Purple_Hat) do_a_flip() change_hat(Hats.Green_Hat) do_a_flip() change_hat(Hats.Brown_Hat) do_a_flip()` Game time: 1h 59m 12s elapsed, 4h 48s of budget remaining.
- 1h 59mthoughtApples only cost 2 cactus and hats are ready to use. I'll clear the farm, equip the gray hat at (0,0), fill the farm via a serpentine Hamiltonian path, then swap hats to collect tail² bones.
- 1h 59m
stop_programresult
Program stopped. Game time: 1h 59m 22s elapsed, 4h 38s of budget remaining.
- 1h 59m
write_programname="farm" · evidenceresult
Saved farm (300 lines). Game time: 1h 59m 32s elapsed, 4h 28s of budget remaining.
- 1h 59mthoughtI'll run the program now, since the next steps depend on seeing its output.
- 1h 59m
run_programname="farm" seconds=240result
Ran farm for 3m 55s of game time; it stopped with an error: Hats.Gray_Hat must be unlocked before this can be used. Inventory change: cactus -286, carrot -144, fertilizer -7, gold +4032, hay +2224, power +501.46, water -44, weird_substance -100. Game time: 2h 3m 37s elapsed, 3h 56m 23s of budget remaining. Output: Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- water …
- 2h 03mthoughtI need to check which hat names are valid and the current state—fetching both now since they're independent.
- 2h 03m
docs_searchquery="Straw_Hat"result
No matches for "Straw_Hat". Game time: 2h 3m 47s elapsed, 3h 56m 13s of budget remaining.
- 2h 03m
docs_readpath="functions/change_hat"result
change_hat(hat) Changes the hat of the drone to hat. returns None takes 200 ticks to execute. example: change_hat(Hats.Dinosaur_Hat) Game time: 2h 3m 57s elapsed, 3h 56m 3s of budget remaining.
- 2h 03m
observeresult
Game time: 2h 4m 7s elapsed, 3h 55m 53s of budget remaining. Program: none running. Inventory: hay 4767, wood 965, carrot 1093, pumpkin 17960, cactus 5658, weird_substance 95, gold 12944, water 191, fertilizer 52, power 759.34. Farm 12x12. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a drone…
- 2h 04mthoughtThe farm filled up with 143 apples eaten, but since Gray Hat isn't unlocked yet, the tail bones weren't collected. I'll write a small program to try the default straw hat for cashing in the tail and check the hats research entry.
- 2h 04m
write_programname="hat" · evidenceresult
Saved hat (2 lines). Game time: 2h 4m 17s elapsed, 3h 55m 43s of budget remaining.
- 2h 04m
docs_searchquery="Hats."result
docs/home.md: …locks/fertilizer.md) [Functions](docs/scripting/functions.md) [Grass](unlocks/grass) [Hats](docs/unlocks/hats.md) [Import](docs/scripting/import.md) [Lists](docs/scripting/lists.md) [Loops](docs/scripting/while.md) [Mazes](docs/unlocks/mazes.md) [Megafarm](docs/unlocks/megafarm.m… docs/unlocks/dinosaurs.md: … dressing up as one. For this purpose you have received the new dinosaur ha…
- 2h 04m
run_programname="hat" seconds=10result
Ran hat for 1s of game time; it finished. Inventory change: bone +20449, power -0.03, water +1. Game time: 2h 4m 38s elapsed, 3h 55m 22s of budget remaining. Output: 20449
- 2h 04mthoughtCollected +20,449 bones. Next I'll fix the farm program to use `Hats.Straw_Hat` and purchase polyculture 2 with bones before rerunning.
- 2h 04m
write_programname="farm" · evidenceresult
Saved farm (300 lines). Game time: 2h 4m 48s elapsed, 3h 55m 12s of budget remaining.
- 2h 04mthoughtI'll buy polyculture 2 for 10k bones, restart the farm program, and check the updated research costs — doing all three at once since they're independent.
- 2h 04m
buy_upgradeupgrades=["polyculture"] · evidenceresult
Bought polyculture, now level 2. Paid bone 10000. Its tutorial is docs page docs/unlocks/polyculture.md. Game time: 2h 4m 58s elapsed, 3h 55m 2s of budget remaining.
- 2h 04m
run_programname="farm" seconds=300result
Ran farm for 5m of game time; it is still running. Inventory change: cactus +16056, fertilizer -5, gold +15264, power -414.63, pumpkin -288, water +96, weird_substance +3384. Game time: 2h 10m 8s elapsed, 3h 49m 52s of budget remaining. Output: (none)
- 2h 10m
researchresult
auto_unlock (Auto Unlock) level 0/1; cost pumpkin 5000; requires costs ## Auto Unlock Automatically unlock things. unlock(Unlocks.Megafarm) cactus (Cactus) level 1/6; cost pumpkin 20000; available, not affordable; tutorial docs/unlocks/cactus.md ## Cactus Increases the yield and cost of cactus. 100% => 200% carrots (Carrots) level 4/10; cost wood 31200; available, not affordable; tutorial docs…
- 2h 10mthoughtI'll go ahead and get dinosaurs 2 (needs 12k cactus, doubles bone yield) and wait for pumpkins to hit 20k for cactus 2 — these are independent so I'm requesting both now.
- 2h 10m
buy_upgradeupgrades=["dinosaurs"] · evidenceresult
Bought dinosaurs, now level 2. Paid cactus 12000. Its tutorial is docs page docs/unlocks/dinosaurs.md. Game time: 2h 10m 28s elapsed, 3h 49m 32s of budget remaining.
- 2h 10m
waitseconds=600 until_resources={"pumpkin":20000}result
Waited 10m (time up). Program: farm running. Inventory change: fertilizer +120, gold +24768, power -314.30, water +480, weird_substance -2064. Game time: 2h 20m 38s elapsed, 3h 39m 22s of budget remaining.
- 2h 20mthoughtMazes consumed the entire 10-minute cycle, netting only +24.8k gold. I'll limit mazes to a small batch per cycle and stop fertilizing cacti, but first I need to stop the program since the edit depends on it.
- 2h 20m
stop_programresult
Program stopped. Game time: 2h 20m 48s elapsed, 3h 39m 12s of budget remaining.
- 2h 20mthoughtI'll update the farm program and buy trees 4 (if hay allows) now, then run the program afterward.
- 2h 20m
write_programname="farm" · evidenceresult
Saved farm (301 lines). Game time: 2h 20m 58s elapsed, 3h 39m 2s of budget remaining.
- 2h 20m
buy_upgradeupgrades=["trees"] · evidenceresult
Could not buy trees: Not enough resources.
- 2h 21mthoughtI'll run the program now, since everything else depends on its results.
- 2h 21m
run_programname="farm" seconds=600result
Ran farm for 10m of game time; it is still running. Inventory change: carrot -288, fertilizer -168, gold +19872, power +693.92, water -241, weird_substance -576. Game time: 2h 31m 18s elapsed, 3h 28m 42s of budget remaining. Output: (none)
- 2h 31mthoughtThe maze logic is dominating every loop since the elif chain keeps re-entering it; I'll fix it so each iteration runs a maze batch when due, then still does a farming round, and I'm stopping now to make that edit.
- 2h 31m
stop_programresult
Program stopped. Game time: 2h 31m 28s elapsed, 3h 28m 32s of budget remaining.
- 2h 31mthoughtI'll write the fixed main loop and check the current inventory next, then run it once both are done.
- 2h 31m
write_programname="farm" · evidenceresult
Saved farm (301 lines). Game time: 2h 31m 38s elapsed, 3h 28m 22s of budget remaining.
- 2h 31m
observeresult
Game time: 2h 31m 48s elapsed, 3h 28m 12s of budget remaining. Program: none running. Inventory: hay 4767, wood 965, carrot 805, pumpkin 17672, cactus 9714, bone 10449, weird_substance 647, gold 75152, water 655, fertilizer 31, power 683.70. Farm 12x12. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); *…
- 2h 31mthoughtGold's at 75k, but wood and hay stalled since mazes ate up the time. Running the fixed program next—that's the key remaining step.
- 2h 31m
run_programname="farm" seconds=600result
Ran farm for 10m of game time; it is still running. Inventory change: bone +40898, cactus +186052, carrot -288, fertilizer -1, gold +10656, hay +2304, power -272.28, pumpkin -2880, water -648, weird_substance -392. Game time: 2h 41m 58s elapsed, 3h 18m 2s of budget remaining. Output: Warning: Tried to use Items.Water but didn't have enough of it. In: worker <- water use_item(Items.Water) ^… - 2h 41mthoughtCactus rounds are dominating gains while pumpkins stall out, so I'll switch the main loop to round-robin between pumpkins, mixed crops, cactus, and dino. I also need to buy affordable upgrades (trees 4, dinosaurs 3, mazes 3, polyculture 3) and pause the program to make these edits.
- 2h 41m
buy_upgradeupgrades=["trees","dinosaurs","mazes","polyculture"] · evidenceresult
Bought trees, now level 4. Paid hay 4800. Its tutorial is docs page docs/unlocks/trees.md. Bought dinosaurs, now level 3. Paid cactus 72000. Its tutorial is docs page docs/unlocks/dinosaurs.md. Bought mazes, now level 3. Paid cactus 72000. Its tutorial is docs page docs/unlocks/mazes.md. Bought polyculture, now level 3. Paid bone 50000. Its tutorial is docs page docs/unlocks/polyculture.md. Game t…
- 2h 42m
stop_programresult
Program stopped. Game time: 2h 42m 18s elapsed, 3h 17m 42s of budget remaining.
- 2h 42mthoughtI'll write the round-robin version now, then run it once it's ready.
- 2h 42m
write_programname="farm" · evidenceresult
Saved farm (311 lines). Game time: 2h 42m 28s elapsed, 3h 17m 32s of budget remaining.
- 2h 42mthoughtI'll run the program next, since that's the remaining step needed.
- 2h 42m
run_programname="farm" seconds=600result
Ran farm for 10m of game time; it is still running. Inventory change: fertilizer +120, power -377.52, pumpkin -168, water +432. Game time: 2h 52m 38s elapsed, 3h 7m 22s of budget remaining. Output: (none)
- 2h 52mthoughtNothing has been produced in 10 minutes, so something seems to be hung. I'll check the farm to see what's happening before deciding on a fix.
- 2h 52m
observeresult
Game time: 2h 52m 48s elapsed, 3h 7m 12s of budget remaining. Program: farm (running). Inventory: hay 2271, wood 965, carrot 517, pumpkin 14624, cactus 72458, bone 1347, weird_substance 255, gold 85808, water 487, fertilizer 162. Farm 12x12. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium, 3 full); * marks a dro…
- 2h 52mthoughtFound that the drone was stuck in a leftover dinosaur hat state from the interrupted run, causing `goto` to deadlock — fixing this by resetting the hat at program start and adding a fallback reset on repeated move failures. Stopping the program now so the edit can be applied.
- 2h 52m
stop_programresult
Program stopped. Game time: 2h 52m 58s elapsed, 3h 7m 2s of budget remaining.
- 2h 52mthoughtI'll write the fixed program first, then run it once that's done.
- 2h 52m
write_programname="farm" · evidenceresult
Saved farm (319 lines). Game time: 2h 53m 8s elapsed, 3h 6m 52s of budget remaining.
- 2h 53mthoughtI'll run the program now and check back on its progress after it's had some time to execute.
- 2h 53m
run_programname="farm" seconds=300result
Ran farm for 5m of game time; it is still running. Inventory change: bone +81992, cactus +61163, carrot -288, fertilizer -168, gold +6912, hay +10608, power +744.03, pumpkin -864, water -511, weird_substance -16, wood -960. Game time: 2h 58m 18s elapsed, 3h 1m 42s of budget remaining. Output: …------------------------------------------------------------ Warning: Didn't have the required items to p…
- 2h 58mthoughtWood's run out since cactus/pump/dino rounds keep wiping trees before they regrow, so I'll switch to mixed sweeps in blocks of 4 and hold off on carrot planting until wood recovers. I'll stop the current run, update the script, then run it again in sequence.
- 2h 58m
stop_programresult
Program stopped. Game time: 2h 58m 28s elapsed, 3h 1m 32s of budget remaining.
- 2h 58mthoughtI'll write the updated program now, then run it afterward.
- 2h 58m
write_programname="farm" · evidenceresult
Saved farm (316 lines). Game time: 2h 58m 38s elapsed, 3h 1m 22s of budget remaining.
- 2h 58mthoughtI'll run the program now, since the remaining checks depend on its output.
- 2h 58m
run_programname="farm" seconds=600result
Ran farm for 10m of game time; it is still running. Inventory change: bone +163592, cactus +59920, carrot +53708, fertilizer -4, gold +21312, hay +29288, power +405.31, pumpkin +2550, water -19, weird_substance +8690, wood +177108. Game time: 3h 8m 48s elapsed, 2h 51m 12s of budget remaining. Output: Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: mixed_block <- run_all <-…
- 3h 08mthoughtPolyculture 20x delivered a massive boost: +177k wood, +54k carrots, +164k bones in 10 minutes. Now I'll spend resources on upgrades (pumpkins, carrots, grass, fertilizer, watering, trees, plus polyculture and megafarm attempts) and refresh the research list in parallel.
- 3h 08m
buy_upgradeupgrades=["pumpkins","carrots","grass","fertilizer","watering","trees","polyculture","megafarm"] · evidenceresult
Bought pumpkins, now level 3. Paid carrot 4000. Its tutorial is docs page docs/unlocks/pumpkins.md. Bought carrots, now level 5. Paid wood 31200. Its tutorial is docs page docs/unlocks/carrots.md. Bought grass, now level 6. Paid wood 62500. Bought fertilizer, now level 3. Paid wood 9000. Its tutorial is docs page docs/unlocks/fertilizer.md. Bought watering, now level 5. Paid wood 12800. Its tutori…
- 3h 08m
researchresult
auto_unlock (Auto Unlock) level 0/1; cost pumpkin 5000; requires costs ## Auto Unlock Automatically unlock things. unlock(Unlocks.Megafarm) cactus (Cactus) level 1/6; cost pumpkin 20000; available, not affordable; tutorial docs/unlocks/cactus.md ## Cactus Increases the yield and cost of cactus. 100% => 200% carrots (Carrots) level 5/10; cost wood 156000; available, not affordable; tutorial doc…
- 3h 09mthoughtI'll buy 4 pumpkins (16k carrots) and 6 waterings (51k wood) now, then let the farm run for about 10 minutes.
- 3h 09m
buy_upgradeupgrades=["pumpkins","watering"] · evidenceresult
Bought pumpkins, now level 4. Paid carrot 16000. Its tutorial is docs page docs/unlocks/pumpkins.md. Bought watering, now level 6. Paid wood 51200. Its tutorial is docs page docs/unlocks/watering.md. Game time: 3h 9m 18s elapsed, 2h 50m 42s of budget remaining.
- 3h 09m
waitseconds=600result
Waited 10m (time up). Program: farm running. Inventory change: bone +163592, cactus +39184, carrot +198560, fertilizer -8, gold +21312, hay +71328, power -437.64, pumpkin +12984, water +203, weird_substance +50228, wood +863232. Game time: 3h 19m 28s elapsed, 2h 40m 32s of budget remaining.
- 3h 19mthoughtI'll make a large upgrade purchase (expanding the megafarm's drones and crop types) and check the current state at the same time, since these can run independently.
- 3h 19m
buy_upgradeupgrades=["megafarm","polyculture","carrots","grass","trees","pumpkins","cactus","fertilizer","watering"] · evidenceresult
Bought megafarm, now level 4. Paid gold 128000. Its tutorial is docs page docs/unlocks/megafarm.md. Bought polyculture, now level 4. Paid bone 250000. Its tutorial is docs page docs/unlocks/polyculture.md. Bought carrots, now level 6. Paid wood 156000. Its tutorial is docs page docs/unlocks/carrots.md. Bought grass, now level 7. Paid wood 312000. Bought trees, now level 6. Paid hay 76800. Its tuto…
- 3h 19m
observeresult
Game time: 3h 19m 48s elapsed, 2h 40m 12s of budget remaining. Program: farm (running). Inventory: hay 15831, wood 215201, carrot 181809, pumpkin 12678, cactus 232725, bone 160523, weird_substance 58961, gold 10800, water 331, fertilizer 10, power 556.98. Farm 12x12. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medi…
- 3h 19mthoughtI just need to wait for the pumpkin count to hit 64k so the 16x16 expand can proceed — everything else depends on that.
- 3h 19m
waitseconds=600 until_resources={"pumpkin":64000}result
Waited 10m (time up). Program: farm running. Inventory change: bone +163592, cactus +80440, carrot +504656, fertilizer +61, gold +20736, hay +240288, power +381.96, pumpkin +25392, water +2488, weird_substance +283404, wood +1866512. Game time: 3h 29m 58s elapsed, 2h 30m 2s of budget remaining.
- 3h 29mthoughtI'll request both in parallel: buying carrots, pumpkins, grass, and watering, while also waiting for the 64k pumpkins since they're independent tasks.
- 3h 29m
buy_upgradeupgrades=["carrots","pumpkins","grass","watering"] · evidenceresult
Bought carrots, now level 7. Paid wood 781000. Its tutorial is docs page docs/unlocks/carrots.md. Bought pumpkins, now level 6. Paid carrot 256000. Its tutorial is docs page docs/unlocks/pumpkins.md. Could not buy grass: Not enough resources. Bought watering, now level 8. Paid wood 819000. Its tutorial is docs page docs/unlocks/watering.md. Game time: 3h 30m 8s elapsed, 2h 29m 52s of budget remain…
- 3h 30m
waitseconds=600 until_resources={"pumpkin":64000}result
Waited 1m 47s (pumpkin reached 64566). Program: farm running. Inventory change: bone +81796, cactus +40680, carrot +334752, fertilizer -94, gold +6912, hay +91136, power -399.81, pumpkin +26496, water +920, weird_substance +176176, wood +626512. Game time: 3h 32m 5s elapsed, 2h 27m 55s of budget remaining.
- 3h 32mthoughtI'll trigger the 16x16 auto-expand and then let it run for 10 minutes—these two steps don't depend on each other, so I'll request both now.
- 3h 32m
buy_upgradeupgrades=["expand"] · evidenceresult
Bought expand, now level 7. Paid pumpkin 64000. Its tutorial is docs page docs/unlocks/expand_1.md. Game time: 3h 32m 15s elapsed, 2h 27m 45s of budget remaining.
- 3h 32m
waitseconds=600result
Waited 10m (time up). Program: farm running. Inventory change: bone +260100, cactus +33338, carrot +1227680, fertilizer -6, gold +16384, hay +191232, power +391.36, pumpkin +45420, water +5444, weird_substance +401648, wood +2754160. Game time: 3h 42m 25s elapsed, 2h 17m 35s of budget remaining.
- 3h 42mthoughtI need to buy grass (8), trees (7), and pumpkins (7), and separately pause the program to raise MAZE_BATCH since unused substance has piled up to ~900k. I'll run both of these independent tasks now.
- 3h 42m
buy_upgradeupgrades=["grass","trees","pumpkins"] · evidenceresult
Bought grass, now level 8. Paid wood 1560000. Bought trees, now level 7. Paid hay 307000. Its tutorial is docs page docs/unlocks/trees.md. Bought pumpkins, now level 7. Paid carrot 1020000. Its tutorial is docs page docs/unlocks/pumpkins.md. Game time: 3h 42m 35s elapsed, 2h 17m 25s of budget remaining.
- 3h 42m
stop_programresult
Program stopped. Game time: 3h 42m 45s elapsed, 2h 17m 15s of budget remaining.
- 3h 42mthoughtI'll first update the code to use MAZE_BATCH=8, then run it afterward.
- 3h 42m
write_programname="farm" · evidenceresult
Saved farm (316 lines). Game time: 3h 42m 55s elapsed, 2h 17m 5s of budget remaining.
- 3h 42mthoughtI'll run the program for about 10 minutes next, then decide on purchases based on what accumulates.
- 3h 42m
run_programname="farm" seconds=600result
Ran farm for 10m of game time; it is still running. Inventory change: cactus +130616, carrot +785536, fertilizer +189, gold +40960, hay +475200, power +363.58, pumpkin +94208, water +6079, weird_substance +364116, wood +4017920. Game time: 3h 53m 5s elapsed, 2h 6m 55s of budget remaining. Output: Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- sun_plant_tile <- e…
- 3h 53mthoughtI'll purchase cactus 3 (80k pumpkins), dinosaurs 4 (432k cactus), and carrots 8 (3.9M wood), then let the game run for another 10 minutes.
- 3h 53m
buy_upgradeupgrades=["cactus","dinosaurs","carrots"] · evidenceresult
Bought cactus, now level 3. Paid pumpkin 120000. Its tutorial is docs page docs/unlocks/cactus.md. Bought dinosaurs, now level 4. Paid cactus 432000. Its tutorial is docs page docs/unlocks/dinosaurs.md. Bought carrots, now level 8. Paid wood 3910000. Its tutorial is docs page docs/unlocks/carrots.md. Game time: 3h 53m 15s elapsed, 2h 6m 45s of budget remaining.
- 3h 53m
waitseconds=600result
Waited 10m (time up). Program: farm running. Inventory change: bone +520200, cactus +259280, carrot +2353600, fertilizer -152, gold +49152, hay +512768, power +151.46, pumpkin +93376, water +5318, weird_substance +996064, wood +5452384. Game time: 4h 3m 25s elapsed, 1h 56m 35s of budget remaining.
- 4h 03mthoughtNext I'll buy 8 pumpkins, 8 trees, and 9 watering cans (plus attempt 5 polyculture and 4 mazes), then run the simulation for another 10 minutes—I'll request both since they're independent.
- 4h 03m
buy_upgradeupgrades=["pumpkins","trees","watering","polyculture","mazes"] · evidenceresult
Bought pumpkins, now level 8. Paid carrot 4100000. Its tutorial is docs page docs/unlocks/pumpkins.md. Bought trees, now level 8. Paid hay 1230000. Its tutorial is docs page docs/unlocks/trees.md. Bought watering, now level 9. Paid wood 3280000. Its tutorial is docs page docs/unlocks/watering.md. Could not buy polyculture: Not enough resources. Could not buy mazes: Not enough resources. Game time:…
- 4h 03m
waitseconds=600result
Waited 10m (time up). Program: farm running. Inventory change: bone +520200, cactus +258160, carrot +1696320, fertilizer -76, gold +32768, hay +407296, power -354.14, pumpkin -2048, water +13313, weird_substance +1730520, wood +6901568. Game time: 4h 13m 45s elapsed, 1h 46m 15s of budget remaining.
- 4h 13mthoughtI'll buy polyculture 5, mazes 4, and grass 9 now that they're affordable, and also observe to check which mode is running since pumpkins didn't increase this window.
- 4h 13m
buy_upgradeupgrades=["polyculture","mazes","grass"] · evidenceresult
Bought polyculture, now level 5. Paid bone 1250000. Its tutorial is docs page docs/unlocks/polyculture.md. Bought mazes, now level 4. Paid cactus 432000. Its tutorial is docs page docs/unlocks/mazes.md. Bought grass, now level 9. Paid wood 7810000. Game time: 4h 13m 55s elapsed, 1h 46m 5s of budget remaining.
- 4h 13m
observeresult
Game time: 4h 14m 5s elapsed, 1h 45m 55s of budget remaining. Program: farm (running). Inventory: hay 448655, wood 3671057, carrot 1665601, pumpkin 302370, cactus 170783, bone 456411, weird_substance 4016409, gold 182064, water 35974, fertilizer 7, power 1461.24. Farm 16x16. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small…
- 4h 14mthoughtI'll let it run for about 10 minutes, since purchases depend on what accumulates over that time.
- 4h 14m
waitseconds=600result
Waited 10m (time up). Program: farm running. Inventory change: bone +520200, cactus +258064, carrot +3118272, fertilizer +85, gold +61440, hay +1790720, power -1176.66, pumpkin -2048, water +13831, weird_substance +2981376, wood +13931968. Game time: 4h 24m 15s elapsed, 1h 35m 45s of budget remaining.
- 4h 24mthoughtI'll refresh the research costs, try purchasing 9 carrots and 4 cactus, and keep the farm running for another 10 minutes—all at once since these are independent actions.
- 4h 24m
researchresult
auto_unlock (Auto Unlock) level 0/1; cost pumpkin 5000; requires costs ## Auto Unlock Automatically unlock things. unlock(Unlocks.Megafarm) cactus (Cactus) level 3/6; cost pumpkin 720000; available, not affordable; tutorial docs/unlocks/cactus.md ## Cactus Increases the yield and cost of cactus. 400% => 800% carrots (Carrots) level 8/10; cost wood 19500000; available, not affordable; tutorial …
- 4h 24m
buy_upgradeupgrades=["carrots","cactus"] · evidenceresult
Could not buy carrots: Not enough resources. Could not buy cactus: Not enough resources.
- 4h 24m
waitseconds=600result
Waited 10m (time up). Program: farm running. Inventory change: bone +520200, cactus -4080, carrot +3493184, fertilizer +149, gold +61440, hay +699776, power +186.01, pumpkin +177408, water +13914, weird_substance +940468, wood +15527296. Game time: 4h 34m 45s elapsed, 1h 25m 15s of budget remaining.
- 4h 34mthoughtI'll buy 9 carrots now that wood is at ~33M, and separately wait for pumpkins to hit 512k to trigger the 22x22 expansion—both can proceed independently.
- 4h 34m
buy_upgradeupgrades=["carrots"] · evidenceresult
Bought carrots, now level 9. Paid wood 19500000. Its tutorial is docs page docs/unlocks/carrots.md. Game time: 4h 34m 55s elapsed, 1h 25m 5s of budget remaining.
- 4h 34m
waitseconds=600 until_resources={"pumpkin":512000}result
Waited 6m 27s (pumpkin reached 654242). Program: farm running. Inventory change: cactus +262144, carrot +5864320, fertilizer -288, gold +57344, hay +1472000, power +484.83, pumpkin +176512, water +7856, weird_substance +3211544, wood +13383936. Game time: 4h 41m 32s elapsed, 1h 18m 28s of budget remaining.
- 4h 41mthoughtI'll buy the expand upgrade to 22x22 since we have enough pumpkins (654k ≥ 512k needed), then let it run for 10 minutes.
- 4h 41m
buy_upgradeupgrades=["expand"] · evidenceresult
Bought expand, now level 8. Paid pumpkin 512000. Its tutorial is docs page docs/unlocks/expand_1.md. Game time: 4h 41m 42s elapsed, 1h 18m 18s of budget remaining.
- 4h 41m
waitseconds=600result
Waited 10m (time up). Program: farm running. Inventory change: cactus -688, carrot +6466560, fertilizer +343, gold +30976, hay +2014208, power -870.40, water +14110, weird_substance +1066688, wood +16273472. Game time: 4h 51m 52s elapsed, 1h 8m 8s of budget remaining.
- 4h 51mthoughtI'll buy 9 pumpkins and 9 trees now that they're affordable, check the farm's current state, and run the simulation for another 10 minutes.
- 4h 51m
buy_upgradeupgrades=["pumpkins","trees"] · evidenceresult
Bought pumpkins, now level 9. Paid carrot 16400000. Its tutorial is docs page docs/unlocks/pumpkins.md. Bought trees, now level 9. Paid hay 4920000. Its tutorial is docs page docs/unlocks/trees.md. Game time: 4h 52m 2s elapsed, 1h 7m 58s of budget remaining.
- 4h 52m
observeresult
Game time: 4h 52m 12s elapsed, 1h 7m 48s of budget remaining. Program: farm (running). Inventory: hay 1505359, wood 43287729, carrot 4207937, pumpkin 142242, cactus 686175, bone 1496811, weird_substance 12215333, gold 409648, water 88245, fertilizer 376. Farm 22x22. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 mediu…
- 4h 52m
waitseconds=600result
Waited 10m (time up). Program: farm running. Inventory change: cactus -4704, fertilizer +480, water +15360. Game time: 5h 2m 22s elapsed, 57m 38s of budget remaining.
- 5h 02mthoughtI'll check how the snake game is progressing to decide whether to let the current dino round finish or end it early.
- 5h 02m
observeresult
Game time: 5h 2m 32s elapsed, 57m 28s of budget remaining. Program: farm (running). Inventory: hay 1505359, wood 43287729, carrot 4207937, pumpkin 142242, cactus 681263, bone 1496811, weird_substance 12215333, gold 409648, water 104117, fertilizer 872. Farm 22x22. x runs west to east, rows are listed north (top) to south. Cells: ground (# soil, _ grassland) + entity code + size (1 small, 2 medium,…
- 5h 02msaidThe tail is ~370/484, so the dino round should finish in a few minutes (worth ~1.9M bones). Needed: wait, stopping early once bones jump. Single request.
- 5h 02m
waitseconds=600 until_resources={"bone":3000000}result
Waited 10m (time up). Program: farm running. Inventory change: bone +1325192, cactus +936320, carrot +4843164, fertilizer -688, gold +73568, hay -247808, power +355.34, pumpkin -3872, water +12948, weird_substance +9723180, wood +26108672. Game time: 5h 12m 42s elapsed, 47m 18s of budget remaining.
- 5h 12mthoughtI'll buy grass 10 (costing ~69M wood) and stop the program to prevent further dino rounds, since a 22x22 round takes ~20 min and could forfeit bones if unfinished by the deadline — then write and run the update.
- 5h 12m
buy_upgradeupgrades=["grass"] · evidenceresult
Bought grass, now level 10. Paid wood 39100000. Game time: 5h 12m 52s elapsed, 47m 8s of budget remaining.
- 5h 12m
stop_programresult
Program stopped. Game time: 5h 13m 2s elapsed, 46m 58s of budget remaining.
- 5h 13mthoughtNext I'll write the end-game program—no dino, with a cactus/pump/mixed rotation and maze batches—then run it afterward once it's done.
- 5h 13m
write_programname="farm" · evidenceresult
Saved farm (276 lines). Game time: 5h 13m 12s elapsed, 46m 48s of budget remaining.
- 5h 13mthoughtNext, I'll run the program, since the remaining checks depend on its output.
- 5h 13m
run_programname="farm" seconds=900result
Ran farm for 15m of game time; it is still running. Inventory change: cactus +937024, carrot +7543224, fertilizer -224, gold +127776, hay +2785024, power +2581.01, pumpkin +677344, water +17690, weird_substance +3566032, wood +34993664. Game time: 5h 28m 22s elapsed, 31m 38s of budget remaining. Output: Warning: Tried to use Items.Fertilizer but didn't have enough of it. In: worker <- pump_tile <-…
- 5h 28mthoughtI'll buy cactus level 4 (720k pumpkins) and megafarm level 5 (512k gold for 32 drones), then run the simulation for another 15 minutes since these purchases are independent.
- 5h 28m
buy_upgradeupgrades=["cactus","megafarm"] · evidenceresult
Bought cactus, now level 4. Paid pumpkin 720000. Its tutorial is docs page docs/unlocks/cactus.md. Bought megafarm, now level 5. Paid gold 512000. Its tutorial is docs page docs/unlocks/megafarm.md. Game time: 5h 28m 32s elapsed, 31m 28s of budget remaining.
- 5h 28m
waitseconds=900result
Waited 15m (time up). Program: farm running. Inventory change: cactus +3748096, carrot +12191616, fertilizer +209, gold +154880, hay +5776384, power -2762.44, pumpkin +671104, water +19057, weird_substance +5376640, wood +62697344. Game time: 5h 43m 42s elapsed, 16m 18s of budget remaining.
- 5h 43mthoughtI'll buy 10 carrots (~127M wood) and 5 mazes (cactus), then use up most of the remaining time—requesting both now since they're independent.
- 5h 43m
buy_upgradeupgrades=["carrots","mazes"] · evidenceresult
Bought carrots, now level 10. Paid wood 97700000. Its tutorial is docs page docs/unlocks/carrots.md. Bought mazes, now level 5. Paid cactus 2590000. Its tutorial is docs page docs/unlocks/mazes.md. Game time: 5h 43m 52s elapsed, 16m 8s of budget remaining.
- 5h 43m
waitseconds=900result
Waited 15m (time up). Program: farm running. Inventory change: cactus +1874048, carrot +25240348, fertilizer +46, gold +263296, hay +2144768, pumpkin +654272, water +18873, weird_substance +3031228, wood +64317568. Game time: 5h 59m 2s elapsed, 58s of budget remaining.
- 5h 59msaidAbout a minute of game time remains — I'll let it run out with the farm program still producing, then take a final snapshot.
- 5h 59m
waitseconds=40result
Waited 40s (time up). Program: farm running. Inventory change: fertilizer +32, gold +15488, water +1024, weird_substance -704. Game time: 5h 59m 52s elapsed, 8s of budget remaining.
- 5h 59msaidThe budget is used up (8s left, program still running). Final summary of the run: ## Result Farm: 22x22, 32 drones, speed maxed, all core upgrades bought (grass 10, carrots 10, trees 9, pumpkins 9, cactus 4, dinosaurs 4, mazes 5, polyculture 5, watering 9, fertilizer 4, megafarm 5). Resources produced (approximate final inventory, after heavy spending on upgrades): | Resource | Amount | |---|---| | Wood | ~160M | | Carrot | ~70M | | Weird substance | ~34M | | Hay | ~18M | | Cactus | ~7M | | Bone | ~2.8M | | Pumpkin | ~1.5M | | Gold | ~0.5M | | Power, water, fertilizer | produced and consumed continuously | ## How it worked - Early game: straight-line harvests → `can_harvest()` loop → bushes → carrots/trees checkerboard with hay-aware grass/carrot switching. - Mid game: a single mode-switching program (`farm`) with rounds for giant pumpkins, sunflower power (8x-petal harvesting), mazes for gold (wall-following), then multi-drone column workers once megafarm unlocked. - Late game: cactus rounds (plant all, parallel row/column bubble sort with `swap`, one harvest → n² cactus), dinosaur rounds (Hamiltonian-cycle snake for tail² bones), and polyculture, which multiplied tree/carrot/grass yields enormously. The main loop ran a fixed rotation (cactus → mixed block → pumpkin → mixed block) with maze batches each cycle. ## Mistakes worth noting - Stopping the program mid-maze or mid-dinosaur left the drone in a stuck state twice (hedge walls / dinosaur hat); fixed by resetting the hat at startup and making `goto` self-recover. - Mazes dominated drone time for ~20 minutes until I capped them per cycle. - Rounds that wipe the field destroyed unripe trees, starving wood until I grouped mixed sweeps into blocks of 4.
- 5h 59msaidWith 8 seconds left, the most useful thing is to let the farm program keep running to the final tick rather than spend the time on any other action.
- 5h 59m
waitseconds=8result
Waited 0s (time up). Program: farm running. Inventory change: no change. Game time: 6h elapsed, 0s of budget remaining. The game-time budget is used up. The run is over; stop now.
- 6h 00msaidThe budget is fully consumed — 6h elapsed, 0s remaining — and the game reports the run is over. There is nothing further to request: every remaining action would need game time that no longer exists, so no tool calls are warranted. Final state stands as summarized above: a 22x22 farm with 32 drones, maxed speed, and most upgrade tracks at or near their top levels, producing wood (~160M), carrots (~70M), weird substance (~34M), hay (~18M), cactus (~7M), bones (~2.8M), pumpkins (~1.5M), gold (~0.5M), plus continuous power, water, and fertilizer.
Thinking is shown as the agent reported it over ACP; some agents report a summary, not the full reasoning. Tool results are cut at 400 characters; program code is in evidence.json.
spent
What it spent
API-equivalent estimate at list prices; not an actual charge
Tokens
| Input (uncached) | 6,231 |
| Cache reads | 15,595,267 |
| Cache writes | 226,215 |
| Output | 113,467 |
| Thinking (subset of output where reported) | 46,895 |
| Total | 15,941,180 |
|---|
| Model | Tokens | Estimate |
|---|---|---|
| claude-fable-5-1 | 15,939,762 | $14.14 |
| claude-haiku-5-5 | 1,418 | $0.00015 |
Estimate: API-equivalent estimate at list prices; not an actual charge. Price table prices-2026-10-16b. The agent itself reported $14.14 (cost reported by the agent itself; plan or subscription billing may differ).
conditions
Limitations
- Recorded from a harness checkout with uncommitted changes.
| Run id | economy-v1-claude-fable-s3-a1-20261017T184247Z |
|---|---|
| Task | economy-v1 · acb5fb455a43 |
| Budget | 6h 00m game time · 10s per action · caps: 2,000 tool calls, 20 continuations, 4h 00m real time |
| Agent | Claude Agent 0.91.0 (@agentclientprotocol/claude-agent-acp) |
| Applied config | {"model":"fable","effort":"medium","fast":"absent"} |
| Models reported | claude-fable-5-1, claude-haiku-5-5 |
| Tools available | buy_upgrade, docs_list, docs_read, docs_search, inspect_tile, list_programs, observe, research, run_program, stop_program, wait, write_program |
| Harness | cd417a33b3bf (uncommitted changes) |
| Bridge / game | ae01202f355c / 953fea25964f |
| Adapters | claude-agent-acp 0.91.0, codex-acp 2.2.2, acp-sdk 1.8.0, mcp-sdk 1.32.1 |
| Rubrics | economy-v1 (headline) · Σ over resources of log10(1 + produced) · 51746c5bec27 economy-weighted-v1 · scores 8.25 · log10(1 + Σ w_r × produced_r), weights from late-game sink prices · 228b39065cbd |
| Started / ended | 2026-10-17T18:42:47.776Z → 2026-10-17T19:10:32.163Z |
| Evidence | 89 items in evidence.json |