├── .ackrc
├── .gitattributes
├── LICENSE
├── README.md
├── bower_components
├── d3
│ ├── .bower.json
│ ├── LICENSE
│ ├── README.md
│ ├── bower.json
│ ├── d3.js
│ └── d3.min.js
├── dagre-d3
│ ├── .bower.json
│ ├── LICENSE
│ ├── bower.json
│ ├── demo
│ │ ├── arrows.html
│ │ ├── clusters.html
│ │ ├── demo.css
│ │ ├── demo.js
│ │ ├── dom.html
│ │ ├── etl-status.html
│ │ ├── graph-story-board.html
│ │ ├── hover.html
│ │ ├── interactive-demo.html
│ │ ├── sentence-tokenization.html
│ │ ├── shapes.html
│ │ ├── style-attrs.html
│ │ ├── svg-labels.html
│ │ ├── tcp-state-diagram.html
│ │ ├── tipsy.css
│ │ ├── tipsy.js
│ │ └── user-defined.html
│ ├── dist
│ │ ├── dagre-d3.core.js
│ │ ├── dagre-d3.core.min.js
│ │ └── dagre-d3.core.min.js.map
│ └── gulpfile.js
├── dagre
│ ├── .bower.json
│ ├── LICENSE
│ ├── bower.json
│ └── dist
│ │ ├── dagre.core.js
│ │ └── dagre.core.min.js
├── graphlib
│ ├── .bower.json
│ ├── LICENSE
│ ├── bower.json
│ └── dist
│ │ ├── graphlib.core.js
│ │ └── graphlib.core.min.js
└── lodash
│ ├── .bower.json
│ ├── LICENSE
│ ├── bower.json
│ ├── lodash.js
│ └── lodash.min.js
├── bulk.jsx
├── calc.css
├── calc.jsx
├── calc.lua
├── calculator.js
├── data
├── core-0-10-2.lua
├── core-0-11-3.lua
├── core-0-12-33.lua
├── core-0-13-15.lua
├── core-0-13-20.lua
├── core-0-14-20.lua
├── core-0-14-22.lua
├── core-0-15-2.lua
├── core-0-15-9.lua
├── core-0-16-51.lua
└── core-0-9-8.lua
├── dataloader.lua
├── datasource.jsx
├── explain.jsx
├── ffi.js
├── ffi.lua
├── graph.jsx
├── index.html
├── ingredients.jsx
├── input.jsx
├── lua.vm.js
├── options.jsx
└── serve-github-pages.rb
/.ackrc:
--------------------------------------------------------------------------------
1 | --ignore-file=is:lua.vm.js
2 | --ignore-dir=bower_components
3 | --ignore-dir=data
4 |
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | # Don't show diffs for lua.vm.js, we're not going to read them anyway.
2 | # https://www.git-scm.com/docs/gitattributes#_defining_macro_attributes
3 | /lua.vm.js binary
4 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | # factorio-calc
2 |
3 | The MIT License (MIT)
4 |
5 | Copyright (c) 2014 Ruy Asan
6 |
7 | Permission is hereby granted, free of charge, to any person obtaining a copy
8 | of this software and associated documentation files (the "Software"), to deal
9 | in the Software without restriction, including without limitation the rights
10 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11 | copies of the Software, and to permit persons to whom the Software is
12 | furnished to do so, subject to the following conditions:
13 |
14 | The above copyright notice and this permission notice shall be included in all
15 | copies or substantial portions of the Software.
16 |
17 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23 | SOFTWARE.
24 |
25 | # lua.vm.js
26 |
27 | The MIT License (MIT)
28 |
29 | Copyright (c) 2013 Alon Zakai (kripken)
30 | Copyright (c) 2014-2016 Daurnimator
31 |
32 | Permission is hereby granted, free of charge, to any person obtaining a copy of
33 | this software and associated documentation files (the "Software"), to deal in
34 | the Software without restriction, including without limitation the rights to
35 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
36 | the Software, and to permit persons to whom the Software is furnished to do so,
37 | subject to the following conditions:
38 |
39 | The above copyright notice and this permission notice shall be included in all
40 | copies or substantial portions of the Software.
41 |
42 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
43 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
44 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
45 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
46 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
47 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
48 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | factorio-calc
2 | =============
3 |
4 | For all your obsessive optimizing needs
5 |
6 | # Contribute a data source #
7 |
8 | Additional data sources are welcome - the calculator should work just fine with mods!
9 |
10 | - Fork this repository
11 | - Add a file containing the recipe dumps to the `data` folder:
12 | + Choose a short descriptive name without any periods (dashes are ok)
13 | + Concentrate all recipe files into one
14 | + e.g. `cat factorio/data/base/prototypes/recipe/*.lua > factorio-calc/data/core-2-0-0.lua`
15 | - Open up `index.html` and add the data source name (in the above example `core-2-0-0`) to the `DATALIBS` array near the top.
16 | - Send me a pull request form your branch, and that's it!
17 |
18 |
19 | ## See Also ##
20 |
21 | [Forum Thread](http://www.factorioforums.com/forum/viewtopic.php?f=5&t=4553)
--------------------------------------------------------------------------------
/bower_components/d3/.bower.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "d3",
3 | "description": "A JavaScript visualization library for HTML and SVG.",
4 | "main": "d3.js",
5 | "license": "BSD-3-Clause",
6 | "ignore": [],
7 | "homepage": "https://github.com/mbostock-bower/d3-bower",
8 | "version": "3.5.16",
9 | "_release": "3.5.16",
10 | "_resolution": {
11 | "type": "version",
12 | "tag": "v3.5.16",
13 | "commit": "f541593777ebe842059fda09d3ce1b6de8b29a7d"
14 | },
15 | "_source": "git://github.com/mbostock-bower/d3-bower.git",
16 | "_target": "^3.3.8",
17 | "_originalSource": "d3"
18 | }
--------------------------------------------------------------------------------
/bower_components/d3/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright (c) 2010-2016, Michael Bostock
2 | All rights reserved.
3 |
4 | Redistribution and use in source and binary forms, with or without
5 | modification, are permitted provided that the following conditions are met:
6 |
7 | * Redistributions of source code must retain the above copyright notice, this
8 | list of conditions and the following disclaimer.
9 |
10 | * Redistributions in binary form must reproduce the above copyright notice,
11 | this list of conditions and the following disclaimer in the documentation
12 | and/or other materials provided with the distribution.
13 |
14 | * The name Michael Bostock may not be used to endorse or promote products
15 | derived from this software without specific prior written permission.
16 |
17 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
18 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
20 | DISCLAIMED. IN NO EVENT SHALL MICHAEL BOSTOCK BE LIABLE FOR ANY DIRECT,
21 | INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
22 | BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23 | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
24 | OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
25 | NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
26 | EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 |
--------------------------------------------------------------------------------
/bower_components/d3/README.md:
--------------------------------------------------------------------------------
1 | # Data-Driven Documents
2 |
3 |
4 |
5 | **D3.js** is a JavaScript library for manipulating documents based on data. **D3** helps you bring data to life using HTML, SVG, and CSS. **D3** emphasizes web standards and combines powerful visualization components with a data-driven approach to DOM manipulation, giving you the full capabilities of modern browsers without tying yourself to a proprietary framework.
6 |
7 | Want to learn more? [See the wiki.](https://github.com/mbostock/d3/wiki)
8 |
9 | For examples, [see the gallery](https://github.com/mbostock/d3/wiki/Gallery) and [mbostock’s bl.ocks](http://bl.ocks.org/mbostock).
10 |
--------------------------------------------------------------------------------
/bower_components/d3/bower.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "d3",
3 | "description": "A JavaScript visualization library for HTML and SVG.",
4 | "main": "d3.js",
5 | "license": "BSD-3-Clause",
6 | "ignore": []
7 | }
8 |
--------------------------------------------------------------------------------
/bower_components/dagre-d3/.bower.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "dagre-d3",
3 | "version": "0.4.17",
4 | "main": [
5 | "dist/dagre-d3.core.js"
6 | ],
7 | "ignore": [
8 | ".*",
9 | "README.md",
10 | "CHANGELOG.md",
11 | "Makefile",
12 | "browser.js",
13 | "build/**",
14 | "dist/dagre-d3.js",
15 | "dist/dagre-d3.min.js",
16 | "dist/dagre-d3.min.js.map",
17 | "dist/demo/**",
18 | "index.js",
19 | "karma*",
20 | "lib/**",
21 | "package.json",
22 | "src/**",
23 | "test/**"
24 | ],
25 | "dependencies": {
26 | "d3": "^3.3.8",
27 | "dagre": "^0.7.3",
28 | "graphlib": "^1.0.5",
29 | "lodash": "^3.10.0"
30 | },
31 | "homepage": "https://github.com/cpettitt/dagre-d3",
32 | "_release": "0.4.17",
33 | "_resolution": {
34 | "type": "version",
35 | "tag": "v0.4.17",
36 | "commit": "88bea485d5556382c1c50f7012d9ebd2ec5c270f"
37 | },
38 | "_source": "git://github.com/cpettitt/dagre-d3.git",
39 | "_target": "~0.4.3",
40 | "_originalSource": "dagre-d3"
41 | }
--------------------------------------------------------------------------------
/bower_components/dagre-d3/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright (c) 2013 Chris Pettitt
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is
8 | furnished to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in
11 | all copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 | THE SOFTWARE.
20 |
--------------------------------------------------------------------------------
/bower_components/dagre-d3/bower.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "dagre-d3",
3 | "version": "0.4.17",
4 | "main": [
5 | "dist/dagre-d3.core.js"
6 | ],
7 | "ignore": [
8 | ".*",
9 | "README.md",
10 | "CHANGELOG.md",
11 | "Makefile",
12 | "browser.js",
13 | "build/**",
14 | "dist/dagre-d3.js",
15 | "dist/dagre-d3.min.js",
16 | "dist/dagre-d3.min.js.map",
17 | "dist/demo/**",
18 | "index.js",
19 | "karma*",
20 | "lib/**",
21 | "package.json",
22 | "src/**",
23 | "test/**"
24 | ],
25 | "dependencies": {
26 | "d3": "^3.3.8",
27 | "dagre": "^0.7.3",
28 | "graphlib": "^1.0.5",
29 | "lodash": "^3.10.0"
30 | }
31 | }
--------------------------------------------------------------------------------
/bower_components/dagre-d3/demo/arrows.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
A sample that shows the different arrows available in dagre-d3. 36 |
An example of visualizing clusters. This example shows 41 | how clusters can be applied to a rendered graph. 42 |
A sample showing how to use DOM nodes in a graph. Note that IE does not 59 | support this technique. 60 |