Nate Bowman
3f183cdbd5
Fix adding task to work queue
2026-11-17 19:48:47 -05:00
Nate Bowman
dba4974e9f
Add tests
2026-11-16 20:11:05 -05:00
Nate Bowman
0780fec1fb
Fix bug in housing check and add test
2026-11-16 19:19:26 -05:00
Nate Bowman
1b9266ff09
Allow queuing villagers via task list
...
This is helpful for testing build orders.
2026-11-15 20:17:31 -05:00
Nate Bowman
3b07e6b3c5
Allow queuing villagers with more complex tasks
...
For instance, queuing a villager to build several buildings in a row is
now possible. Also adds a task queue for villagers. Any idle villager
will automatically grab the first task in the queue. The task queue is
used to implement the more complex initial villager tasks, so it is
possible that a different villager will do later tasks in the queued
villager's chain of tasks, but only if there are already idle villagers.
As long as the user does not wish to leave villagers idle for a long
time, this should not affect accuracy too badly.
2026-11-15 20:11:07 -05:00
Nate Bowman
2fc6b76db4
Fix floating-point problem
...
Shame on me for trying to compare floats directly. I hoped I could get
away with it this once, but I should know better.
2026-11-15 20:11:07 -05:00
Nate Bowman
24a0e9e16b
Allow hunting and building as initial tasks in a better way
2026-11-15 17:11:27 -05:00
Nate Bowman
7ce4b4a150
Revert "Allow hunting and building as initial villager tasks"
...
This reverts commit 8a8effe3d1 .
I did not like adding kwargs in so many places, so there will be an
upcoming commit that implements the same change in a different way.
2026-11-15 16:58:49 -05:00
Nate Bowman
8a8effe3d1
Allow hunting and building as initial villager tasks
2026-11-15 16:53:13 -05:00
Nate Bowman
e4aaba0320
Add routine to play until last action
2026-11-15 16:18:29 -05:00
Nate Bowman
e8c6e8eff8
Fix typo in test
2026-11-12 00:55:04 -05:00
Nate Bowman
8865950678
Allow user to choose whether getting housed is an error
...
Previously, the simulation would automatically end whenever it
determined you were housed. That is still the default, but the user can
now choose to have the simulation continue instead. Also, this likely
fixes a bug whereby an error could have been thrown for an unavailable
production building when searching the production queue.
2026-11-12 00:51:32 -05:00
Nate Bowman
20d4f5bd6c
Generate better error messages
2026-11-11 23:57:14 -05:00
Nate Bowman
5a5c6e1d3a
Add README
2026-11-08 21:32:07 -05:00
Nate Bowman
6680433770
Remove old info from description
2026-11-08 21:19:12 -05:00
Nate Bowman
9ccf25f0ab
Require a market to use buying and selling
2026-11-08 21:06:48 -05:00
Nate Bowman
e94af31828
Remove old comments
2026-11-08 21:01:38 -05:00
Nate Bowman
ec8b33ac00
Add ability to automatically queue villagers
2026-11-08 21:00:32 -05:00
Nate Bowman
c02aa3f736
Add warning about builders
2026-11-08 20:55:00 -05:00
Nate Bowman
e03911b78a
Modify farm and fishtrap code slightly
2026-11-08 20:51:38 -05:00
Nate Bowman
c6254e6d1e
Add fish traps
...
Also likely fixes bugs in farming and fishing, which were not tested
before
2026-11-08 20:26:38 -05:00
Nate Bowman
5f1999caac
Add market transactions
2026-11-07 20:00:07 -05:00
Nate Bowman
4d9da78842
Add trade
2026-11-07 19:59:11 -05:00
Nate Bowman
0d40fe5dc0
Add decay for huntables
2026-11-06 20:13:44 -05:00
Nate Bowman
85e441927b
Remove some helpers from test file
...
No longer need them now that I realized I can just cheat to set up the
world how I want it for the tests
2026-11-06 20:06:05 -05:00
Nate Bowman
61f98819bc
Add more tests
2026-11-06 19:24:12 -05:00
Nate Bowman
dd6526fb09
Add default villager task
...
Needed in case someone trains a villager through the default queue_unit
routine rather than the queue_villager routine
2026-11-06 19:22:35 -05:00
Nate Bowman
d5c0d928b6
Add fishing ships
2026-11-06 19:22:15 -05:00
Nate Bowman
5d2178cd9c
Add monks and relics
2026-11-06 19:21:32 -05:00
Nate Bowman
09d05e950b
Fix bug in housing check
2026-11-06 19:18:55 -05:00
Nate Bowman
54050235f0
Add functions to gameplay class
2026-11-06 19:16:22 -05:00
Nate Bowman
622bdc38fb
Remove runner file
...
Tests file shows examples of how to run the simulator
2026-11-06 19:14:52 -05:00
Nate Bowman
e67085aab7
Add boar luring
...
No decay accounted for yet
2026-11-06 19:13:57 -05:00
Nate Bowman
c6550fb007
Fix moving to next age
2026-11-06 19:09:15 -05:00
Nate Bowman
9e45d182b0
Add missing function
2026-11-06 19:08:39 -05:00
Nate Bowman
1f19740355
Fix bug in production queue
...
Queue was losing initial task
2026-11-06 19:06:53 -05:00
Nate Bowman
0fa68c6e32
Fix bug in gather rate decrease scheduling
...
Variable next_decrease can be 0 if the decrease should happen right now,
which caused the previous conditional to evaluate as False when it
should not have
2026-11-05 23:01:52 -05:00
Nate Bowman
c74fe5e451
Add some basic tests
2026-11-05 23:00:05 -05:00
Nate Bowman
d51980290b
Move functionality into gather file
2026-11-05 21:46:31 -05:00
Nate Bowman
00615c7c35
Reorganize more code
2026-07-31 19:50:22 -04:00
Nate Bowman
194925ab04
Move more code into gather file
2026-07-30 21:02:14 -04:00
Nate Bowman
e25abd87ab
Move more code into separate classes
...
It might make logical sense. Honestly, I'm just tired of the code for
World being so long.
2026-07-30 19:33:05 -04:00
Nate Bowman
d7dcc0d873
Uncomment some buildings now that we have their info
2026-07-29 21:20:55 -04:00
Nate Bowman
eb0e5b7d5a
Move dependencies code to separate class
2026-07-29 20:18:05 -04:00
Nate Bowman
3bcc133674
Combine unit and research functions
2026-07-28 19:51:05 -04:00
Nate Bowman
ebd3858aef
Enforce max population
2026-07-27 22:21:23 -04:00
Nate Bowman
9ff2613579
Add research and finish most buildings
2026-07-27 22:20:29 -04:00
Nate Bowman
013468d34e
Deal with farms and varying gather rates
2026-07-26 23:15:46 -04:00
Nate Bowman
4a014aeb50
Initial commit
2026-07-26 20:26:36 -04:00