Anyone making a Julia MUD?

So, it’s way off to left field, but is anyone working on a MUD in Julia? In particular, I’m looking for an introduction to Julia book for a small cohort of middle-school kids and one way that I think they could be drawn into software development is by mixing STEM with creative writing and imagination. When I was young, making games was it. While making graphical games always captures attention, multi-user games are far more attractive since kids like to interact with their friends. So. I’m curious, anyone bother to build an interactive, web-based based game? Perhaps we could bootstrap something like this to capture the imagination of youth developers and broaden our outreach to young girls and even more specifically, those from disadvantaged backgrounds.

Why I think a MUD in Julia would be interesting? Multiple dispatch and scientific computing. At the very basic form of interaction is usually a 3-way dispatch: a subject, a direct object, and sometimes a set of indirect object(s). For example, someone taps another on the shoulder with a ruler. The verb tap could have a multiple dispatch. Furthermore, there are often 3 audiences for actions like this, the avatar performing the action, the avatar(s) directly affected by the action, and observers. Object oriented models don’t work well here, but I bet that multiple-dispatch would be singularly brilliant here. The other interesting thing is that statistics are always interesting for multi-person games, ie, plot of various properties. This could be a fun way to lure kids into real scientific programming, while at the same time linking with creative writing and drawing. Interactive story books are fun.

Anyone interested in a JuliaCon hackathon to bootstrap a JuliaMUD?

1 Like

While I consider your goals laudable, I think that Julia is not the right language for this.

It is powerful, but also complex — occasionally very complex. The complex parts are hard to contain: it is very difficult to come up with a subset that does not unravel. Julia users accept this complexity as the price of getting a singularly powerful language, but this power is mostly unneeded even at the level of an advanced high school student.

Moreover, a lot of key components of the package ecosystem are not that mature or work in progress. Add the “time to first plot” issue to this, and working in Julia as a first computer language is almost guaranteed to be a frustrating experience (except for the 0.1% of students who would probably enjoy it, but targeting them is probably not very inclusive).

AFAIK Python is very well suited for the purposes you describe.

Tamas, As someone who has used Python for two decades and Julia for about 2 years, I can appreciate what you are saying. But I just simply disagree. Perhaps Racket might be more appropriate, at least Racket is designed for pedagogy. But even so. I think a sample application solving a non-scientific problem would be particularly useful to this community, especially for on-boarding those who are using Julia as their first language. A MUD pops out at me because it can mix in creative writing and other artistic assets. Making stuff fun is important.

But I am not sure why you disagree. Searching Amazon for “python game coding children” turns up 20+ books, so there must be enough people who consider it appropriate for this task to sustain a market. No matter how one feels about Julia, it is difficult to dismiss Python as a good candidate out of hand.

As always, I think a project will be coded by people who consider it important enough to devote time to it. If getting a viable demo is something beyond the resources of a single (experienced) Julia coder, then I doubt the pedagogical utility.

Having taught Julia to undergrad and grad students, I seriously doubt that it is the right choice as a first programming language. This is not a statement about the language per se, more about the match between it and the audience.

Although this is a bit off topic, I am genuinely curious about what makes you say that Julia is not a good first programming language. (And what is a good first programming language.)

I think that learning is most satisfying when, after some effort invested, there is a feeling of having mastered some new domain. Of course after some consolidation, this is extended, but the ability to consolidate is important. Conversely, students are frustrated when the subject matter seems practically endless, or too large to digest in one pass without some success.

I think that for Julia, it is very difficult to isolate a subset that someone new to programming can master in a short course. It is pretty much inevitable to run into parametric types and multiple dispatch (eg trying to interpret an error message, even when the user used neither intentionally). This is simply too much when one is learning about loops.

Just to clarify, I think that Julia is the greatest language ever. But at the same time not ideal for a first language, just like calculus is not ideal for someone’s first math class.


I like the idea of building a MUD. If its feasible at the current state, i have no idea, but i hope you manage to build at least a proof of concept!

Regarding first programming languages, i think a good first programming language is one that has plenty of educational material, loads of previously asked questions on Stack Overflow or so, and makes sense for a given domain. I tried learning programming in the past but it made no sense in isolation, as i had no real reason to learn it. After finding myself in a business intelligence position learning things like R and SQL made sense because i could relate what i learned to what i tried to solve. I have no idea if you can get a bunch of middle school kids to get that connection with Julia. On the other hand, some folks worked on educational material for Haskell and it seems to work, so why not Julia.

Multiple dispatch is very well suited to game development. It really simplifies some stuff that gets way to complex in OO languages. Most modern game code has adopted an ECS style. ( google for better material that wikipedia ).
I’m sure Julia can handle a super elegant ECS system with or without macros.

The functional style of programming in Julia is also a big win for learning game dev since managing state is the main frustration in games. Games are very stateful programs.

For multi-user stuff channels will be your best friend.

Just remembered this:

For simple and fun “graphics” you can use (n)curses.

I’ll reserve my judgement on this issue until I can read how Tanmay teaches Julia for kids and beginners. :wink:


Not sure I found the right person, but

has no Julia code.

1 Like

I’ve kind of created an ECS for my rendering package Glimpse.jl (not very user friendly atm) and I must say that I like it a lot. The multiple dispatch has been very useful in being able to define a new System with Update method and a couple new Components that the System uses, and just inject it into the renderloop. It’s very easy to do some real time simulation and see the results rendered on your screen.

Also the power of MD allowed for the creation of a specific kind of array that works like a normal one but is tailored to be fast in an ECS.

There’s probably a huge amount of room for improvement in what I’ve got now though since it’s been the first ECS I’ve ever written.

1 Like

Why not a Rogue-like?

Haven’t booked my travel yet, so I’m not sure how much time I’ll have to stick around on the Hackathon day, but I’d be down for at least getting something off the ground.

As for where to begin, I really enjoyed Steve Losh’s “Caves of Clojure” series of posts: Part 1, Part 2, Part 3.1, Part 3.2, Part 3.3, Part 3.4, Part 4, Part 5, Interlude, Part 6, Part 7.1.

The game he develops is a rouge-like with algorithmically generated maps and a basic combat system. In a short amount of work he produces something quite engaging, I think, and provides a good framework for expanding upon game mechanics and adding new features.

Unfortunately, Steve never quite brought the project to any sort of conclusion, and has since moved on from Clojure to Common Lisp. Also, obviously there are some Clojure specific concerns that he spends time with that wouldn’t apply to Julia. In particular, drawing ASCII graphics in Clojure (i.e. Java) is much more complicated than it would be in Julia. He also puts a good amount of effort into how to manage game state in an inherently immutable language, work that could be avoided in Julia, but I rather feel that it’s an opportune chance to explore how immutability is not as restrictive as it might seem at first, while also picking up some good functional programming best practices.

Overall, I would love to see “Caves of Clojure” ported to Julia…maybe “Journey of Julia”?

I would need to see evidence that Python is actually pedagogically preferable to Julia as a first language. Python’s classes have several elements that are quite conceptually challenging, as well as some pretty intimidating boilerplate. You can omit classes, but that has similar error-interpreting implications as omitting multiple dispatch in Julia.

I honestly don’t know why folks consider Python’s conventions to be so much more straightforward or canonical than other languages’. I felt slightly gaslit by this phenomenon before I encountered Julia, because Python always felt to me more like a swiss army knife to me than pseudocode that runs. Nothing wrong with that, but it’s worth being honest about. If you want to see what it looks like when CS educators endeavor to make a Python-adjacent beginner friendly language, check out Pyret.

I find myself focusing more on language idiosyncrasies when teaching Python, and more on computer science ideas when teaching Julia. Thus, having taught one course in Julia and one in Python in the last year, I prefer the former as an instructional language by a significant margin. The students had a lot of positive feedback as well, despite using Python in other classes and having reasons to prefer sticking to one language. I received no complaints about Julia’s difficulty.


What ever the exact game or to whom its targeted, having an incrementally constructed system, that just happens to provide an introduction to Julia, seems something I’d like to see. I’d pick a MUD over a rogue like game mostly because the audience I have in mind is into multi-player story telling, not hack-n-slash. I’ve got a group of 9-12 year olds that play minecraft all evening at a sleepover, for them it’s about building things and showing their friends what they built via interactive immersion in the world they’ve constructed. With a MUD that has text and pictures, you don’t exclude those with creative writing and drawing skills.

I’ve also found Julia to be relatively easy to teach to beginners, at least at a surface level. With regard to pedagogy of parametric types and multiple dispatch while learning loops, if I had the choice between introducing multiple dispatch or loops, I’d do multiple-dispatch first. It’s just simple and intuitive. Of course functions would dispatch based on their types… why would it be any other way? By contrast, loops seem more advanced. Perhaps it is the error messages, not the language itself, that need help.

1 Like