philihp / fields-of-arle Goto Github PK
View Code? Open in Web Editor NEWFields of Arle Simulator
Home Page: https://arle.philihp.com
License: GNU General Public License v3.0
Fields of Arle Simulator
Home Page: https://arle.philihp.com
License: GNU General Public License v3.0
If you're into functional programming, this task represents a fun task/puzzle.
Implement sheering
here:
fields-of-arle/src/game/endOfRound.js
Lines 106 to 110 in 5bfb374
Given a player
object, return a new player
object with baby animals in it, given by the following rule:
Further clarification in page 8 of the rules: https://boardgamegeek.com/filepage/107460/fields-arle-rulebook
If you'd like to write a test suite for this, export the function and put the test in ./__tests__/endOfRound.test.js
Issue to serve as a checklist for implementing the buildings.
Tests are busted. I think it happened when I did an eject of create react app. Would be nice to be able to write some tests again.
> [email protected] test /Users/philihp/work/fields-of-arle
> node scripts/test.js --env=jsdom
2018-10-22 22:57 node[60182] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
2018-10-22 22:57 node[60182] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
2018-10-22 22:57 node[60182] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
events.js:183
throw er; // Unhandled 'error' event
^
Error: Error watching file for changes: EMFILE
at FSEvent.FSWatcher._handle.onchange (fs.js:1359:9)
npm ERR! Test failed. See above for more details.
Good bug for someone getting their feet wet:
The Imitate action consumes 2 food from the current player. As such, the current player should not be allowed to take this action if they don't have 2 food. This issue has two parts:
First, the Laborer job should not do anything if the client attempts to try to do it without 2 food. Currently it just takes 2 food away and allows the player to go negative. https://github.com/philihp/fields-of-arle/blob/master/src/game/jobs/laborer.js
Second, on the Action component, disable the buttons if they have less than 2 food. A good starting place is right here:
https://github.com/philihp/fields-of-arle/blob/master/src/components/actionsBoard.js#L355-L370
Best to satisfy the first requirement first, since the second will make it difficult to test the first.
Checklist for each of the buildings - do a thing when it's built
Page 9: you can return animals to the supply at any time
Page 10: you can return vehicles to the supply at any time
To allow this, implement a button like "Arrange" and "Load", which asks the user what token they'd like to return to the supply.
I'm really really looking for a good web designer for this. If you'd simply like to play around with CSS and make something that looks good, I would happily welcome a PR.
You would not be able to use copyrighted artwork from the actual game itself, but maybe something that looks like the aesthetic of the original? https://boardgamegeek.com/boardgame/159675/fields-arle
Right now a Warden can flip a moor tile, but the drained moor doesn't have any peat on it so it never can be cut and cleared
Also a Warden shouldn't be able to flip a dMoor tile
https://github.com/philihp/fields-of-arle/blob/master/src/game/common/player.js#L101
No good can go above 15.
That's all. This one's easy.
If you're into functional programming, this task represents a fun task/puzzle.
Implement babyAnimals
here:
fields-of-arle/src/game/endOfRound.js
Lines 77 to 81 in 5bfb374
Given a player
object, return a new player
object with baby animals in it, given by the following rule:
Each spring (May), animals will breed.
Further clarification in page 8 of the rules: https://boardgamegeek.com/filepage/107460/fields-arle-rulebook
If you'd like to write a test suite for this, export the function and put the test in ./__tests__/endOfRound.test.js
Followup to #60, player should be able to get up to 30 food, rather than 15 as with all the other goods.
Player should be able to be something like
{
"goods": {
"food": 23,
"wool": 10,
"grain": 15,
"flax": 4,
}
}
Update the Webpack dependency to Webpack 4.
This will probably require some config changes to ensure the game still loads. At a minimum, it should still:
npm run start
npm run build
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.