Saturday, August 13, 2011

Short stories

I discovered the programming equivalent of writing short stories and it's kind of addictive.

These six programs (all in one) are roughly 600 lines of code. They're also mostly some type of "cool" or "fun". For me at least they were.

Here's the Google Docs link: QtBeziers.zip

There are six tabs, each of which has a mini-program of its own. From right to left:

Progress - Like Progress Quest, but slightly more graphical. This was me just getting used to Qt. It's even got the Hello World button.
Beziers - The coolest one. The one I spent the most time on. The one I named the program after. The one I made the whole program to make. Generalized Bezier curves. Click the canvas to set guide points. When you've specified order+1 points, it draws the resulting curve. Further clicks remove the oldest point and adds the newest as the end. The program defaults to cubic splines (3rd order), which are the Bezier curves we're most familiar with (if you didn't know; they're used in almost all vector graphics, including the font you're reading now), but the order can be modified (within reason). Subdivisions controls how the curve is drawn; the default should be fine. Time works with the ShowSteps option; this shows how the curve is drawn mathmatically, visually. Animate automatically increments the Time slider.
Mountain - This is an implementation of the one-dimensional Midpoint Displacement algorithm. I would have given settings to modify the algorithm, but it's randomized enough to be interesting on its own, and frankly who cares.
Neighborhood - Click the screen and it'll make points. Then it'll find the relative neighborhood graph of those points. This guarantees connectivity, but also can have cycles. It also doesn't cross the paths, which makes the graph spatially appealing. It also generalizes easily to higher dimensions. When it comes to 3D random dungeon generation, this is the algorithm I'm going to use to connect the rooms together.
Map - Creates a random world-map looking thing. Algorithm straight from here. [I think] the sliders are fairly intuitive; depth controls how much the program iterates, land controls the ratio of land to water, and noise controls how rough the borders look.
Cave - Makes random caves, using a cellular automata method.

3D random dungeons coming eventually!

Tuesday, August 9, 2011

Hands up, people who saw this coming

So yeah, interest in Duckbill got shot to hell. What happened? At roughly the same time, I burned myself out trying to write complicated networking code when I have only the most basic ideas of how networking works, and my artist got a real job and an internship. Yeah I had an artist working with me on that. Yeah I didn't mention that to avoid getting anybody's hopes up (not that the four of you reading this didn't already know).
Shortly after my desire to program anything hit rock-bottom, I started playing WoW.
Over a month later, here we are.

So, no games coming from me anytime in the near future.