19 ms·
Coffee Is Hard
- password1 7y agoIt was so well written that he made me want to play his purposefully frustrating game and I'm still disappointed he didn't provide a link to download it.
- whatshisface 7y agoThe first puzzle is the search for the game itself.
- bap 7y agoIf you download it from the wrong mirror..
- czinck 7y agoProbably worth noting that he also wrote the very well done "Programming Sucks" article, https://www.stilldrinking.org/programming-sucks https://www.stilldrinking.org/programming-sucks and the original HN discussion https://news.ycombinator.com/item?id=7667825 https://news.ycombinator.com/item?id=7667825. If you hadn't read that post, definitely worth it.
- arcticbull 7y ago"Programming Sucks" is genuinely one of my favorite pieces of writing. If y'all haven't it's very much worth a read.
- mbillie1 7y agoAbsolutely my favorite (funny) thing about programming ever written.
- comicjk 7y agoI like the core description of programming, but the framing - that programming is tougher than manual labor - is childish. Life is not a competition for whose job is hardest, and if it were, no one on Hacker News would win it.
- erikpukinskis 7y ago> no one on Hacker News would win it. That might be true, but it doesn’t seem like a thing you could know.
- Doxin 7y ago> Life is not a competition for whose job is hardest I think the author agrees, and wrote the article mostly as a response to people who think it is.
- AdmiralAsshat 7y agoThis reminds me of Scribblenauts. There was an interview with one of the devs at the E3 before it was released and he discussed how much time went into the game simply to pad the internal "dictionary" and conjure up not just things, but also make sure that those things could interact with other things (e.g. "bread" should be able to interact with "toaster" to make "toast"). I don't remember if it was the dev talking about his own team, or if he was talking about players interacting with the demo, but he mentioned that some people were attempting to summon a list of ingredients (flour, eggs, sugar, milk, etc.) and throw them into a bowl and then into a heat source to see if they could make cookies within the game.
- journalctl 7y agoOh wow, Scribblenauts takes me back! I love games like that. Half the fun is sitting there just figuring out what interacts with what. If I recall correctly, you can conjure up a Large Hadron Collider, which blows up and makes you lose a life. It sounds tedious to program for sure, but the result was amazingly fun.
- throwaway66920 7y agoI always thought that game must have an incredible ontology underneath it that would be amazingly useful to other ventures... I also recall playing it and, at a certain point, realizing that I was stubbornly uncreative in using the variety of options available to me. In retrospect maybe that wasn’t true, and the game managed the massive potential for variance by condensing things into smaller buckets. Either way those were some brave developers agreeing to that project scope.
- AdmiralAsshat 7y agoTake a look for yourself: https://gamasutra.com/view/news/300313/Scribblenauts_dev_shares_lessons_learned_in_making_its_huge_object_library.php https://gamasutra.com/view/news/300313/Scribblenauts_dev_sha...
- scrollaway 7y ago
- godot 7y agoAs a geek and a fan of 80s-90s PC games (not just Sierra but also LucasArts adventure games and so on), this was a super entertaining read on its own; but I also enjoyed some of these insights about life in general from it: > Living is mostly a series of repetitive and unrelated tasks. It makes sense that the most tedious things to code are the tedious things that just have to be done. There are no life lessons or gymnastic skills involved in doing dishes, there’s no underlying theory of housework that will reveal itself after a thousand vacuum cleanings. Making coffee is a boring sequence of steps people feel stupid for getting wrong, even though they’re statistically doomed to screw it up now and then. The hard parts of of life are driving to work, eating properly, flossing, .... Perhaps I found it particular insightful because I just became a parent a year ago. Prior to this, I thought I had optimized my life so well that most tedious work were gone from my life; with the peak being having switched to remote work and not having to even commute anymore. Then I became a parent, and had to come to terms again with having to do a long series of repetitive and routine work every day -- washing bottles, dishes, changing diapers, etc. It was a bit of a cultural shock to my system since over the past 10 years I had slowly gotten used to / gradually removed or optimized aspects that are frictions / repetitiveness / tedious routines from my life; and suddenly it's 10x of it all coming back. Over the past year, I've come to realize this is what life is, which is exactly as the author said.
- LunaSea 7y agoInteresting! What kind of life optimizations did you use before?
- shantly 7y agoHaving money and spending it to make other people do your boring stuff is a pretty effective life optimization. Cleaning, laundry, cooking, lawn care, car maintenance—even driving—can all be bought, so you barely have to do any of it again, if you've got money. You can—and most with means do, I think—just make almost any of this "this is what life mostly is" boring crap go away, unless you actually enjoy it more than what you might be doing instead. Making the tedious parts of raising a kid go away is a lot more expensive than making the normal adult boring stuff go away, though. Also if you're not fairly damn rich (i.e. rich enough not to need a real job) the boring parts will be most of the time you spend with your kids by a large margin, so you'll be reluctant to outsource that even if you can afford to. That's even more true if you're not paying to have the rest of your boring stuff done by someone else ("sorry honey, maybe we can play blocks later, I'm cooking dinner because if I don't we won't, you know, have any" but then later it's bath time then story and bed and maybe you squeeze in 10min of blocks if you're lucky)
- Torwald 7y agoIf you like doing your own adventure game, this may be interesting: http://www.skotos.net http://www.skotos.net
- TurkishPoptart 7y agoI really like this guy's writing and am grateful that he shared some of the coding challenges. I'd really like to be able to program games like this, and while I'm not a programmer, I'd like to learn how. In TFA he shares some of the code to check the coffee "state": >'LOOK AT COFFEE MAKER': () => { if( State.scene.state.coffeedrunk ) { return "The coffee maker has done its job and mercifully drained the last life out of the old and savaged grounds." } else if( State.scene.state.brewed ) { return "The coffee maker has a fresh pot of what is likely coffee in it." } else if( State.scene.state.brewing ) { return "The coffee maker is brewing." } else if( State.scene.state.waterinmaker ) { return "The coffee maker has fresh water in it, and is ready to brew a terrible cup of coffee." } else { return "Makes coffee. Whodathunk? There's no water in it, and you don't have any fresh coffee, but the grounds already in there have only been used twice and can't be THAT moldy." } } This is JavaScript right? Is that how these sorts of games are coded? Would learning this be the best way to go about creating games? Thanks.
- whatshisface 7y agoIt looks like JavaScript to me. Yes, these games are usually coded in scripting languages like JS or Python, even back in the day they were programmed in custom scripting languages running on the engines of yore. Finally, yes, these kinds of games are a great way to learn programming because they map very well on to basic control flow constructs (if, else, while) and don't usually require additional computer science knowledge.
- drankula3 7y agoFor python, check out pygame. It's outdated and only works with 2.7, but I think it can be installed with apt on Ubuntu and will teach the basics like rendering loops, frames, etc.
- throwaway377373 7y agoIt works with Python 3.7 now, and has for sometime. `sudo pip install pygame`
- gameguy43 7y agoAmped to see Still Drinking on HN again. If you enjoy devouring this guys writing, buy his book, “And Then I Thought I Was A Fish” (I think it’s the “novel” he references the game being based on?). I really really liked it. Link at the bottom of the original post. The other book is just a collection of blog posts. It’s /okay/. But I really really liked ATITIWAF. The kind of book that makes you want to try your hand at writing. —a random internet fan.
- icebraining 7y agoNever read the book, but I'm a fan of his blog! I keep an excerpt of one of his posts pinned on my notes app: "The only reason coders' computers work better than non-coders' computers is coders know computers are schizophrenic little children with auto-immune diseases and we don't beat them when they're bad." https://www.stilldrinking.org/programming-sucks https://www.stilldrinking.org/programming-sucks
- deleted 7y ago[deleted]
- meroes 7y agoI would also recommend his story about acid to anyone https://www.stilldrinking.org/the-episode-part-1 https://www.stilldrinking.org/the-episode-part-1
- halleonard 7y agoThat book is so crazy good! I started reading and read it all the way through in one setting and then passed it off to all of my friends. Remarkable writing and I also felt it to be quite wise.
- aidenn0 7y agoAs an example of one of the more notorious puzzles in the Sierra games of yesteryear, in Space Quest, you have a sand skimmer (think Luke's sand speeder). When you get to where you are going, you need to sell it for money. If you get out without removing your keys, it is stolen. Then someone offers you enough money to continue on in the game. If you say yes, then much later in the game you die because you don't have a jetpack. If you say no, they offer to throw in their old jetpack. There are literally no hints that a jetpack would be related to selling your skimmer. You just have to reload old saves and try random things until you get one. And hope you have enough saves that you didn't overwrite one from before you sold the skimmer, or you need to start the whole game over.
- raldi 7y agoThis is a major piece of the linked article.
- aidenn0 7y agoWow, I totally skimmed over that.
- SamBam 7y agoHaving played most of the Sierra and LucasArts games when I was much younger, I feel, though cannot confirm, that there was a shift in these kinds of games such that you couldn't actually progress too far beyond a fail state. That is, by about Space Quest II or III, you could still take an action that would lead to your death within a minute or so, but you could no longer take actions that would lead you to dying/being unable to finish many, many scenes later. Can anyone confirm this? And I feel like the later LucasArts games (Day of the Tentacle, etc) you could never actually be in a fail state.
- aidenn0 7y agoLucasArts had a very strong bent towards not putting you in a fail state. My understanding is that Sierra was intending to be more fair as time went on, but they had a bias against playtesting so there were still some big goofs that got through. I think all of the first 5 KQ games had ways to lose items that would later be needed to win. KQ VI had a branching path and if you picked the "easy" branch you were unlikely to end up in a very unwinnable state, but there was no indication at the time of the branch that you were doing so (IIRC you were about to be burned alive and you could either use some maid's clothes to put out the fire, destroying the clothes, or cast a spell that required boiling some water, using up some component). With a hint-book it took me several attempts to make it through the "hard" path.
- ctdonath 7y agoI'd be happy to articulate the hard way to make a really good cup of coffee, starting with ordering green coffee beans and proceeding thru barista tools few are familiar with. (Might take a while to write.) Plenty of ways for the process to go wrong, including lethally.
- deng 7y agoI really recommend the author's book "And then I thought I was a fish". Not only is it incredibly funny, in my opinion this is one of the best descriptions of a drug-induced psychosis out there. It is really pretty rare that someone can remember that much from such an episode and also has the ability to put it to paper.
- hinkley 7y agoHis thesis at the end explains all of the memes about Link being a monster with a grudge against anyone who own pottery.
- acomjean 7y agoAdventure game frustration was solved, and used to make some classics. https://grumpygamer.com/puzzle_dependency_charts https://grumpygamer.com/puzzle_dependency_charts some adventure game puzzles became way too obtuse to be fun. https://www.oldmanmurray.com/features/77.html https://www.oldmanmurray.com/features/77.html
- wool_gather 7y agoOh, the dependency graph article is very interesting. Reminds me of this logic programming tutorial, writing a (tiny) adventure game (with Prolog specifically): http://www.amzi.com/AdventureInProlog/a1start.php http://www.amzi.com/AdventureInProlog/a1start.php
- irascible 7y agoMinor nitpick.. Tumble off his mortal coil... Looks like a play on "shuffle off this mortal coil" which doesn't mean standing on, and then shuffling away from.. it means removing the mortal coil, that is coiled around you, tying you to the earth.
- deckar01 7y agoWaiting for a Haskell programmer to explain why this is an artifact of procedural languages and that making coffee should be abstracted as the death of coffee caused by hot water.
- phlakaton 7y agoCoffee is just a fixpoint of the coffee-maker state transition monad; what's the problem?
- platz 7y agoI think you're confusing Haskell with the second law of thermodynamics and that the universe started in an extremely low entropy state resulting in the arrow of time which causes the coffee to do it's thing
- zem 7y agothey'll only explain if you force them to
- SamBam 7y agoAlways pining for more adventure games that remind me of the Sierra/LucasArts games of my youth. Can we start a thread here of great modern examples? I recently played Machinarium, and enjoyed it a lot. My wife and I played it for many evenings on the couch, and computer games are not her thing at all. I'm finishing up Infamous Machine on my Android phone. It's a fairly silly, small game, but a direct homage to LucasArts games like Day of the Tentacle.
- manifestsilence 7y agoNeverhood and Samorost are also fun. The latter is by the Machinarium creators.
- jccooper 7y agoThimbleweed Park.
- cousin_it 7y agoMilkmaid of the Milky Way
- coded 7y agoPeasants Quest (although it’s not that new) Fester Mudd - Curse of the Gold Broken Age
- cagenut 7y agoThinking about stuff like this is fascinating in the context of just how much massively more of a big deal its going to become very very soon. Specifically, if you draw the trend line on the size and price of kuka/fanuc/abb robot arms, and you put UR's models in there for today, we are really only 3 - 5 years away from you having a robot arm sitting on your kitchen counter that you can script to make your coffee for you. So all of these bugs will become real :)
- RugnirViking 7y agoWhile UR robots are techincally collaborative robots (rated safe for operation without a cage around them), I am sure that putting them into people's homes is asking for trouble.
- cagenut 7y agotrouble's coming!
- pololee 7y ago> I like Git commit messages. Used well, I think they’re one of the most powerful tools available to document a codebase over its lifetime. 1000000% agree!
- sulZ 7y agoI think that you may have replied to the wrong thread[0] [0] https://news.ycombinator.com/item?id=21289827 https://news.ycombinator.com/item?id=21289827
- pololee 7y agoOo. Thx.
- manifestsilence 7y agoHaving just read the other thread, this gave me a great moment of confusion and deja vu as the two trains of thought entangled in my mind. Kudos. :)
- pugworthy 7y agoI'm curious why people would have voted this person's comment down, simply for a mistake. Seems sort of harsh to do that to someone's reputation simply for a mistake.
- jodrellblank 7y agoBecause almost everyone who comes to this thread has a better experience if that comment is buried down at the bottom in "don't bother reading territory".
- deleted 7y ago[deleted]
- ergothus 7y ago> Most treasured memories are agonies that won’t get out of the mind and have to get turned into a character-building story to maintain sanity, My world is changed by how obvious yet insightful this is.
- caseymarquis 7y agoHaving enjoyed the article, it also reminded me why I never once finished making a game. Instead of seeing the example code and thinking 'Ah, yes, that code gets something done in a straight-forward way.', I instead think, 'I'm pretty sure I could build a scripting engine and turn most of that code into ajax calls to json files. Of course, I'd then have to build an in-game editor which allowed you to modify the contents of the json files while playing the game with hot-swapping content. Huh, art? Plot? Fun? Oh, yeah, I guess I'll probably need those... eventually...' Fortunately, trying (and failing) to make games led me to realize that I really love programming and building maintainable systems.
- acbart 7y agoThis speaks to me. I used to spend my childhood tweaking and retweaking my game engines. Never really got my games past the cool demo phase. I guess I also now stay with maintainable systems too.
- Doxin 7y agoI too, highly prefer building game engines above building games. Not that I ever finish a game engine either but at least it keeps me busy I suppose. And who knows, I could hit on the big new paradigm in game programming at any point ;-)
- aasasd 7y agoI'm having flashbacks to late 90s–early 2000s, when oldschool adventures were on their last legs and I still thought that I could make one just by putting together a hundred random puzzles.
- bluejay2387 7y agoTake a look at rules engines and Expert Systems technology. Its a more declarative way to handle complex logic that allows you to state facts and let a inference engine handle the nested nature of dependent logical conditions. It will decrease the amount of work needed to code this part of your game. With your current approach you end up in the logic programming version of Node's call back hell before we had tools like async await. As an aside, I run into developers taking the same approach with business logic in enterprise apps all the time -- with the same consequences.
- erikpukinskis 7y agoCallback hell is easily avoided by naming callbacks. Async/await has its own footguns, except they’re so difficult to debug that you need static analysis tools (Typescript or ESLint) to use them safely. It’s one of that most special class of APIs that let you add a bug in one part of the system (e.g. forgetting an await) that causes a totally different part of the system to fail inscrutably. (Although really it’s Promises that unlock this ability, but potato/potahto.) Callbacks are easily debugged with just a normal JavaScript interpreter.
- simpsond 7y agoIf coding coffee is hard, coding espresso is really hard. More steps, more precision required... just like making espresso in reality. I like the theme of the article.
- alchemism 7y agoThere is a famous Zen saying (which) describes nothing-yet-everything about this: “Before Enlightenment, chop wood and carry water. After Enlightenment, chop wood and carry water.”
- bravura 7y agoOne day the Master [Joshu] announced that a young monk had reached an advanced state of enlightment. The news caused some stir. Some of the monks went to see the young monk [Kyogen]. "We heard you are enlightened. Is that true?" they asked. "It is," he replied. "And how do you feel?" "As miserable as ever," said the monk.
- timClicks 7y agoI still regret that I was never able to finish any of those games. Leisure Suit Larry, Police Quest, Space Quest and others. I poured hours into them and never got to the end. The worst was Kings Quest V. I really wanted to get that one, but I'm still left with not much more than regret, guilt and anger.
- 40four 7y agoWe played through Kings Quest (V? I can't remember) as a class when I was in grade school. My math/ science teacher had a copy and would let us play for a few minutes at the end of the day after assignments were done. We did eventually beat it after much trial and error, but only with the help of a cheat sheet she had printed off :) I do remember it being brutally hard.
- mhmood_jmj 7y ago110
- mhmood_jmj 7y ago111
- mhmood_jmj 7y ago112
- mhmood_jmj 7y ago113
- anonu 7y agotldr; They even offered some decent life strategies: look at everything, pick up anything you can, avoid wizards, and always haggle for jetpacks. Loved reading this...
- nateburke 7y ago“You are the master of your universe, and yet you are dripping with rat blood and feces. Your enormous mind literally vegetating by your own hand. I have no doubt that you would be bored senseless by therapy, the same way I’m bored when I brush my teeth and wipe my ass. Because the thing about repairing, maintaining, and cleaning is it’s not an adventure. There’s no way to do it so wrong you might die. It’s just work. And the bottom line is, some people are okay going to work, and some people … well, some people would rather die. Each of us gets to choose.” —the psychologist from ‘Pickle Rick’
- dottrap 7y agoFor those who love Space Quest, check out Snail Trek. It's like a modern made love letter to Space Quest. http://snailtrek.com http://snailtrek.com
- Rediscover 7y agoI frequently find the essays on stilldrinking.org entertaining. My favorite is still the one on why eCigarettes suck. https://www.stilldrinking.org/seriously-make-a-better-ecigarette https://www.stilldrinking.org/seriously-make-a-better-ecigar...
- misrab 7y agoLove this! > Avoiding premature death is a process of not occupying the same space as fast-moving metal or motivated microbes. Living is mostly a series of repetitive and unrelated tasks.
- shurcooL 7y agoThis seems like a high quality article and has many upvotes, but I found it hard to read, and unfortunately ads made it even harder, so I couldn't get through it. I wonder if I'm in the minority because I don't use an ad blocker?
- pavel_lishin 7y agoOh my god, it's so bad with the adblocker disabled. Does the author know?
- esotericsean 7y agoIs there a download somewhere? Or is this still in development?
- yters 7y agoEveryone is unhappy these days. It is not cool to be happy and satisfied.
- rsync 7y ago"There are no life lessons or gymnastic skills involved in doing dishes, there’s no underlying theory of housework that will reveal itself after a thousand vacuum cleanings." This is false. Doing dishes can involve gymnastic skills at any moment and the deepest truths of life, the universe - and everything - can be found in the simplest of chores.
- pugworthy 7y agoIt's a really fun read, but it's far more satire and humorous interpretation of game design and development than it is a real treatise on those topics.
- jasonkester 7y agoThe Coffee part of this article resonates with me. I have a stovetop espresso machine, and I'm constantly amazed at the new and ingenuous ways I come up with to mess it up. Making coffee before you've had your morning coffee is the great connundrum of our generation. Here's a short list of failure modes I've run up against: - Machine on stove, no water - Machine on stove, no coffee grounds - Machine on stove, completely empty - Coffee and water in machine, machine in refrigerator - Coffee grounds in water reservoir - Coffee grounds in brewed coffee reservoir - Brewing correctly, brewed coffee reservoir still filled with water from washing - Brewing correctly, head off to work - Brewing correctly, coffee grounds returned to microwave That's just a subset, and amazingly I still come up with a new one every few weeks.
- jdkee 7y agoSet theory is your friend. :)
- jmiskovic 7y agoThe coffee part also resonated stongly with me, for a completely different reason :) I spent last year thinking on how to implement a text-only simulation that could cope with just about any situation. Most of my models were mentally evaluated on this "simple" task of making coffee. The design I came up with (still to be implemented) is not code driven, but data driven. Instead of executing bunch of nested if-elses, I'd have a big list of tuples that contain <action, preconditions, reaction>. When action is performed upon object, this list is traversed. For each element, it's preconditions are compared to current world state. Based on this criteria the most suitable element is selected, and it's reaction is applied to modify world's state. Your list could be used as preconditions for action of brewing coffee; each would produce different results ranging from nice coffee to yucky mud or broken machine. I'd like to include a nice built-in editor that could be utilized to quickly modify or add reactions, objects, or world state variables. I have most of it figured out but it's a lot of work to put together all the pieces.
- Doxin 7y agoSounds like it could make for a fun variation on the text adventure, where having stuff go wrong is at least as amusing as actually solving puzzles.
- polynomial 7y ago> There are no life lessons (...) involved in doing dishes Couldn't be more wrong.