Roguelight: shadowcasting in kakoune

I’ve just published the kakoune-roguelight repository which contains an implementation of a roguelike-lighting system, based on this algorithm. Perhaps the most interesting thing about it is that it’s implemented in just posix shell.

I’m too lazy to make a demo now, but here is a screenshot. Please give it a try.

4 Likes

I’m sure you showed me a demo some time ago xd

Big gg :wink:

Yes if you look at the git history, you’ll see that most of the code was written half a year ago. I just had a sudden urge to fix and release it, and here we are.

Cool! This reminds me of good days of playing brogue.

The only thing bothers me is why walls that are in the light are all dark? those should be much brighter, no?

Also would be nice if it could work with https://github.com/lenormf/kakoune-extra/blob/master/games/sokoban.kak!

Excellent point, in fact just highlighting the walls is much more pleasant to the eye, I’ll try to tweak this.
Regarding the sokoban plugin, I think there wouldn’t be many changes required, just tweaking the opacity check to consider only ‘#’ to be walls, and call roguelight-refresh on each move.

1 Like