Settings

Theme

Swarm: A resource-gathering game based on robot programming, written in Haskell

github.com

110 points by Eugeleo 4 years ago · 26 comments

Reader

metagame 4 years ago

If you want a Lispier robot programming game, check out GNU Robots. You use the dialect of Scheme that most GNU tools are extensible with, so you'll get something out of it!

https://www.gnu.org/software/gnurobots/

  • y4mi 4 years ago

    there is also screeps if anyone wants the MMO experience. but this one aint free though, because you're effectively running code 24/7 and the devs need to maintain servers so that your code gets executed. i'd suggest just getting the simple game and run the server locally. no longer MMO in that case, but thats probably for the best until your code can handle raids by other players :)

    https://screeps.com/

JoelMcCracken 4 years ago

Oo this looks really cool! I'm bookmarking this for the future. I don't know that I'll have time to do anything with it any time soon, but looks really interesting.

I wish there were more "play games while programming" projects. Only thing is that they all seem to be too low level, whereas I want to be able to write logic like:

"when you have < 100 wood, stop creating carved objects and increase the amount of wood gathering."

instead of having to program my own pathfinding logic or whatever.

  • RHSeeger 4 years ago

    I highly recommend Bit Burner (https://danielyxie.github.io/bitburner/). It's an idle/incremental game with a focus on automating things with javascript. Heck of a lot of fun, imo.

  • timurtime 4 years ago

    Something that goes in the other extreme — very simple game rules, but you are free to code in whatever behaviour you want — https://yare.io

  • umvi 4 years ago

    > I wish there were more "play games while programming" projects

    I'm working on just such a project right now:

    https://bryanpg.com/games/pragma_twice

    Periodically check that page (or follow the Twitter) for a playable demo sometime in the next few months.

  • Folcon 4 years ago

    Interesting, I didn't think there was much demand for games like this.

    I'm putting together a few things in this space, would you be interested in a programming resources management game?

    • JoelMcCracken 4 years ago

      I mean, i baiscally want to play like Age of Empires II but script logic for units as well.

      edit: I should also add that it maybe depends what you're taklintg about; one thing i'd like to do is be able to play an actual normal game, but offload some of the menial tasks to scirpts. so some manual control, but I can write logic to make it less tedious.

Ciantic 4 years ago

How is the compile time?

I like Haskell's succinctness, but I was a bit shocked when I needed to compile Haskell IDE Engine (HIE) and had to wait almost 2 hours... That's when I thought, I'll just complete these university courses and see if I bother afterwards.

  • unhammer 4 years ago

    On a Thinkpad X270, 14m8s from I typed `stack build` in a fresh clone. I had the GHC version, but almost no libraries from that snapshot, so it had to compile a bunch of dependencies. I then tried a fresh clone and `stack build` again and that just took 1m15. Guess this is why people use things like cachix :-)

  • WJW 4 years ago

    Compile time in CI seems to be about 1 minute 20 seconds. Not the fastest, not terrible either.

  • JoelMcCracken 4 years ago

    Haskell does take a long time to compile from scratch, but once you compile once, it is much much faster. The annoying bit comes when you end up changing something which means a lot of other things end up needing to be recompiled, but there are ways to mitigate that, and overall I think haskell is very worth the tradeoff.

    I often think about "what would replace haskell?" though and ponder it, and I do think that most likely one feature will be a faster compiler (though I don't really know how possible that is to maintain feature parity).

roland35 4 years ago

I always wondered if there is some way to create a game where you program real life robots against each other?

xiaodai 4 years ago

Some kind of uglier Halite clone?

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection