Hacker News new | ask | show | jobs
by qw3rty01 1909 days ago
You can absolutely refactor in factorio...in fact you have to refactor as you get access to better technologies. Just like software, refactorability is largely dependent on how well you design your base at the beginning. If you leave plenty of room for expansion and compartmentalize different production areas, it makes it extremely easy to upgrade with minimal disruption to the factory. And also like software, if you don't put any thought into the design at the beginning, it will probably be easier to start from scratch than try to redesign on the fly.
1 comments

Ultimately how well your base is designed is completely based upon what things you need to produce in the future, what their inputs are, what their outputs are, what those outputs will be inputs into, and in which quantities you need to produce all of this stuff.

These are all things a new player has no clue about. All you're really saying is an experienced player that has done enough researching and equation balancing (X miners feeds Y furnaces and a line of belt can support Z miners) ahead of time should be able to design a base that doesn't require too much demolishing. And presumably, not overdesign in unnecessary base components.

It assumes perfect knowledge.

The closest to refactoring in Factorio is the ability to use bots to tear down and build blueprints. But you get that ability long after it would first be useful - that would be around when you get plastics, which easily triples the size of your base.

Ultimately how well your program is designed is completely based upon what features you need to develop in the future, what their parameters are, what their return values are, what those return values will be arguments into, and in what scales you need to run all of this stuff.

These are all things a new programmer has no clue about. All you're really saying is an experienced programmer that has done enough researching and equation balancing (X algorithms feeds Y threads and a processor can support Z cores) ahead of time should be able to design a program that doesn't require too much changes in the future. And presumably, not overdesign in unnecessary micro optimizations.

It assumes perfect knowledge.

The closest to refactoring in programming is the ability to use IDEs to remove dead code and do code generation. But programers learn about IDEs long after they would first be useful - that would be around when you get to integrations, which easily triples the code base of your program.

Everything you mentioned is also true about programming