Skip to main content

Timeline for Light up a Roguelike

Current License: CC BY-SA 3.0

24 events
when toggle format what by license comment
Feb 5, 2014 at 7:51 vote accept Justin
Jan 28, 2014 at 19:05 history edited Justin CC BY-SA 3.0
added 26 characters in body
Jan 28, 2014 at 19:00 comment added Justin @IlmariKaronen You are absolutely correct. That is just how I like it. :-).
Jan 28, 2014 at 15:13 comment added Chowlett @IlmariKaronen - you're right. I'll edit in the vision pattern out to (40,40) into my answer.
Jan 28, 2014 at 14:51 comment added Ilmari Karonen Just a curious observation, but if I understand your definition of "line" right, it looks like there are some squares that won't be visible even without any obstacles. For example, if the player is at (0, 0), then the square at (5, 12) can't be reached by any line. It might've made more sense to, say, specify some canonical implementation of Bresenham's line algorithm for drawing a line between any two points, and define a square as obscured if the line between it and the player intersects an obstacle.
Jan 28, 2014 at 13:14 comment added Justin @Howard After verifying your results by hand, I believe they are correct. Thanks.
Jan 28, 2014 at 13:13 history edited Justin CC BY-SA 3.0
added 4 characters in body
Jan 28, 2014 at 9:20 comment added Howard @Quincunx Posted my current version (although it might be possible to golf further). The results are different from your examples (first and third one) - found some light paths which you seem to miss.
Jan 28, 2014 at 9:18 answer added Howard timeline score: 5
Jan 27, 2014 at 17:04 answer added Chowlett timeline score: 4
Jan 27, 2014 at 17:01 history edited Justin CC BY-SA 3.0
deleted 1 characters in body
Jan 27, 2014 at 16:42 comment added Justin @Howard Oops, missed those two dots; I filled it out by hand.
Jan 27, 2014 at 16:35 history edited Justin CC BY-SA 3.0
edited body
Jan 27, 2014 at 15:00 comment added Chowlett ...and I now match @Howard in having extra visible dots.
Jan 27, 2014 at 14:43 comment added Chowlett @Howard - aha, yes; I'd managed to miss that either d1 or d2 had to be magnitude 1. I was always stepping with the non-mag-1 component first.
Jan 27, 2014 at 14:34 comment added Howard @Chowlett You may choose 1 SE 2 E and after two full steps you are there.
Jan 27, 2014 at 14:32 comment added Howard Now that I've implemented a first version I can see more light than in your output. E.g. in the first case if I choose direction 1 E 8 SE there are two more dots in the lower right corner.
Jan 27, 2014 at 13:32 history tweeted twitter.com/#!/StackCodeGolf/status/427796240420831232
Jan 27, 2014 at 11:58 comment added Chowlett I'm starting to work on an implementation (my first ever golf!), but I don't quite match your solution. Can you tell me, in the first test, what d1 and d2 are to reach the last . in the J row?
Jan 27, 2014 at 5:31 comment added John Dvorak I don't know about quantum mechanics, but the bat and the gnome mummy might be an easy deal. The mimic might complicate things further, though. Also, those three ants might be fun, and the large group of assorted monsters on the north-east might already know about you. Yeah... it might be nasty. As for #3 - where's my teleporation scroll? Oops, that was destroy armor.
Jan 27, 2014 at 5:25 comment added Justin Those last two test cases gave me the chills...
Jan 27, 2014 at 5:24 comment added Justin @JanDvorak I was lazy and chose capital letters for blocking. Sort of like TALL monsters vs short monsters; which would you be able to see over. So yes.
Jan 27, 2014 at 5:23 comment added John Dvorak OK... bats, all kind of funghi, molds and snakes and even wraiths block the line of view, but giant mimics, hill orcs, mastodons, all kinds of other creatures or even fire vortices don't?
Jan 27, 2014 at 5:06 history asked Justin CC BY-SA 3.0