🌸🍇🍈🍉🍊🍋
A project for Procjam 2019.
This program uses a graph grammar to generate diagrams of the flow of goods in a toy economy. Plants are eaten, or processed into food and materials. Ore is mined, refined, and made into machines.
- Generate a graph with all the components of the economy labelled with emoji.
- Calculate max-flow given a restricted amount of source capacity.
- Generate a utility function that rewards consumption of multiple types of goods. (Maybe label some as substitutes or complements in the graph.) Figure out how to calculate a flow that maximizes this utility.
- Duplicate the economic graph and disable parts of it to generate isolated economies that would benefit from trade.
- Create trading routes between the economies.
- Cute web page that animates the result.
Emojiconomy uses pipenv. Run
pipenv install
pipenv run python -m emojiconomy.planets
The files econ-full-flow.svg
and econ-full.svg
will show the full economy and its optimal solution. There will be a lot of debugging output as the auction mechanism is run. The files step-NN-PPPP-flow.svg
show intermediate steps for planet/region PPPP after NN auction rounds.
When the auction is completed (200 rounds) the final output will be:
econ-PPPP-flow.svg
: planet PPPP's economic flowplanet-trade.svg
: graph showing all tradesgalaxy.pickle
: pickled version of the final state
I will be presnting a lightning talk on Emojiconomy at Roguelike Celebration 2020.