Live data from Hacker News

How Dwarf Fortress is built

stackoverflow.blog

81–90 of 407 posts

Re: How Dwarf Fortress is built

#82

Making the item system polymorphic was ultimately a mistake, but that was a big one. Q: Why was this was a mistake? A: When you declare a class that’s a kind of item, it locks you into that structure much more tightly than if you just have member elements. It’s nice to be able to use virtual functions and that kind of thing, but the tradeoffs are just too much. I started using a “tool” item in the hierarchy, which st…

Prefer delegation over inheritance was one of the first OOP lessons I learnt. I read it in a C++ blog around 2004, it was explained very well with geometric shapes examples.

The only time I used inheritance was while implementing a job execution framework. It fit the pattern nicely.

Re: How Dwarf Fortress is built

#83

Earlier quoted context omitted.

Everything about it is wonderful (I really mean that) except the fact that he's sponging off his mother to do it. I can't help but feel that it's a drop of vinegar that spoils the whole cup of milk

I think it's OK as long as they feel it's OK. We can say that his mother "sponsors" the project.

Edit: I was wrong about how much he is relying on his family - didn't realize how much Patreon support the project now has compared to when I last looked. My bad, should have checked. I still agree with the below in the abstract but I retract my criticism in this case

I can get with that take when it comes to Patreon but it's harder to demonstrate ok-ness-with-it with family. Let's say she's really not all that jazzed about it, actually. What is she gonna do, throw her son out on the street? A lot of parents don't have it in them to do that even if they think they would be justified and it would be the best thing for their child. An adult shouldn't put their parents in that position. He should be making sure his mom is provided for, not the other way around

Re: How Dwarf Fortress is built

#84

Earlier quoted context omitted.

Unfortunately it remains unexplained (by the article) why this is considered a bug. It would be unethical to test, but this seems like perfectly cromulent behavior one might actually see in real life.

IIRC the actual bug was that cats licking their paws made them consume an entire tankard's worth of beer with each lick, which made them drunk (and dead) with just a few licks.

Yeah this is what I recall being the case as well.

Re: How Dwarf Fortress is built

#85

Df is just like OpenTTD. Both are like Chess, easy to start, fun to play casually but it takes years to master. Great games, complex if you want to and a time sink if you don't keep an eye on it. Have had many hundreds of fun hours in both games

Dwarf Fortress seems incredibly hard to start to me. The UI is chaotic and the "graphics" verge on incoherent.

Re: How Dwarf Fortress is built

#86

Earlier quoted context omitted.

Hickey nails this one in his talks. When you make something a class, that's NOT an abstraction, that's a concretion. You make a Tool class, you haven't abstracted what a tool is, you've made a fixed decision about what it is. For games that want this level of complex interaction between components, entity component systems are the way to go.

I’d love a reference to this talk.

"Maybe Not" talks about these compositional ideas: https://www.youtube.com/watch?v=YR5WdGrpoug

Re: How Dwarf Fortress is built

#88
post #2

I read everything about this game I can get my hands on. I don’t fully understand why I find dwarf fortress so intriguing. It’s such a pure passion project… that actually made it.

Do you actually play it? I'm a bit the same about reading about it, yet I have never once played it for myself!

Hah, this is like EVE Online for me. I love reading about the espionage and cloak and dagger and pure insanity, but other than a brief toe-dip...oh no I will not play it.

DF lives in my blood, however.

Re: How Dwarf Fortress is built

#89
post #62

Earlier quoted context omitted.

No it isn't! It's so easy and effective for keeping track of your work and backups. If you want the absolute simplest way to use git, just setup an alias to do: alias gcmp="git add -A && git commit && git push" Now all you need to do is run gcmp every time you're ready to log the new state of your codebase. How could it be simpler? git only becomes more complex as your needs become more complex. At which point I'd re…

git commit to which branch? git push to which branch?

Master/main? It's a single branch workflow.

Re: How Dwarf Fortress is built

#90

Making the item system polymorphic was ultimately a mistake, but that was a big one. Q: Why was this was a mistake? A: When you declare a class that’s a kind of item, it locks you into that structure much more tightly than if you just have member elements. It’s nice to be able to use virtual functions and that kind of thing, but the tradeoffs are just too much. I started using a “tool” item in the hierarchy, which st…

[deleted]
Post reply on HN