Log In  

I ended up mostly skipping Genuary because of Ludum Dare, but today I decided to write a tiny village generator.

Cart #generator20220122-0 | 2023-01-22 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

This took me about one hour to write. Every time you run the cart, a new tiny village is generated.

There is nothing special going on. Walls are placed first, then doors and floors following a flood fill algorithm. Everything else is placed by sampling the map hundreds of times and checking for placing conditions.

The code is a bit of a mess and, looking back, I can see several easy places to reduce token count and increase variety. Maybe I'll revisit this before the end of the month. Maybe not.

I hope I'll have some time in march to participate in 7DRL. I have ideas I want to put into practice.

P#60314 2023-01-22 13:57


[Please log in to post a comment]

Follow Lexaloffle:          
Generated 2023-01-27 10:19:21 | 0.006s | Q:10