Remix.run Logo
Buildcraft Is a Compiler Problem(mitander.xyz)
17 points by mitander 2 days ago | 4 comments
AlotOfReading an hour ago | parent | next [-]

There's another way to view this that I think is even more elegant:

You start with facts, which are composed by rules. The current state at any given instant is the fixed point of the derived facts. Provenance is the path through the derivation graph. The whole thing is relational algebra, like SQL or datalog.

A helpful side effect of this perspective is that it can adjust our performance expectations. For example, You can do an in-memory, in-process relational query in microseconds for thousands or millions of rows, way more than any realistic game scene. Incremental updates, etc are nice optimizations, but just let'er rip first and see how fast it goes.

You can even do these kinds of queries fast enough to end up memory bottlenecked if you restrict yourself to queries with fixed graph degree, which is admittedly a mouthful to say (and understand).

well_ackshually 3 hours ago | parent | prev | next [-]

>if skill == cleave and support == wide_sweep: make cleave radius bigger

if skill == cleave and support == focused_edge: make cleave smaller but stronger

if skill == cleave and support == twin_cleave and rule == guarded_arc: quietly move to the woods

>That can work for a demo. It gets rough once the game has lots of skills, supports, items, statuses, and encounter rules.

Laughs in path of building : https://github.com/PathOfBuildingCommunity/PathOfBuilding-Po...

Path of Exile has deeper mechanics than pretty much every other ARPGs out there, PoB covers the vast majority of them, in a beautiful mess of about 20k lines of calculations in various files.

Making it a "Compiler problem" makes it an unsolvable one in acceptable time.

Fun fact: it directly parses mods from their ingame description into a mod database that is basically a stringly typed list of whatever increases also. : https://github.com/PathOfBuildingCommunity/PathOfBuilding-Po...

Second fun fact: that's the one for Path of Exile 2, that has different mechanics. The PoE1 version is the same thing, except even larger.

So yeah, don't bother about making a compiler. Your compiler will figure out micro upgrades and die in three months when the game adds incompatible mechanics. Stay agile and on your feet.

ZeWaka 3 hours ago | parent | prev [-]

Darn, this title got me excited about Minecraft.

valorzard 2 hours ago | parent [-]

I’m glad I’m not the only one who thought about the classic 1.2.5 mod with the giant quarries that mined out entire chunks of the world, and the pipes you could use to make a Jaffa cake factory